show_addon_metadata
0x0015d7c0 · 168 bytes · __cdecl
_ZL19show_addon_metadataRK8CCommand
Decompiled
undefined (1 param)
/* show_addon_metadata(CCommand const&) */
void show_addon_metadata(CCommand *param_1)
{
int iVar1;
int iVar2;
int iVar3;
int iVar4;
if (DAT_0039fab0 == 0) {
Msg("No custom addon files are loaded!\n");
}
iVar4 = 0;
iVar3 = 0;
if (0 < DAT_0039fab0) {
do {
iVar2 = s_vecAddonMetadata + iVar4;
iVar1 = *(int *)(iVar2 + 0x100);
if (iVar1 == 1) {
Msg("MISSION: %s \t(%s)\n",iVar2 + 0x80,iVar2);
}
else if (iVar1 == 0) {
Msg("CONTENT: (%s)\n",iVar2);
}
else if (iVar1 == 2) {
Msg("MODE: %s \t(%s)\n",iVar2 + 0x80,iVar2);
}
iVar3 = iVar3 + 1;
iVar4 = iVar4 + 0x108;
} while (iVar3 < DAT_0039fab0);
}
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.