L L4D2node

rr2::CRuleBuilder::ReserveLambdaCriteria

0x00bd9b40 · 133 bytes · __thiscall

_ZN3rr212CRuleBuilder21ReserveLambdaCriteriaEib

Decompiled

undefined (3 params)

/* rr2::CRuleBuilder::ReserveLambdaCriteria(int, bool) */

void __thiscall
rr2::CRuleBuilder::ReserveLambdaCriteria(CRuleBuilder *this,int param_1,bool param_2)

{
  int iVar1;
  void *pvVar2;
  uint uVar3;
  
  iVar1 = *(int *)(this + 4);
  if (!param_2) {
    uVar3 = *(uint *)(iVar1 + 0x54) / 0xc;
    if ((int)uVar3 < (int)(param_1 + uVar3)) {
      uVar3 = param_1 + uVar3;
    }
    pvVar2 = realloc(*(void **)(iVar1 + 0x50),uVar3 * 0xc);
    *(uint *)(iVar1 + 0x54) = uVar3 * 0xc;
    *(void **)(iVar1 + 0x50) = pvVar2;
    *(void **)(iVar1 + 0x5c) = pvVar2;
    return;
  }
  uVar3 = *(uint *)(iVar1 + 0x24) / 0xc;
  if ((int)uVar3 < (int)(param_1 + uVar3)) {
    uVar3 = param_1 + uVar3;
  }
  pvVar2 = realloc(*(void **)(iVar1 + 0x20),uVar3 * 0xc);
  *(uint *)(iVar1 + 0x24) = uVar3 * 0xc;
  *(void **)(iVar1 + 0x20) = pvVar2;
  *(void **)(iVar1 + 0x2c) = pvVar2;
  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)