L L4D2node

tv_retry

0x0016f9c0 · 244 bytes · __cdecl

_ZL8tv_retryRK8CCommand

Decompiled

undefined (1 param)

/* tv_retry(CCommand const&) */

void tv_retry(CCommand *param_1)

{
  int iVar1;
  undefined4 uVar2;
  undefined4 uVar3;
  
  if (hltv == 0) {
    ConMsg("SourceTV not active.\n");
    return;
  }
  if (*(char *)(hltv + 0x63a0) == '\0') {
    iVar1 = CAddressList::Count((CAddressList *)(hltv + 0x240));
    if (iVar1 != 0) {
      iVar1 = CAddressList::Get((CAddressList *)(hltv + 0x240),0);
      uVar2 = CUtlString::Get((CUtlString *)(iVar1 + 0x10));
      ConMsg("Commencing SourceTV connection retry to %s\n",uVar2);
      iVar1 = CAddressList::Get((CAddressList *)(hltv + 0x240),0);
      uVar2 = CUtlString::Get((CUtlString *)(iVar1 + 0x10));
      uVar2 = va("tv_relay %s\n",uVar2);
      uVar3 = Cbuf_GetCurrentPlayer();
      Cbuf_AddText(uVar3,uVar2,0);
      return;
    }
    ConMsg("Can\'t retry, no previous SourceTV connection\n");
    return;
  }
  ConMsg("SourceTV in Master-Only mode.\n");
  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)