L L4D2node

CBaseDoor::ChainTouch

0x006678a0 · 206 bytes · __thiscall

_ZN9CBaseDoor10ChainTouchEP11CBaseEntity

Decompiled

undefined (2 params)

/* CBaseDoor::ChainTouch(CBaseEntity*) */

void __thiscall CBaseDoor::ChainTouch(CBaseDoor *this,CBaseEntity *param_1)

{
  char *pcVar1;
  int *piVar2;
  CBaseEntity *pCVar3;
  
  if (this[0x5f9] == (CBaseDoor)0x0) {
    pCVar3 = (CBaseEntity *)0x0;
    while( true ) {
      pcVar1 = *(char **)(this + 0x518);
      if (pcVar1 == (char *)0x0) {
        pcVar1 = "";
      }
      pCVar3 = (CBaseEntity *)
               CGlobalEntityList::FindEntityByName
                         ((CGlobalEntityList *)gEntList,pCVar3,pcVar1,(CBaseEntity *)0x0,
                          (CBaseEntity *)0x0,(CBaseEntity *)0x0,(IEntityFindFilter *)0x0);
      if (pCVar3 == (CBaseEntity *)0x0) break;
      if (this != (CBaseDoor *)pCVar3) {
        piVar2 = (int *)__dynamic_cast(pCVar3,&CBaseEntity::typeinfo,&typeinfo,0);
        if ((piVar2 != (int *)0x0) && (piVar2[0x110] == *(int *)(this + 0x440))) {
          *(undefined1 *)((int)piVar2 + 0x5f9) = 1;
          (**(code **)(*piVar2 + 0x1b4))(piVar2,param_1);
          *(undefined1 *)((int)piVar2 + 0x5f9) = 0;
        }
      }
    }
  }
  return;
}

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)