L L4D2node

CHLTVServer::BroadcastEvent

0x0016fb80 · 422 bytes · __thiscall

_ZN11CHLTVServer14BroadcastEventEP10IGameEvent

Decompiled

undefined (2 params)

/* CHLTVServer::BroadcastEvent(IGameEvent*) */

void __thiscall CHLTVServer::BroadcastEvent(CHLTVServer *this,IGameEvent *param_1)

{
  char cVar1;
  undefined4 uVar2;
  int in_GS_OFFSET;
  undefined **local_4ac;
  undefined1 local_4a8;
  undefined4 local_4a4;
  undefined4 local_4a0;
  undefined4 local_49c;
  undefined8 local_498;
  undefined4 local_490;
  undefined4 local_48c;
  undefined8 local_488;
  undefined4 local_480;
  undefined4 local_47c;
  undefined1 local_478;
  undefined8 local_474;
  undefined4 local_46c;
  undefined4 local_468;
  undefined4 local_45c;
  undefined1 local_458;
  undefined4 local_454;
  undefined4 local_450;
  bf_write local_438 [24];
  undefined1 local_420 [1024];
  int local_20;
  
  local_498 = 0;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  local_488 = 0;
  local_474 = 0;
  local_4a0 = 0;
  local_49c = 0;
  local_490 = 0;
  local_48c = 0;
  local_480 = 0;
  local_47c = 0;
  local_478 = 0;
  local_46c = 0;
  local_468 = 0;
  local_4a8 = 1;
  local_4a4 = 0;
  local_4ac = &PTR__SVC_GameEvent_002a1f48;
  local_458 = 0;
  local_45c = 0;
  local_454 = 0xffffffff;
  local_450 = 0;
  bf_write::bf_write(local_438);
  bf_write::StartWriting(local_438,local_420,0x400,0,-1);
  cVar1 = (**(code **)(s_GameEventManager + 0x30))(&s_GameEventManager,param_1,local_438);
  if (cVar1 == '\0') {
    uVar2 = (**(code **)(*(int *)param_1 + 8))(param_1);
    DevMsg("CHLTVServer: failed to serialize event \'%s\'.\n",uVar2);
  }
  else {
    (**(code **)(*(int *)(this + 4) + 0x84))(this + 4,&local_4ac,1,1);
    if (*(int *)(tv_debug._28_4_ + 0x30) != 0) {
      uVar2 = (**(code **)(*(int *)param_1 + 8))(param_1);
      Msg("SourceTV broadcast event: %s\n",uVar2);
    }
  }
  if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
    return;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail();
}

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)