CDispInfo::ClearShadowDecalFragments
0x001380b0 · 179 bytes · __thiscall
_ZN9CDispInfo25ClearShadowDecalFragmentsEt
Decompiled
undefined (2 params)
/* CDispInfo::ClearShadowDecalFragments(unsigned short) */
void __thiscall CDispInfo::ClearShadowDecalFragments(CDispInfo *this,ushort param_1)
{
int iVar1;
ushort uVar2;
ushort uVar3;
int iVar4;
iVar1 = (uint)param_1 * 0x1c + s_DispShadowDecals;
uVar2 = *(ushort *)(iVar1 + 0x14);
while (uVar3 = uVar2, uVar3 != 0xffff) {
uVar2 = *(ushort *)(s_DispShadowFragments + 10 + (uint)uVar3 * 0xc);
CUtlLinkedList<CDispShadowFragment,unsigned_short,true,unsigned_short,CUtlMemory<UtlLinkedListElem_t<CDispShadowFragment,unsigned_short>,unsigned_short>>
::Unlink((CUtlLinkedList<CDispShadowFragment,unsigned_short,true,unsigned_short,CUtlMemory<UtlLinkedListElem_t<CDispShadowFragment,unsigned_short>,unsigned_short>>
*)&s_DispShadowFragments,uVar3);
iVar4 = (uint)uVar3 * 0xc + s_DispShadowFragments;
if (*(void **)(iVar4 + 4) != (void *)0x0) {
operator_delete__(*(void **)(iVar4 + 4));
}
*(undefined4 *)(iVar4 + 4) = 0;
*(ushort *)(iVar4 + 10) = DAT_0039eca0;
DAT_0039eca0 = uVar3;
}
*(byte *)(iVar1 + 0xc) = *(byte *)(iVar1 + 0xc) & 0xf7;
*(undefined2 *)(iVar1 + 0x14) = 0xffff;
*(undefined2 *)(iVar1 + 0x10) = 0;
*(undefined2 *)(iVar1 + 0xe) = 0;
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.