L L4D2node

L4D1SurvivorBehavior::IsHindrance

0x00922410 · 266 bytes · __thiscall

_ZNK20L4D1SurvivorBehavior11IsHindranceEPK8INextBotP11CBaseEntity

Decompiled

undefined (3 params)

/* L4D1SurvivorBehavior::IsHindrance(INextBot const*, CBaseEntity*) const */

undefined4 __thiscall
L4D1SurvivorBehavior::IsHindrance(L4D1SurvivorBehavior *this,INextBot *param_1,CBaseEntity *param_2)

{
  char cVar1;
  undefined4 uVar2;
  int iVar3;
  CBaseEntity *pCVar4;
  int *piVar5;
  
  uVar2 = 1;
  if (param_2 != (CBaseEntity *)&DAT_ffffffff) {
    cVar1 = (**(code **)(*(int *)param_1 + 0x11c))
                      (param_1,param_2,*(undefined4 *)(SurvivorBotHindranceRange._28_4_ + 0x2c));
    if (cVar1 == '\0') {
      iVar3 = CBaseEntity::GetTeamNumber(param_2);
      cVar1 = IsASurvivorTeam(iVar3);
      if (cVar1 == '\0') {
        iVar3 = CBaseEntity::GetTeamNumber(param_2);
        if (iVar3 != 3) {
          return 2;
        }
        pCVar4 = (CBaseEntity *)(**(code **)(*(int *)param_2 + 0x144))(param_2);
        iVar3 = CBaseEntity::GetTeamNumber(pCVar4);
        if ((iVar3 != 3) || (iVar3 = (**(code **)(*(int *)pCVar4 + 0x544))(pCVar4), iVar3 != 8)) {
          pCVar4 = (CBaseEntity *)(**(code **)(*(int *)param_2 + 0x144))(param_2);
          iVar3 = CBaseEntity::GetTeamNumber(pCVar4);
          if ((iVar3 != 3) || (iVar3 = (**(code **)(*(int *)pCVar4 + 0x544))(pCVar4), iVar3 != 7)) {
            piVar5 = (int *)(**(code **)(*(int *)param_1 + 0xcc))(param_1);
            cVar1 = (**(code **)(*piVar5 + 0xd0))(piVar5,param_2,1,0);
            if (cVar1 != '\0') {
              return 1;
            }
          }
        }
        return 2;
      }
    }
    uVar2 = 0;
  }
  return uVar2;
}

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)