L L4D2node

CVisibilityMonitor::IsTrackingEntity

0x006657c0 · 125 bytes · __thiscall

_ZN18CVisibilityMonitor16IsTrackingEntityEP11CBaseEntity

Decompiled

undefined (2 params)

/* CVisibilityMonitor::IsTrackingEntity(CBaseEntity*) */

undefined4 __thiscall
CVisibilityMonitor::IsTrackingEntity(CVisibilityMonitor *this,CBaseEntity *param_1)

{
  uint uVar1;
  int iVar2;
  uint *puVar3;
  undefined *puVar4;
  
  if (0 < *(int *)(this + 0x18)) {
    puVar3 = *(uint **)(this + 0xc);
    iVar2 = 0;
    do {
      uVar1 = *puVar3;
      if (((uVar1 == 0xffffffff) ||
          (puVar4 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar4 == (undefined *)0xfffffffc)) ||
         (*(uint *)(puVar4 + 8) != uVar1 >> 0xc)) {
        if (param_1 == (CBaseEntity *)0x0) {
          return 1;
        }
      }
      else if (param_1 == *(CBaseEntity **)(puVar4 + 4)) {
        return 1;
      }
      iVar2 = iVar2 + 1;
      puVar3 = puVar3 + 5;
    } while (iVar2 != *(int *)(this + 0x18));
  }
  return 0;
}

SourceMod gamedata

paste into addons/sourcemod/gamedata/<your_plugin>.txt
used as the SourceMod key — change to fit your plugin's convention
SourceMod library name (server / engine / matchmaking)

Just a Signatures{} block, ready to drop into a gamedata file. Wire it up in your plugin however you like - SDKCall, DHooks, raw memory ops, or anything else.



        

        

          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)