Skip to content

Commit

Permalink
more detailed debug into endtouch
Browse files Browse the repository at this point in the history
  • Loading branch information
zer0k-z committed Nov 9, 2023
1 parent 98cb49d commit 3cdc28d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/utils/detours.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,21 +129,25 @@ void FASTCALL Detour_CBaseTrigger_StartTouch(CBaseTrigger *this_, CBaseEntity *p
void FASTCALL Detour_CBaseTrigger_EndTouch(CBaseTrigger *this_, CBaseEntity *pOther)
{
DEBUG_PRINT(Detour_CBaseTrigger_EndTouch);
META_CONPRINTF("pOther = %x\n", pOther);
CBaseTrigger_EndTouch(this_, pOther);
DEBUG_PRINT_POST(Detour_CBaseTrigger_EndTouch);

if (!pOther) return;
DEBUG_PRINT(IsEntityPawn);
if (utils::IsEntityPawn(pOther))
{
if (IsEntTriggerMultiple((CBaseEntity *)this_))
{
DEBUG_PRINT(ToPlayer);
MovementPlayer *player = g_pPlayerManager->ToPlayer((CBasePlayerPawn *)pOther);
if (IsTriggerStartZone(this_))
{
DEBUG_PRINT(StartZoneEndTouch);
player->StartZoneEndTouch();
}
}
}
DEBUG_PRINT_POST(Detour_CBaseTrigger_EndTouch);
}

int FASTCALL Detour_RecvServerBrowserPacket(RecvPktInfo_t &info, void* pSock)
Expand Down

0 comments on commit 3cdc28d

Please sign in to comment.