Quote:
Originally Posted by throwaway12812391
Is it possible to change
PHP Code:
if ( !PointInRespawnRoom( this, WorldSpaceCenter() ) )
to
PHP Code:
if ( !PointInRespawnRoom( this, WorldSpaceCenter(), true ) )
in CTFPlayer::CheckInstantLoadoutRespawn with a detour to prevent usage in enemy func_respawnroom? I am completely new to DHooks.
|
It sounds like you want to patch the function call, specifically one of the params passed to it.
What you can do is detour
CTFPlayer::CheckInstantLoadoutRespawn and then patch the function call in pre-hook and restore the original bytes in post-hook. That's only if you want to do it per-player.
If you just want to patch that function call for the server's whole lifespan, then you won't need to detour anything. In that case, you would just need the address of
CTFPlayer::CheckInstantLoadoutRespawn and the offset of the "mov" instruction that passes the bool to the
PointInRespawnRoom function call.
__________________