L L4D2node

CGameTimescale::SetCurrentTimescale

0x00465800 · 160 bytes · __thiscall

_ZN14CGameTimescale19SetCurrentTimescaleEf

Decompiled

undefined (2 params)

/* CGameTimescale::SetCurrentTimescale(float) */

void __thiscall CGameTimescale::SetCurrentTimescale(CGameTimescale *this,float param_1)

{
  int *piVar1;
  undefined **local_2c [8];
  
  piVar1 = engine;
  if (param_1 == *(float *)(this + 0x10)) {
    return;
  }
  *(float *)(this + 0xc) = param_1;
  *(float *)(this + 0x10) = param_1;
  (**(code **)(*piVar1 + 0x200))(piVar1,param_1);
  CRecipientFilter::CRecipientFilter((CRecipientFilter *)local_2c);
  local_2c[0] = &PTR__CBroadcastRecipientFilter_00c09928;
                    /* try { // try from 00465855 to 00465859 has its CatchHandler @ 004658a3 */
  CRecipientFilter::AddAllPlayers((CRecipientFilter *)local_2c);
  local_2c[0] = &PTR__CReliableBroadcastRecipientFilter_00c157a8;
                    /* try { // try from 00465864 to 00465868 has its CatchHandler @ 004658b5 */
  CRecipientFilter::MakeReliable((CRecipientFilter *)local_2c);
                    /* try { // try from 00465874 to 0046588c has its CatchHandler @ 004658ce */
  UserMessageBegin((IRecipientFilter *)local_2c,"CurrentTimescale");
  MessageWriteFloat(*(float *)(this + 0x10));
  MessageEnd();
  local_2c[0] = &PTR__CBroadcastRecipientFilter_00c09928;
  CRecipientFilter::~CRecipientFilter((CRecipientFilter *)local_2c);
  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)