DmeTime_t::CurrentFrame
0x00bf1500 · 209 bytes · __thiscall
_ZNK9DmeTime_t12CurrentFrameE14DmeFramerate_t12RoundStyle_t
Decompiled
undefined (3 params)
/* DmeTime_t::CurrentFrame(DmeFramerate_t, RoundStyle_t) const */
void __thiscall DmeTime_t::CurrentFrame(DmeTime_t *this,ushort *param_2,int param_3)
{
ushort uVar1;
longlong lVar2;
uint uVar3;
uint uVar4;
uint uVar5;
uVar1 = param_2[1];
uVar5 = (uint)uVar1;
uVar3 = (uint)*param_2;
lVar2 = (longlong)(int)uVar3 * (longlong)*(int *)this;
if (*(int *)this < 0) {
if (param_3 == 0) {
lVar2 = (lVar2 - (ulonglong)(uVar1 >> 1)) + (ulonglong)uVar3;
}
else if (param_3 == 1) {
uVar4 = (uint)lVar2 - uVar5;
lVar2 = CONCAT44(((int)((ulonglong)lVar2 >> 0x20) - (uint)((uint)lVar2 < uVar5)) +
(uint)CARRY4(uVar4,uVar3),uVar4 + uVar3);
}
}
else {
if (param_3 == 0) {
__divdi3(lVar2 + (ulonglong)(uVar1 >> 1),uVar5,0);
return;
}
if (param_3 == 2) {
uVar4 = (uint)(lVar2 + (ulonglong)uVar5);
lVar2 = CONCAT44((int)(lVar2 + (ulonglong)uVar5 >> 0x20) - (uint)(uVar4 < uVar3),uVar4 - uVar3
);
}
else if (param_3 == 1) {
lVar2 = lVar2 + (ulonglong)uVar3;
}
}
__divdi3(lVar2,uVar5,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.