CPureServerWhitelist::PrintCommand
0x001d6f20 · 341 bytes · __thiscall
_ZN20CPureServerWhitelist12PrintCommandEPKcS1_iPNS_8CCommandE
Decompiled
undefined (5 params)
/* CPureServerWhitelist::PrintCommand(char const*, char const*, int,
CPureServerWhitelist::CCommand*) */
void __thiscall
CPureServerWhitelist::PrintCommand
(CPureServerWhitelist *this,char *param_1,char *param_2,int param_3,CCommand *param_4)
{
int iVar1;
int in_GS_OFFSET;
char *pcVar2;
undefined4 uVar3;
char acStack_125 [261];
int local_20;
pcVar2 = acStack_125 + 1;
uVar3 = 0x104;
local_20 = *(int *)(in_GS_OFFSET + 0x14);
V_strncpy(pcVar2,param_1,0x104);
iVar1 = _V_strlen(pcVar2);
if (0 < iVar1) {
if (acStack_125[iVar1] == '\\') {
acStack_125[iVar1] = '\0';
}
else if (acStack_125[iVar1] == '/') {
acStack_125[iVar1] = '\0';
}
}
if (param_2 == (char *)0x0) {
Msg(&DAT_002c48a3,pcVar2);
}
else {
uVar3 = 0x2f;
Msg("%s%c%s",pcVar2,0x2f,param_2);
}
iVar1 = _V_strlen(param_1);
for (; iVar1 <= param_3 + 5; iVar1 = iVar1 + 1) {
Msg(&DAT_002a5e02,pcVar2,uVar3);
}
Msg(&DAT_002c79d3,pcVar2,uVar3);
if (*param_4 == (CCommand)0x0) {
Msg("from_steam");
}
else if (param_4[1] == (CCommand)0x0) {
Msg("allow_from_disk");
}
else {
Msg("allow_from_disk+check_crc");
}
Msg("\n");
if (local_20 == *(int *)(in_GS_OFFSET + 0x14)) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
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.