L L4D2node

Behavior<Charger>::Update

0x00a8f5d0 · 299 bytes · __cdecl

_ZN8BehaviorI7ChargerE6UpdateEPS0_f

Decompiled

undefined (2 params)

/* Behavior<Charger>::Update(Charger*, float) */

void Behavior<Charger>::Update(Charger *param_1,float param_2)

{
  code *pcVar1;
  char cVar2;
  int iVar3;
  undefined4 uVar4;
  int in_GS_OFFSET;
  undefined4 local_138;
  undefined4 local_134;
  undefined4 local_130;
  undefined **local_12c;
  undefined1 local_128;
  undefined1 local_127;
  undefined4 local_24;
  int local_20;
  
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  if ((param_2 != 0.0) && (*(Behavior **)(param_1 + 8) != (Behavior *)0x0)) {
    Action<Charger>::InvokeUpdate((Charger *)&local_138,*(Behavior **)(param_1 + 8),param_2);
    iVar3 = Action<Charger>::ApplyResult
                      (*(undefined4 *)(param_1 + 8),param_2,param_1,local_138,local_134,local_130);
    *(int *)(param_1 + 8) = iVar3;
    if (iVar3 != 0) {
      cVar2 = INextBot::IsDebugging((INextBot *)((int)param_2 + 0x4028),1);
      if (cVar2 != '\0') {
        local_128 = 1;
        local_12c = &PTR_InitQuietTruncation_00c08ee8;
        local_127 = 0;
        local_24 = 0;
        pcVar1 = *(code **)(*(int *)((int)param_2 + 0x4028) + 0x144);
        uVar4 = Action<Charger>::DebugString(*(Action<Charger> **)(param_1 + 8));
        uVar4 = CFmtStrN<256>::sprintf((CFmtStrN<256> *)&local_12c,"%s: %s",param_1 + 0x11,uVar4);
        (*pcVar1)((INextBot *)((int)param_2 + 0x4028),uVar4);
      }
    }
  }
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    __stack_chk_fail();
  }
  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)