L L4D2node

CServerGameDLL::ServerActivate

0x006c4b20 · 235 bytes · __cdecl

_ZN14CServerGameDLL14ServerActivateEP7edict_tii

Decompiled

undefined (3 params)

/* CServerGameDLL::ServerActivate(edict_t*, int, int) */

void CServerGameDLL::ServerActivate(edict_t *param_1,int param_2,int param_3)

{
  int *piVar1;
  int iVar2;
  CBaseEntity *this;
  CBaseEntity *pCVar3;
  
  if (g_InRestore == '\0') {
    iVar2 = CGlobalEntityList::ResetDeleteList();
    if (iVar2 != 0) {
      Msg("ERROR: Entity delete queue not empty on level start!\n");
    }
    pCVar3 = (CBaseEntity *)0x0;
    while (this = (CBaseEntity *)CGlobalEntityList::NextEnt((CGlobalEntityList *)gEntList,pCVar3),
          this != (CBaseEntity *)0x0) {
      iVar2 = CBaseEntity::IsDormant(this);
      piVar1 = mdlcache;
      pCVar3 = this;
      if (iVar2 == 0) {
        (**(code **)(*mdlcache + 0x68))(mdlcache);
                    /* try { // try from 006c4b7f to 006c4b84 has its CatchHandler @ 006c4c26 */
        (**(code **)(*(int *)this + 0x94))(this);
        (**(code **)(*piVar1 + 0x6c))(piVar1);
      }
    }
    IGameSystem::LevelInitPostEntityAllSystems();
    CBaseEntity::SetAllowPrecache(false);
    if (*(int *)(*(int *)(g_pDeveloper + 0x1c) + 0x30) == 0) {
      pCVar3 = (CBaseEntity *)0x0;
      ConVar::SetValue(0xf7e660);
    }
    if (*(int *)(sv_no_navmesh._28_4_ + 0x30) == 0) {
      (**(code **)(*TheNavMesh + 0x28))(TheNavMesh,pCVar3);
    }
                    /* WARNING: Could not recover jumptable at 0x006c4be2. Too many branches */
                    /* WARNING: Treating indirect jump as call */
    (**(code **)(*TheDirector + 0x1c))();
    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)