#include "SessionScript.h"
◆ SessionScript()
| SessionScript::SessionScript |
( |
char const * |
name, |
|
|
std::vector< uint16 > |
enabledHooks = std::vector<uint16>() |
|
) |
| |
|
protected |
40{
41
42 if (enabledHooks.empty())
44 enabledHooks.emplace_back(i);
45
47}
std::uint16_t uint16
Definition Define.h:108
@ SESSIONHOOK_END
Definition SessionScript.h:28
Definition ScriptObject.h:42
static void AddScript(TScript *const script, std::vector< uint16 > enabledHooks={})
Definition ScriptMgr.h:798
References ScriptRegistry< TScript >::AddScript(), and SESSIONHOOK_END.
◆ OnSessionUpdate()
This hook is called once per world tick for every session, from the world thread, right before the session processes its logout and warden checks.
- Parameters
-
| session | Contains information about the WorldSession |
| diff | Contains information about the diff time |
Referenced by ScriptMgr::OnSessionUpdate().
◆ OnWardenCheckExpectedResult()
This hook is called when Warden evaluates the client's answer to a MEM_CHECK or MPQ_CHECK, right before the answer is compared with the expected bytes.
A script may replace the expected bytes (warden_checks.result) for this session only, for example for a client build whose memory or files legitimately differ from the stock client.
- Parameters
-
| session | Contains information about the WorldSession |
| check | The warden check being evaluated |
| expected | Receives the bytes the client must return: check.Length bytes for a MEM_CHECK, 20 (SHA1) for an MPQ_CHECK |
- Returns
- true if expected was filled; the first script returning true wins
Referenced by ScriptMgr::OnWardenCheckExpectedResult().
The documentation for this class was generated from the following files: