CBuildNumber::ComputeBuildNumber
0x00113ce0 · 193 bytes · __thiscall
_ZN12CBuildNumber18ComputeBuildNumberEv
Decompiled
undefined (1 param)
/* CBuildNumber::ComputeBuildNumber() */
void __thiscall CBuildNumber::ComputeBuildNumber(CBuildNumber *this)
{
char *pcVar1;
int iVar2;
long lVar3;
uint uVar4;
int iVar5;
int iVar6;
iVar6 = 0;
iVar5 = 0;
do {
iVar2 = V_strncasecmp(date,(&mon)[iVar5],3);
if (iVar2 == 0) break;
pcVar1 = &mond + iVar5;
iVar5 = iVar5 + 1;
iVar6 = iVar6 + *pcVar1;
} while (iVar5 != 0xb);
lVar3 = strtol(date + 4,(char **)0x0,10);
uVar4 = strtol(date + 7,(char **)0x0,10);
iVar6 = (int)((double)(int)(uVar4 - 0x76d) * 365.25) + iVar6 + -1 + lVar3;
*(int *)this = iVar6;
if ((uVar4 & 3) == 0) {
iVar6 = iVar6 + (uint)(1 < iVar5);
}
*(int *)this = iVar6 + -0x8b9b;
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.