CSPSharedMemoryManager::~CSPSharedMemoryManager
0x001db470 · 136 bytes · __thiscall
_ZN22CSPSharedMemoryManagerD2Ev
Decompiled
undefined (1 param)
/* CSPSharedMemoryManager::~CSPSharedMemoryManager() */
void __thiscall CSPSharedMemoryManager::~CSPSharedMemoryManager(CSPSharedMemoryManager *this)
{
int iVar1;
undefined4 uVar2;
undefined4 uVar3;
undefined4 uVar4;
int iVar5;
int iVar6;
iVar5 = *(int *)(this + 0xc) + -1;
iVar6 = iVar5 * 4;
if (-1 < iVar5) {
do {
iVar5 = iVar5 + -1;
iVar1 = *(int *)(*(int *)this + iVar6);
iVar6 = iVar6 + -4;
uVar2 = *(undefined4 *)(iVar1 + 0x20);
uVar3 = *(undefined4 *)(iVar1 + 0x14);
uVar4 = CUtlString::Get((CUtlString *)(iVar1 + 4));
Warning("Shared memory space %s (%i) still has %i references.\n",uVar4,uVar3,uVar2);
} while (iVar5 != -1);
}
*(undefined4 *)(this + 0xc) = 0;
CUtlMemory<CSPSharedMemory*,int>::Purge((CUtlMemory<CSPSharedMemory*,int> *)this);
*(undefined4 *)(this + 0x10) = *(undefined4 *)this;
CUtlMemory<CSPSharedMemory*,int>::Purge((CUtlMemory<CSPSharedMemory*,int> *)this);
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.