L L4D2node

CTestScriptMgr::CheckPoint

0x0021a880 · 171 bytes · __thiscall

_ZN14CTestScriptMgr10CheckPointEPKc

Decompiled

undefined (2 params)

/* CTestScriptMgr::CheckPoint(char const*) */

void __thiscall CTestScriptMgr::CheckPoint(CTestScriptMgr *this,char *param_1)

{
  int iVar1;
  longdouble lVar2;
  char *local_14;
  undefined4 local_10;
  
  if ((*(int *)(this + 4) != 0) &&
     (lVar2 = (longdouble)Plat_FloatTime(), *(double *)(this + 0x28) <= (double)lVar2)) {
    if ((*(int *)(testscript_debug._28_4_ + 0x30) != 0) &&
       (iVar1 = _V_stricmp(param_1,"frame_end"), iVar1 != 0)) {
      Msg("TESTSCRIPT: CheckPoint -> \'%s\'.\n",param_1);
    }
    local_14 = strdup(param_1);
    local_10 = 0;
    CUtlRBTree<CUtlMap<char_const*,int,int>::Node_t,int,CUtlMap<char_const*,int,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,int,int>::Node_t,int>,int>>
    ::Insert((CUtlRBTree<CUtlMap<char_const*,int,int>::Node_t,int,CUtlMap<char_const*,int,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,int,int>::Node_t,int>,int>>
              *)(this + 0x58),(Node_t *)&local_14);
    if ((this[8] != (CTestScriptMgr)0x0) &&
       (iVar1 = _V_stricmp((char *)(this + 8),param_1), iVar1 != 0)) {
      return;
    }
    this[8] = (CTestScriptMgr)0x0;
    RunCommands(this);
  }
  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)