L L4D2node

CUtlBuffer::PeekWhiteSpace

0x00260850 · 103 bytes · __thiscall

_ZN10CUtlBuffer14PeekWhiteSpaceEi

Decompiled

undefined (2 params)

/* CUtlBuffer::PeekWhiteSpace(int) */

int __thiscall CUtlBuffer::PeekWhiteSpace(CUtlBuffer *this,int param_1)

{
  char cVar1;
  int iVar2;
  uint uVar3;
  CUtlBuffer *unaff_EBX;
  int unaff_EBP;
  int unaff_ESI;
  
  iVar2 = 0;
  if ((((byte)this[0x15] & 1) != 0) && (this[0x14] == (CUtlBuffer)0x0)) {
    while (iVar2 = param_1, cVar1 = CheckPeekGet(unaff_EBX,unaff_ESI,unaff_EBP), cVar1 != '\0') {
      uVar3 = *(byte *)(*(int *)this + ((*(int *)(this + 0xc) + iVar2) - *(int *)(this + 0x20))) - 9
      ;
      if (0x17 < uVar3) {
        return iVar2;
      }
      if ((1 << ((byte)uVar3 & 0x1f) & 0x80001fU) == 0) {
        return iVar2;
      }
      param_1 = iVar2 + 1;
      if (((byte)this[0x14] & 2) != 0) {
        return iVar2 + 1;
      }
    }
  }
  return iVar2;
}

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)