L L4D2node

CloseZipZ

0x000ef610 · 197 bytes · __cdecl

_Z9CloseZipZP6HZIP__

Decompiled

undefined (1 param)

/* CloseZipZ(HZIP__*) */

undefined4 CloseZipZ(HZIP__ *param_1)

{
  TZip *this;
  undefined4 *puVar1;
  undefined4 uVar2;
  
  if (param_1 != (HZIP__ *)0x0) {
    if (*(int *)param_1 == 2) {
      this = *(TZip **)(param_1 + 4);
      uVar2 = TZip::Close(this);
      puVar1 = (undefined4 *)___tls_get_addr();
      *puVar1 = uVar2;
      if (this != (TZip *)0x0) {
        operator_delete(this);
      }
      operator_delete(param_1);
      puVar1 = (undefined4 *)___tls_get_addr();
      uVar2 = *puVar1;
    }
    else {
      puVar1 = (undefined4 *)___tls_get_addr();
      *puVar1 = 0x80000;
      uVar2 = 0x80000;
    }
    return uVar2;
  }
  puVar1 = (undefined4 *)___tls_get_addr();
  *puVar1 = 0x10000;
  return 0x10000;
}

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)