DetermineDlcRequiredMask
0x00038960 · 330 bytes · __regparm3
_ZL24DetermineDlcRequiredMaskP9KeyValues
Decompiled
undefined (1 param)
/* DetermineDlcRequiredMask(KeyValues*) */
ulonglong __regparm3 DetermineDlcRequiredMask(KeyValues *param_1)
{
code *pcVar1;
undefined4 uVar2;
char *pcVar3;
KeyValues *this;
ulonglong uVar4;
ulonglong uVar5;
ulonglong uVar6;
char *pcVar7;
undefined *puVar8;
char *local_20 [4];
pcVar1 = *(code **)(*(int *)g_pMatchExtL4D + 0x10);
uVar2 = KeyValues::GetString(param_1,"game/mode","");
pcVar3 = (char *)(*pcVar1)(g_pMatchExtL4D,uVar2);
uVar2 = 0;
uVar4 = KeyValues::GetUint64(pcVar3,0xb0b8f);
local_20[0] = (char *)0x0;
pcVar3 = (char *)(**(code **)(*(int *)g_pMatchExtL4D + 8))(g_pMatchExtL4D,param_1,local_20,uVar2);
if (pcVar3 != (char *)0x0) {
uVar5 = KeyValues::GetUint64(local_20[0],0xb0b8f);
uVar2 = 0;
uVar6 = KeyValues::GetUint64(pcVar3,0xb0b8f);
uVar4 = uVar5 | uVar6 | uVar4;
}
puVar8 = &DAT_000b2b65;
pcVar7 = "game/campaign";
pcVar3 = (char *)KeyValues::GetString(param_1,"game/campaign","");
if (*pcVar3 != '\0') {
this = (KeyValues *)
(*(code *)**(undefined4 **)g_pMatchExtL4D)(g_pMatchExtL4D,pcVar7,puVar8,uVar2);
pcVar3 = (char *)KeyValues::FindKey(this,pcVar3,false);
uVar5 = KeyValues::GetUint64(pcVar3,0xb0b8f);
uVar4 = uVar5 | uVar4;
}
return uVar4;
}
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.