L L4D2node

IVision::ForEachRecognized<ThreatCounter>

0x00923070 · 201 bytes · __thiscall

_ZN7IVision17ForEachRecognizedI13ThreatCounterEEbRT_

Decompiled

bool (2 params)

/* bool IVision::ForEachRecognized<ThreatCounter>(ThreatCounter&) */

bool __thiscall IVision::ForEachRecognized<ThreatCounter>(IVision *this,ThreatCounter *param_1)

{
  uint uVar1;
  char cVar2;
  int *piVar3;
  undefined *puVar4;
  int iVar5;
  int iVar6;
  
  iVar6 = 0;
  iVar5 = 0;
  if (*(int *)(this + 0x38) < 1) {
    return true;
  }
  do {
    while ((((*(float *)(gpGlobals + 0xc) < (float)((uint *)(*(int *)(this + 0x2c) + iVar5))[4] ||
             (uVar1 = *(uint *)(*(int *)(this + 0x2c) + iVar5), uVar1 == 0xffffffff)) ||
            (puVar4 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar4 == (undefined *)0xfffffffc)) ||
           (((*(uint *)(puVar4 + 8) != uVar1 >> 0xc ||
             (piVar3 = *(int **)(puVar4 + 4), piVar3 == (int *)0x0)) ||
            (piVar3 = (int *)(**(code **)(*piVar3 + 0x148))(piVar3), piVar3 == (int *)0x0))))) {
LAB_00923090:
      iVar6 = iVar6 + 1;
      iVar5 = iVar5 + 0x14;
      if (*(int *)(this + 0x38) <= iVar6) {
        return true;
      }
    }
    piVar3 = (int *)(**(code **)(*piVar3 + 0xc4))(piVar3);
    cVar2 = (**(code **)(*piVar3 + 0x114))(piVar3,2);
    if (cVar2 == '\0') goto LAB_00923090;
    iVar6 = iVar6 + 1;
    iVar5 = iVar5 + 0x14;
    *(int *)param_1 = *(int *)param_1 + 1;
    if (*(int *)(this + 0x38) <= iVar6) {
      return true;
    }
  } while( true );
}

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)