L L4D2node

GetStringHelper

0x0020df30 · 94 bytes · __cdecl

_Z15GetStringHelperR10CUtlBufferPci

Decompiled

undefined (3 params)

/* GetStringHelper(CUtlBuffer&, char*, int) */

bool GetStringHelper(CUtlBuffer *param_1,char *param_2,int param_3)

{
  CUtlBuffer CVar1;
  
  *param_2 = '\0';
  CUtlBuffer::GetString(param_1,param_2,param_3);
  CVar1 = param_1[0x14];
  if (CVar1 != (CUtlBuffer)0x0) {
    *(undefined4 *)(param_1 + 0xc) = 0;
    *(undefined4 *)(param_1 + 0x10) = 0;
    *(undefined4 *)(param_1 + 0x20) = 0;
    *(undefined4 *)(param_1 + 0x1c) = 0;
    param_1[0x14] = (CUtlBuffer)0x0;
    CUtlMemory<unsigned_char,int>::Purge((CUtlMemory<unsigned_char,int> *)param_1);
  }
  return CVar1 == (CUtlBuffer)0x0;
}

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)