L L4D2node

CCSPlayer::ShowMOTD

0x0065a660 · 264 bytes · __thiscall

_ZN9CCSPlayer8ShowMOTDEv

Decompiled

undefined (1 param)

/* CCSPlayer::ShowMOTD() */

void __thiscall CCSPlayer::ShowMOTD(CCSPlayer *this)

{
  char cVar1;
  int iVar2;
  KeyValues *this_00;
  undefined *puVar3;
  
  cVar1 = (**(code **)(*(int *)this + 0x778))(this);
  if ((cVar1 == '\0') && (g_pStringTableInfoPanel != (int *)0x0)) {
    puVar3 = &DAT_00c6d1bb;
    iVar2 = (**(code **)(*g_pStringTableInfoPanel + 0x34))(g_pStringTableInfoPanel);
    if (iVar2 != 0xffff) {
      this_00 = KeyValues::operator_new((KeyValues *)0x2c,(uint)puVar3);
                    /* try { // try from 0065a6cf to 0065a6d3 has its CatchHandler @ 0065a76f */
      KeyValues::KeyValues(this_00,"data",(IKeyValuesSystem *)0x0,false);
      KeyValues::SetString(this_00,"title","#L4D_MOTD");
      KeyValues::SetString(this_00,"type","1");
      KeyValues::SetString(this_00,"msg","motd");
      KeyValues::SetString(this_00,"cmd","joingame");
      (**(code **)(*(int *)this + 0x580))(this,"info",1,this_00);
      KeyValues::deleteThis();
      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)