L L4D2node

BZ2_bzBuffToBuffCompress

0x002906a0 · 278 bytes · unknown

Decompiled

undefined (0 params)

int BZ2_bzBuffToBuffCompress
              (int param_1,int *param_2,int param_3,undefined4 param_4,int param_5,uint param_6,
              uint param_7)

{
  int iVar1;
  int iVar2;
  int local_4c;
  undefined4 local_48;
  int local_3c;
  int local_38;
  undefined4 local_28;
  undefined4 local_24;
  undefined4 local_20;
  
  if ((((param_1 != 0) && (param_2 != (int *)0x0)) && (param_3 != 0)) &&
     (((param_5 - 1U < 9 && (param_6 < 5)) && (param_7 < 0xfb)))) {
    if (param_7 == 0) {
      param_7 = 0x1e;
    }
    local_28 = 0;
    local_24 = 0;
    local_20 = 0;
    iVar1 = BZ2_bzCompressInit(&local_4c,param_5,param_6,param_7);
    if (iVar1 == 0) {
      local_3c = param_1;
      local_4c = param_3;
      local_48 = param_4;
      local_38 = *param_2;
      iVar2 = BZ2_bzCompress(&local_4c,2);
      if (iVar2 == 3) {
        iVar1 = -8;
        BZ2_bzCompressEnd(&local_4c);
      }
      else {
        if (iVar2 != 4) {
          BZ2_bzCompressEnd(&local_4c);
          return iVar2;
        }
        *param_2 = *param_2 - local_38;
        BZ2_bzCompressEnd(&local_4c);
      }
    }
    return iVar1;
  }
  return -2;
}

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.



        
        

⚠ This function has no mangled symbol — it may be internal/static. The Linux gamedata field uses @-prefix symbol resolution which requires an exported mangled name. You'll need a Linux byte signature for this one (extract via extract_signature.java).


          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)