L L4D2node

CUtlInplaceBuffer::InplaceGetLinePtr

0x0004e920 · 118 bytes · __thiscall

_ZN17CUtlInplaceBuffer17InplaceGetLinePtrEv

Decompiled

undefined (1 param)

/* CUtlInplaceBuffer::InplaceGetLinePtr() */

char * __thiscall CUtlInplaceBuffer::InplaceGetLinePtr(CUtlInplaceBuffer *this)

{
  char cVar1;
  char *local_14;
  int local_10 [3];
  
  local_14 = (char *)0x0;
  local_10[0] = 0;
  cVar1 = InplaceGetLinePtr(this,&local_14,local_10);
  if (cVar1 != '\0') {
    cVar1 = local_14[local_10[0] + -1];
    if ((cVar1 == '\n') || (cVar1 == '\r')) {
      local_14[local_10[0] + -1] = '\0';
      if (local_10[0] != 1) {
        cVar1 = local_14[local_10[0] + -2];
        if ((cVar1 == '\n') || (cVar1 == '\r')) {
          local_14[local_10[0] + -2] = '\0';
          return local_14;
        }
      }
    }
  }
  return local_14;
}

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)