CEntityDataInstantiator<physicspushlist_t>::CreateDataObject
0x004809e0 · 480 bytes · __thiscall
_ZN23CEntityDataInstantiatorI17physicspushlist_tE16CreateDataObjectEPK11CBaseEntity
Decompiled
undefined (2 params)
/* CEntityDataInstantiator<physicspushlist_t>::CreateDataObject(CBaseEntity const*) */
undefined4 __thiscall
CEntityDataInstantiator<physicspushlist_t>::CreateDataObject
(CEntityDataInstantiator<physicspushlist_t> *this,CBaseEntity *param_1)
{
char cVar1;
uint uVar2;
void *pvVar3;
int *piVar4;
undefined4 *puVar5;
int iVar6;
CUtlVector<CEntityDataInstantiator<physicspushlist_t>::HashEntry,CUtlMemory<CEntityDataInstantiator<physicspushlist_t>::HashEntry,int>>
*this_00;
uint uVar7;
int iVar8;
uint local_34;
CBaseEntity *local_24;
undefined4 local_20;
local_20 = 0;
local_24 = param_1;
local_34 = (**(code **)(this + 0x1c))(&local_24);
if (this[0x20] == (CEntityDataInstantiator<physicspushlist_t>)0x0) {
local_34 = local_34 % *(uint *)(this + 0x10);
}
else {
local_34 = local_34 & *(uint *)(this + 0x24);
}
uVar7 = 0;
piVar4 = (int *)(*(int *)(this + 4) + local_34 * 0x14);
uVar2 = piVar4[3];
if ((int)uVar2 < 1) {
LAB_00480a4e:
if ((uVar2 != uVar7) && (uVar2 = local_34 << 0x10 | uVar7, uVar2 != 0xffffffff)) {
iVar6 = (uVar7 & 0xffff) * 8;
iVar8 = (uVar2 >> 0x10) * 0x14;
goto LAB_00480a75;
}
}
else {
do {
cVar1 = (**(code **)(this + 0x18))(*piVar4 + uVar7 * 8,&local_24);
if (cVar1 != '\0') goto LAB_00480a4e;
uVar7 = uVar7 + 1;
} while (uVar7 != uVar2);
}
local_34 = (**(code **)(this + 0x1c))(&local_24);
if (this[0x20] == (CEntityDataInstantiator<physicspushlist_t>)0x0) {
local_34 = local_34 % *(uint *)(this + 0x10);
}
else {
local_34 = local_34 & *(uint *)(this + 0x24);
}
uVar7 = 0;
piVar4 = (int *)(*(int *)(this + 4) + local_34 * 0x14);
uVar2 = piVar4[3];
if ((int)uVar2 < 1) {
LAB_00480b05:
if (uVar2 == uVar7) goto LAB_00480b8c;
}
else {
do {
cVar1 = (**(code **)(this + 0x18))(*piVar4 + uVar7 * 8,&local_24);
if (cVar1 != '\0') goto LAB_00480b05;
uVar7 = uVar7 + 1;
} while (uVar7 != uVar2);
LAB_00480b8c:
this_00 = (CUtlVector<CEntityDataInstantiator<physicspushlist_t>::HashEntry,CUtlMemory<CEntityDataInstantiator<physicspushlist_t>::HashEntry,int>>
*)(local_34 * 0x14 + *(int *)(this + 4));
uVar7 = *(uint *)(this_00 + 0xc);
CUtlVector<CEntityDataInstantiator<physicspushlist_t>::HashEntry,CUtlMemory<CEntityDataInstantiator<physicspushlist_t>::HashEntry,int>>
::GrowVector(this_00,1);
CUtlVector<CEntityDataInstantiator<physicspushlist_t>::HashEntry,CUtlMemory<CEntityDataInstantiator<physicspushlist_t>::HashEntry,int>>
::ShiftElementsRight(this_00,uVar7,1);
puVar5 = (undefined4 *)(*(int *)this_00 + uVar7 * 8);
if (puVar5 != (undefined4 *)0x0) {
*puVar5 = local_24;
puVar5[1] = local_20;
}
}
pvVar3 = ::operator_new(0x220);
puVar5 = (undefined4 *)((int)pvVar3 + 0x20);
do {
*puVar5 = 0xffffffff;
puVar5 = puVar5 + 1;
} while (puVar5 != (undefined4 *)((int)pvVar3 + 0xa0));
iVar6 = (uVar7 & 0xffff) * 8;
iVar8 = ((local_34 << 0x10 | uVar7) >> 0x10) * 0x14;
*(void **)(*(int *)(*(int *)(this + 4) + iVar8) + 4 + iVar6) = pvVar3;
_V_memset(*(void **)(*(int *)(*(int *)(this + 4) + iVar8) + 4 + iVar6),0,0x220);
LAB_00480a75:
return *(undefined4 *)(*(int *)(*(int *)(this + 4) + iVar8) + 4 + iVar6);
}
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.