L L4D2node

CBaseCombatCharacter::SetTransmit

0x005f8c90 · 374 bytes · __thiscall

_ZN20CBaseCombatCharacter11SetTransmitEP18CCheckTransmitInfob

Decompiled

undefined (3 params)

/* CBaseCombatCharacter::SetTransmit(CCheckTransmitInfo*, bool) */

void __thiscall
CBaseCombatCharacter::SetTransmit
          (CBaseCombatCharacter *this,CCheckTransmitInfo *param_1,bool param_2)

{
  int iVar1;
  int *piVar2;
  edict_t *peVar3;
  char cVar4;
  uint uVar5;
  uint uVar6;
  int iVar7;
  undefined *puVar8;
  CBasePlayer *this_00;
  
  if (*(int *)(this + 0x30) == 0) {
    uVar5 = 1;
    iVar7 = 0;
  }
  else {
    uVar6 = *(int *)(this + 0x30) - *(int *)(gpGlobals + 0x58) >> 4;
    uVar5 = 1 << ((byte)uVar6 & 0x1f);
    iVar7 = (uVar6 >> 5) << 2;
  }
  if ((uVar5 & *(uint *)(*(int *)(param_1 + 0x2008) + iVar7)) != 0) {
    return;
  }
  CBaseAnimating::SetTransmit((CBaseAnimating *)this,param_1,param_2);
  iVar7 = *(int *)(this + 0x30);
  iVar1 = *(int *)param_1;
  cVar4 = (**(code **)(*(int *)this + 0x16c))(this);
  if (cVar4 == '\0') {
    if (iVar1 != iVar7) {
LAB_005f8d1b:
      uVar5 = *(uint *)(this + 0x19d4);
      if (uVar5 == 0xffffffff) {
        return;
      }
      puVar8 = g_pEntityList + (uVar5 & 0xfff) * 0x10;
      if (puVar8 == (undefined *)0xfffffffc) {
        return;
      }
      if (*(uint *)(puVar8 + 8) != uVar5 >> 0xc) {
        return;
      }
      piVar2 = *(int **)(puVar8 + 4);
      if (piVar2 == (int *)0x0) {
        return;
      }
      if ((*(byte *)(piVar2 + 0x35) & 0x20) != 0) {
        return;
      }
                    /* WARNING: Could not recover jumptable at 0x005f8d74. Too many branches */
                    /* WARNING: Treating indirect jump as call */
      (**(code **)(*piVar2 + 0x5c))();
      return;
    }
  }
  else if (iVar1 != iVar7) {
    peVar3 = *(edict_t **)param_1;
    cVar4 = (**(code **)(*(int *)this + 0x16c))(this);
    this_00 = (CBasePlayer *)0x0;
    if (cVar4 != '\0') {
      this_00 = (CBasePlayer *)this;
    }
    cVar4 = CBasePlayer::IsSplitScreenUserOnEdict(this_00,peVar3);
    if (cVar4 == '\0') goto LAB_005f8d1b;
  }
  iVar7 = 0;
  do {
    uVar5 = *(uint *)(this + iVar7 * 4 + 0x18f4);
    if ((((uVar5 != 0xffffffff) &&
         (puVar8 = g_pEntityList + (uVar5 & 0xfff) * 0x10, puVar8 != (undefined *)0xfffffffc)) &&
        (*(uint *)(puVar8 + 8) == uVar5 >> 0xc)) &&
       (piVar2 = *(int **)(puVar8 + 4), piVar2 != (int *)0x0)) {
      (**(code **)(*piVar2 + 0x5c))(piVar2,param_1,param_2);
    }
    iVar7 = iVar7 + 1;
  } while (iVar7 != 0x38);
  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)