CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>::NewNode
0x005f9de0 · 278 bytes · __thiscall
_ZN10CUtlRBTreeI22VisibilityCacheEntry_tt25CVisibilityCacheEntryLess10CUtlMemoryI15UtlRBTreeNode_tIS0_tEtEE7NewNodeEv
Decompiled
undefined (1 param)
/* CUtlRBTree<VisibilityCacheEntry_t, unsigned short, CVisibilityCacheEntryLess,
CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t, unsigned short>, unsigned short> >::NewNode()
*/
void __thiscall
CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>
::NewNode(CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>
*this)
{
uint uVar1;
undefined2 uVar2;
int iVar3;
uint uVar4;
int iVar5;
if (*(ushort *)(this + 0x14) != 0xffff) {
iVar3 = *(int *)(this + 4);
iVar5 = iVar3 + (uint)*(ushort *)(this + 0x14) * 0x18;
*(undefined2 *)(this + 0x14) = *(undefined2 *)(iVar5 + 2);
goto LAB_005f9e0a;
}
iVar5 = *(int *)(this + 8);
if ((int)(uint)*(ushort *)(this + 0x16) < iVar5) {
uVar4 = *(ushort *)(this + 0x16) + 1;
uVar1 = uVar4 & 0xffff;
if (iVar5 <= (int)uVar1) {
uVar1 = 0xffff;
uVar4 = 0xffff;
}
if (iVar5 <= (int)uVar1) goto LAB_005f9e87;
LAB_005f9e51:
uVar2 = (undefined2)uVar4;
iVar5 = (uVar4 & 0xffff) * 0x18;
}
else {
iVar3 = 0xffff;
if (0 < iVar5) {
iVar3 = 0;
}
uVar4 = (0 < iVar5) - 1;
if (iVar3 < iVar5) goto LAB_005f9e51;
LAB_005f9e87:
CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>::Grow
((CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short> *)
(this + 4),1);
iVar3 = *(int *)(this + 8);
uVar2 = 0xffff;
if ((int)(uint)*(ushort *)(this + 0x16) < iVar3) {
uVar1 = *(ushort *)(this + 0x16) + 1;
uVar2 = (undefined2)uVar1;
uVar1 = uVar1 & 0xffff;
if ((int)uVar1 < iVar3) {
iVar5 = uVar1 * 0x18;
}
else {
iVar5 = 0x17ffe8;
uVar1 = 0xffff;
uVar2 = 0xffff;
}
}
else {
uVar1 = 0;
iVar5 = 0x17ffe8;
if (iVar3 < 1) {
uVar1 = 0xffff;
}
else {
iVar5 = 0;
uVar2 = 0;
}
}
if (iVar3 <= (int)uVar1) {
Error("CUtlRBTree overflow!\n");
}
}
iVar3 = *(int *)(this + 4);
*(undefined2 *)(this + 0x16) = uVar2;
iVar5 = iVar3 + iVar5;
LAB_005f9e0a:
if (iVar5 != -8) {
*(undefined4 *)(iVar5 + 0x10) = 0xffffffff;
iVar3 = *(int *)(this + 4);
}
*(int *)(this + 0x18) = iVar3;
return;
}
SourceMod gamedata
paste intoaddons/sourcemod/gamedata/<your_plugin>.txt
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.
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.