CCollisionEvent::DeltaTimeSinceLastFluid
0x0077e590 · 272 bytes · __thiscall
_ZN15CCollisionEvent23DeltaTimeSinceLastFluidEP11CBaseEntity
Decompiled
undefined (2 params)
/* CCollisionEvent::DeltaTimeSinceLastFluid(CBaseEntity*) */
longdouble __thiscall
CCollisionEvent::DeltaTimeSinceLastFluid(CCollisionEvent *this,CBaseEntity *param_1)
{
uint uVar1;
undefined4 *puVar2;
uint *puVar3;
int iVar4;
undefined *puVar5;
undefined4 *puVar6;
iVar4 = *(int *)(this + 0x140) + -1;
if (-1 < iVar4) {
puVar3 = (uint *)(*(int *)(this + 0x134) + iVar4 * 8);
do {
uVar1 = *puVar3;
if (((uVar1 == 0xffffffff) ||
(puVar5 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar5 == (undefined *)0xfffffffc)) ||
(*(uint *)(puVar5 + 8) != uVar1 >> 0xc)) {
if (param_1 == (CBaseEntity *)0x0) goto LAB_0077e610;
}
else if (param_1 == *(CBaseEntity **)(puVar5 + 4)) {
LAB_0077e610:
return (longdouble)(*(float *)(gpGlobals + 0xc) - (float)puVar3[1]);
}
iVar4 = iVar4 + -1;
puVar3 = puVar3 + -2;
} while (iVar4 != -1);
}
iVar4 = CUtlVector<fluidevent_t,CUtlMemory<fluidevent_t,int>>::InsertBefore
((CUtlVector<fluidevent_t,CUtlMemory<fluidevent_t,int>> *)(this + 0x134),
*(int *)(this + 0x140));
puVar6 = (undefined4 *)(*(int *)(this + 0x134) + iVar4 * 8);
if (param_1 == (CBaseEntity *)0x0) {
*puVar6 = 0xffffffff;
}
else {
puVar2 = (undefined4 *)(**(code **)(*(int *)param_1 + 0xc))(param_1);
*puVar6 = *puVar2;
}
*(undefined4 *)(*(int *)(this + 0x134) + 4 + iVar4 * 8) = *(undefined4 *)(gpGlobals + 0xc);
return (longdouble)2.0;
}
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.