L L4D2node

_GLOBAL__sub_I_net_usesocketsforloopback

0x0009de50 · 2727 bytes · unknown

Decompiled

undefined (0 params)

/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */

void _GLOBAL__sub_I_net_usesocketsforloopback(void)

{
  undefined4 *puVar1;
  undefined4 *puVar2;
  int iVar3;
  
  iVar3 = 1;
  puVar2 = &s_LoopBacks;
  UNSPECIFIED_LOGGING_COLOR._0_1_ = 0;
  UNSPECIFIED_LOGGING_COLOR._1_1_ = 0;
  UNSPECIFIED_LOGGING_COLOR._2_1_ = 0;
  UNSPECIFIED_LOGGING_COLOR._3_1_ = 0;
  vec2_origin._0_4_ = 0;
  vec2_origin._4_4_ = 0;
  vec2_invalid._0_4_ = 0x7f7fffff;
  vec2_invalid._4_4_ = 0x7f7fffff;
  vec4_origin._0_4_ = 0;
  vec4_origin._4_4_ = 0;
  vec4_origin._8_4_ = 0;
  vec4_origin._12_4_ = 0;
  vec4_invalid._0_4_ = 0x7f7fffff;
  vec4_invalid._4_4_ = 0x7f7fffff;
  vec4_invalid._8_4_ = 0x7f7fffff;
  vec4_invalid._12_4_ = 0x7f7fffff;
  ConVar::ConVar((ConVar *)net_showsplits,"net_showsplits","0",0x80000,
                 "Show info about packet splits");
  __cxa_atexit(ConVar::~ConVar,net_showsplits,&__dso_handle);
  ConVar::ConVar((ConVar *)net_showsplit_errors,"net_showsplit_errors","1",0x80000,
                 "Show info about invalid packet split");
  __cxa_atexit(ConVar::~ConVar,net_showsplit_errors,&__dso_handle);
  ConVar::ConVar((ConVar *)net_splitrate,"net_splitrate","1",0x80000,
                 "Number of fragments for a splitpacket that can be sent per frame");
  __cxa_atexit(ConVar::~ConVar,net_splitrate,&__dso_handle);
  ConVar::ConVar((ConVar *)ipname,"ip","localhost",0x80000,"Overrides IP for multihomed hosts");
  __cxa_atexit(ConVar::~ConVar,ipname,&__dso_handle);
  ConVar::ConVar((ConVar *)hostport,"hostport","27015",0x80000,"Host game server port");
  __cxa_atexit(ConVar::~ConVar,hostport,&__dso_handle);
  ConVar::ConVar((ConVar *)hostip,"hostip","",0x80000,"Host game server ip");
  __cxa_atexit(ConVar::~ConVar,hostip,&__dso_handle);
  ConVar::ConVar((ConVar *)net_public_adr,"net_public_adr","",0x80000,
                 "For servers behind NAT/DHCP meant to be exposed to the public internet, this is the public facing ip address string: (\"x.x.x.x\" )"
                );
  __cxa_atexit(ConVar::~ConVar,net_public_adr,&__dso_handle);
  ConVar::ConVar((ConVar *)clientport,"clientport","27005",0x80000,"Host game client port");
  __cxa_atexit(ConVar::~ConVar,clientport,&__dso_handle);
  ConVar::ConVar((ConVar *)hltvport,"tv_port","27020",0x80000,"Host SourceTV port");
  __cxa_atexit(ConVar::~ConVar,hltvport,&__dso_handle);
  ConVar::ConVar((ConVar *)fakelag,"net_fakelag","0",0x4000,
                 "Lag all incoming network data (including loopback) by this many milliseconds.");
  __cxa_atexit(ConVar::~ConVar,fakelag,&__dso_handle);
  ConVar::ConVar((ConVar *)fakeloss,"net_fakeloss","0",0x4000,
                 "Simulate packet loss as a percentage (negative means drop 1/n packets)");
  __cxa_atexit(ConVar::~ConVar,fakeloss,&__dso_handle);
  ConVar::ConVar((ConVar *)droppackets,"net_droppackets","0",0x4000,"Drops next n packets on client"
                );
  __cxa_atexit(ConVar::~ConVar,droppackets,&__dso_handle);
  ConVar::ConVar((ConVar *)fakejitter,"net_fakejitter","0",0x4000,"Jitter fakelag packet time");
  __cxa_atexit(ConVar::~ConVar,fakejitter,&__dso_handle);
  ConVar::ConVar((ConVar *)net_compressvoice,"net_compressvoice","0",0,
                 "Attempt to compress out of band voice payloads (360 only).");
  __cxa_atexit(ConVar::~ConVar,net_compressvoice,&__dso_handle);
  ConVar::ConVar((ConVar *)net_usesocketsforloopback,"net_usesocketsforloopback","0",0,
                 "Use network sockets layer even for listen server local player\'s packets (multiplayer only)."
                );
  __cxa_atexit(ConVar::~ConVar,net_usesocketsforloopback,&__dso_handle);
  ConVar::ConVar((ConVar *)voice_xsend_debug,"voice_xsend_debug","0",0);
  __cxa_atexit(ConVar::~ConVar,voice_xsend_debug,&__dso_handle);
  CUtlMemoryPool::CUtlMemoryPool
            ((CUtlMemoryPool *)loopback_t::s_Allocator,0x808,2,2,"loopback_t pool",0);
  __cxa_atexit(CUtlMemoryPool::~CUtlMemoryPool,loopback_t::s_Allocator,&__dso_handle);
  ConVar::ConVar((ConVar *)sv_maxroutable,"sv_maxroutable","1200",0,
                 "Server upper bound on net_maxroutable that a client can use.",true,576.0,true,
                 1200.0);
  __cxa_atexit(ConVar::~ConVar,sv_maxroutable,&__dso_handle);
  ConVar::ConVar((ConVar *)net_maxroutable,"net_maxroutable","1200",0x280,
                 "Requested max packet size before packets are \'split\'.",true,576.0,true,1200.0);
  __cxa_atexit(ConVar::~ConVar,net_maxroutable,&__dso_handle);
  netadr_s::netadr_s((netadr_s *)&net_local_adr);
  net_sockets = 0;
  _DAT_003ac4e8 = 0;
  _DAT_003ac4ec = 0;
  DAT_003ac4f0 = 0;
  _DAT_003ac4f4 = 0;
  __cxa_atexit(CUtlVector<netsocket_t,CUtlMemory<netsocket_t,int>>::~CUtlVector,&net_sockets,
               &__dso_handle);
  net_packets._0_4_ = 0;
  net_packets._4_4_ = 0;
  net_packets._8_4_ = 0;
  net_packets._12_4_ = 0;
  net_packets._16_4_ = 0;
  __cxa_atexit(CUtlVector<netpacket_s,CUtlMemory<netpacket_s,int>>::~CUtlVector,net_packets,
               &__dso_handle);
  DAT_003ac4b4 = 0;
  s_NetChannels = 0;
  _DAT_003ac4a4 = 0;
  _DAT_003ac4a8 = 0;
  DAT_003ac4ac = 0;
  _DAT_003ac4b0 = 0;
  DAT_003ac4b8 = 0;
  _DAT_003ac4bc = 0;
  _DAT_003ac4c0 = 0;
  __cxa_atexit(CUtlVectorMT<CUtlVector<CNetChan*,CUtlMemory<CNetChan*,int>>,CThreadFastMutex>::
               ~CUtlVectorMT,&s_NetChannels,&__dso_handle);
  DAT_003ac474 = 0;
  s_PendingSockets = 0;
  _DAT_003ac464 = 0;
  _DAT_003ac468 = 0;
  DAT_003ac46c = 0;
  _DAT_003ac470 = 0;
  DAT_003ac478 = 0;
  _DAT_003ac47c = 0;
  _DAT_003ac480 = 0;
  __cxa_atexit(CUtlVectorMT<CUtlVector<pendingsocket_t,CUtlMemory<pendingsocket_t,int>>,CThreadFastMutex>
               ::~CUtlVectorMT,&s_PendingSockets,&__dso_handle);
  do {
    puVar2[4] = 0;
    puVar2[6] = 0;
    puVar2[7] = 0;
    LOCK();
    puVar2[4] = 0;
    UNLOCK();
    puVar2[3] = 0;
    puVar2[1] = 0;
                    /* try { // try from 0009e657 to 0009e65b has its CatchHandler @ 0009e8f7 */
    puVar1 = operator_new(8);
    iVar3 = iVar3 + -1;
    puVar2[2] = puVar1;
    *puVar2 = puVar1;
    *puVar1 = puVar2;
    puVar2 = puVar2 + 8;
  } while (iVar3 != -1);
  __cxa_atexit(__tcf_0,0,&__dso_handle);
  net_splitpackets = 0;
  _DAT_003ac424 = 0;
  _DAT_003ac428 = 0;
  _DAT_003ac42c = 0;
  _DAT_003ac430 = 0;
  __cxa_atexit(CUtlVector<CUtlVector<CSplitPacketEntry,CUtlMemory<CSplitPacketEntry,int>>,CUtlMemory<CUtlVector<CSplitPacketEntry,CUtlMemory<CSplitPacketEntry,int>>,int>>
               ::~CUtlVector,&net_splitpackets,&__dso_handle);
  g_NetScratchBuffers = 0;
  DAT_003ac0e4 = 0;
  __cxa_atexit(CTSPool<net_scratchbuffer_t>::~CTSPool,&g_NetScratchBuffers,&__dso_handle);
  DAT_003ac410 = 0xffff;
  _DAT_003ac412 = 0xffff;
  _DAT_003ac414 = 0xffff;
  _DAT_003ac416 = 0;
  _DAT_003ac418 = 0;
  g_SendQueue = 0;
  _DAT_003ac404 = 0;
  DAT_003ac408 = 0;
  _DAT_003ac40c = 0;
  DAT_003ac41a = 0xffff;
  _DAT_003ac41c = 0;
  __cxa_atexit(SendQueue_t::~SendQueue_t,&g_SendQueue,&__dso_handle);
  ConVar::ConVar((ConVar *)net_splitpacket_maxrate,"net_splitpacket_maxrate","15000",0x80000,
                 "Max bytes per second when queueing splitpacket chunks",true,1000.0,true,30000.0);
  __cxa_atexit(ConVar::~ConVar,net_splitpacket_maxrate,&__dso_handle);
  ConCommand::ConCommand
            ((ConCommand *)net_channels_command,"net_channels",net_channels,"Shows net channel info"
             ,0,(int_____char_const__char *)0x0);
  __cxa_atexit(ConCommand::~ConCommand,net_channels_command,&__dso_handle);
  ConCommand::ConCommand
            ((ConCommand *)net_start_command,"net_start",net_start,
             "Inits multiplayer network sockets",0,(int_____char_const__char *)0x0);
  __cxa_atexit(ConCommand::~ConCommand,net_start_command,&__dso_handle);
  ConCommand::ConCommand
            ((ConCommand *)net_status_command,"net_status",net_status,"Shows current network status"
             ,0,(int_____char_const__char *)0x0);
  __cxa_atexit(ConCommand::~ConCommand,net_status_command,&__dso_handle);
  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.



        
        

⚠ This function has no mangled symbol — it may be internal/static. The Linux gamedata field uses @-prefix symbol resolution which requires an exported mangled name. You'll need a Linux byte signature for this one (extract via extract_signature.java).


          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)