L L4D2node

CSoundParametersInternal::PitchToString

0x00599440 · 166 bytes · __thiscall

_ZNK24CSoundParametersInternal13PitchToStringEv

Decompiled

undefined (1 param)

/* CSoundParametersInternal::PitchToString() const */

undefined1 * __thiscall CSoundParametersInternal::PitchToString(CSoundParametersInternal *this)

{
  uint uVar1;
  undefined1 *puVar2;
  float fVar3;
  
  uVar1 = (uint)(byte)this[0x14];
  if (this[0x15] != (CSoundParametersInternal)0x0) {
    V_snprintf(PitchToString()::sz,0x40,"%i, %i",uVar1,(byte)this[0x15] + uVar1);
    return PitchToString()::sz;
  }
  fVar3 = (float)uVar1;
  if (fVar3 == (float)g_pPitchLookup._0_4_) {
    puVar2 = g_pPitchLookup;
  }
  else if (fVar3 == (float)g_pPitchLookup._8_4_) {
    puVar2 = (undefined1 *)0xf212b8;
  }
  else {
    puVar2 = (undefined1 *)0xf212c0;
    if (fVar3 != (float)g_pPitchLookup._16_4_) {
      V_snprintf(_PitchToString(float)::sz,0x20,"%.3f",(double)uVar1);
      return _PitchToString(float)::sz;
    }
  }
  return *(undefined1 **)(puVar2 + 4);
}

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)