L L4D2node

CTerrorPlayer::OnSpeak

0x009f4aa0 · 235 bytes · __thiscall

_ZN13CTerrorPlayer7OnSpeakEP11CBasePlayerPKcf

Decompiled

undefined (4 params)

/* CTerrorPlayer::OnSpeak(CBasePlayer*, char const*, float) */

void __thiscall
CTerrorPlayer::OnSpeak(CTerrorPlayer *this,CBasePlayer *param_1,char *param_2,float param_3)

{
  float fVar1;
  longdouble lVar2;
  
  if (this == (CTerrorPlayer *)param_1) {
    fVar1 = *(float *)(this + 0x30a0);
    lVar2 = (longdouble)CountdownTimer::Now();
    if (fVar1 - (float)lVar2 < param_3) {
      (**(code **)(*(int *)this + 0x850))
                (this,*(undefined4 *)(ZombieNoiseLevelVocalize._28_4_ + 0x2c));
      lVar2 = (longdouble)CountdownTimer::Now();
      if ((float)lVar2 + param_3 != *(float *)(this + 0x30a0)) {
        (**(code **)(*(int *)(this + 0x3098) + 4))(this + 0x3098,this + 0x30a0);
        *(float *)(this + 0x30a0) = (float)lVar2 + param_3;
      }
      if (param_3 != *(float *)(this + 0x309c)) {
        (**(code **)(*(int *)(this + 0x3098) + 4))(this + 0x3098,this + 0x309c);
        *(float *)(this + 0x309c) = param_3;
        return;
      }
    }
  }
  return;
}

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)