sdkhooks: Allow overriding SDKHook_Think (#1397)
* Allow to block Think() * Update SDKHookCB comment
This commit is contained in:
parent
fdfb8837d1
commit
823b55c22a
@ -1458,7 +1458,11 @@ void SDKHooks::Hook_StartTouchPost(CBaseEntity *pOther)
|
|||||||
|
|
||||||
void SDKHooks::Hook_Think()
|
void SDKHooks::Hook_Think()
|
||||||
{
|
{
|
||||||
Call(META_IFACEPTR(CBaseEntity), SDKHook_Think);
|
cell_t result = Call(META_IFACEPTR(CBaseEntity), SDKHook_Think);
|
||||||
|
|
||||||
|
if(result >= Pl_Handled)
|
||||||
|
RETURN_META(MRES_SUPERCEDE);
|
||||||
|
|
||||||
RETURN_META(MRES_IGNORED);
|
RETURN_META(MRES_IGNORED);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -237,11 +237,12 @@ typeset SDKHookCB
|
|||||||
function void (int client);
|
function void (int client);
|
||||||
|
|
||||||
// Spawn
|
// Spawn
|
||||||
|
// Think
|
||||||
function Action (int entity);
|
function Action (int entity);
|
||||||
|
|
||||||
// GroundEntChanged
|
// GroundEntChanged
|
||||||
// SpawnPost
|
// SpawnPost
|
||||||
// Think/Post
|
// ThinkPost
|
||||||
// VPhysicsUpdate/Post
|
// VPhysicsUpdate/Post
|
||||||
function void (int entity);
|
function void (int entity);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user