CWin32UploadGameStats::CWin32UploadGameStats
0x00213a20 · 560 bytes · __thiscall
_ZN21CWin32UploadGameStatsC1ERK8netadr_sRK20TGameStatsParametersj
Decompiled
undefined (4 params)
/* CWin32UploadGameStats::CWin32UploadGameStats(netadr_s const&, TGameStatsParameters const&,
unsigned int) */
void __thiscall
CWin32UploadGameStats::CWin32UploadGameStats
(CWin32UploadGameStats *this,netadr_s *param_1,TGameStatsParameters *param_2,uint param_3)
{
undefined4 local_84;
code *local_80;
undefined4 local_7c;
undefined4 local_78;
code *local_74;
undefined4 local_70;
undefined4 local_6c;
code *local_68;
undefined4 local_64;
undefined4 local_60;
code *local_5c;
undefined4 local_58;
undefined4 local_54;
code *local_50;
undefined4 local_4c;
undefined4 local_48;
code *local_44;
undefined4 local_40;
undefined4 local_3c;
code *local_38;
undefined4 local_34;
undefined4 local_30;
code *local_2c;
undefined4 local_28;
undefined4 local_24;
code *local_20;
undefined4 local_1c;
undefined4 local_18;
code *local_14;
undefined4 local_10;
*(undefined4 *)this = 0;
*(TGameStatsParameters **)(this + 0x2c) = param_2;
*(undefined4 *)(this + 4) = 0;
*(undefined4 *)(this + 8) = 0;
*(undefined4 *)(this + 0xc) = 0;
*(uint *)(this + 0x30) = param_3;
*(undefined4 *)(this + 0x10) = 0;
*(undefined4 *)(this + 0x14) = 0;
*(undefined4 *)(this + 0x18) = 0;
*(undefined4 *)(this + 0x1c) = 0;
*(undefined4 *)(this + 0x20) = 0;
*(undefined4 *)(this + 0x24) = 0;
*(undefined4 *)(this + 0x28) = 0;
/* try { // try from 00213a93 to 00213c45 has its CatchHandler @ 00213c50 */
netadr_s::ToSockadr(param_1,(sockaddr *)(this + 0x18));
local_84 = 0;
local_80 = CreateTCPSocket;
local_7c = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_84);
local_78 = 1;
local_74 = ConnectToHarvesterServer;
local_70 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_78);
local_6c = 2;
local_68 = SendProtocolVersion;
local_64 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_6c);
local_60 = 3;
local_5c = ReceiveProtocolOkay;
local_58 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_60);
local_54 = 4;
local_50 = SendUploadCommand;
local_4c = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_54);
local_48 = 5;
local_44 = ReceiveOKToSendFile;
local_40 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_48);
local_3c = 6;
local_38 = SendWholeFile;
local_34 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_3c);
local_30 = 7;
local_2c = ReceiveFileUploadSuccess;
local_28 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_30);
local_24 = 8;
local_20 = SendGracefulClose;
local_1c = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_24);
local_18 = 9;
local_14 = CloseTCPSocket;
local_10 = 0;
CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>::
InsertBefore((CUtlVector<CWin32UploadGameStats::FSMState_t,CUtlMemory<CWin32UploadGameStats::FSMState_t,int>>
*)this,*(int *)(this + 0xc),(FSMState_t *)&local_18);
return;
}
SourceMod gamedata
paste intoaddons/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.
Signatures + Functions block. The plugin uses
DHookCreateFromConf - DHooks reads return type, this-type,
calling convention, and argument types straight from the gamedata. Less
boilerplate in the plugin, types travel with the gamedata.
Gamedata KeyValues
DHooks plugin example
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.