L L4D2node

ServerDemoPacket_BaseAnimating::CompareAndCacheModifiedFields

0x00596c90 · 422 bytes · __thiscall

_ZN30ServerDemoPacket_BaseAnimating29CompareAndCacheModifiedFieldsERKS_

Decompiled

undefined (2 params)

/* ServerDemoPacket_BaseAnimating::CompareAndCacheModifiedFields(ServerDemoPacket_BaseAnimating
   const&) */

undefined4 __thiscall
ServerDemoPacket_BaseAnimating::CompareAndCacheModifiedFields
          (ServerDemoPacket_BaseAnimating *this,ServerDemoPacket_BaseAnimating *param_1)

{
  short sVar1;
  short sVar2;
  int iVar3;
  uint uVar4;
  uint local_1c;
  uint local_18;
  
  *(undefined4 *)this = 0;
  *(undefined4 *)(this + 4) = 0;
  sVar1 = *(short *)(param_1 + 0xc);
  sVar2 = *(short *)(this + 0xc);
  if (sVar2 != sVar1) {
    *(short *)(this + 0xc) = sVar1;
    *(undefined4 *)this = 1;
    *(undefined4 *)(this + 4) = 0;
  }
  local_18 = 0;
  local_1c = (uint)(sVar2 != sVar1);
  if (*(short *)(this + 0xe) != *(short *)(param_1 + 0xe)) {
    local_1c = local_1c | 2;
    *(short *)(this + 0xe) = *(short *)(param_1 + 0xe);
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (*(short *)(this + 0x10) != *(short *)(param_1 + 0x10)) {
    local_1c = local_1c | 4;
    *(short *)(this + 0x10) = *(short *)(param_1 + 0x10);
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (this[0x12] != param_1[0x12]) {
    local_1c = local_1c | 8;
    this[0x12] = param_1[0x12];
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (this[0x13] != param_1[0x13]) {
    local_1c = local_1c | 0x10;
    this[0x13] = param_1[0x13];
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (this[0x14] != param_1[0x14]) {
    local_1c = local_1c | 0x20;
    this[0x14] = param_1[0x14];
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (this[0x15] != param_1[0x15]) {
    local_1c = local_1c | 0x40;
    this[0x15] = param_1[0x15];
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (*(float *)(param_1 + 0x18) != *(float *)(this + 0x18)) {
    local_1c = local_1c | 0x80;
    *(float *)(this + 0x18) = *(float *)(param_1 + 0x18);
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (*(float *)(param_1 + 0x1c) != *(float *)(this + 0x1c)) {
    local_1c = local_1c | 0x100;
    *(float *)(this + 0x1c) = *(float *)(param_1 + 0x1c);
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (*(int *)(this + 0x20) != *(int *)(param_1 + 0x20)) {
    local_1c = local_1c | 0x200;
    *(int *)(this + 0x20) = *(int *)(param_1 + 0x20);
    *(uint *)this = local_1c;
    *(undefined4 *)(this + 4) = 0;
  }
  if (param_1[0x24] != (ServerDemoPacket_BaseAnimating)0x0) {
    iVar3 = 0;
    do {
      if (*(float *)(param_1 + iVar3 * 4 + 0x28) != *(float *)(this + iVar3 * 4 + 0x28)) {
        *(float *)(this + iVar3 * 4 + 0x28) = *(float *)(param_1 + iVar3 * 4 + 0x28);
        uVar4 = 0x800 << ((byte)iVar3 & 0x1f);
        local_1c = local_1c | uVar4;
        local_18 = local_18 | (int)uVar4 >> 0x1f;
        *(uint *)(this + 4) = local_18;
        *(uint *)this = local_1c;
      }
      iVar3 = iVar3 + 1;
    } while (iVar3 < (int)(uint)(byte)param_1[0x24]);
  }
  *(uint *)this = local_1c | 0x400;
  *(uint *)(this + 4) = local_18;
  return CONCAT31((int3)((local_18 | local_1c) >> 8),(local_18 | local_1c) != 0);
}

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)