CLogicRelay::InputTrigger
0x006ee160 · 247 bytes · __thiscall
_ZN11CLogicRelay12InputTriggerER11inputdata_t
Decompiled
undefined (2 params)
/* CLogicRelay::InputTrigger(inputdata_t&) */
void __thiscall CLogicRelay::InputTrigger(CLogicRelay *this,inputdata_t *param_1)
{
int *piVar1;
undefined4 *puVar2;
longdouble lVar3;
if ((this[0x474] == (CLogicRelay)0x0) && (this[0x475] == (CLogicRelay)0x0)) {
piVar1 = *(int **)(param_1 + 4);
if (piVar1 == (int *)0x0) {
*(undefined4 *)(this + 0x470) = 0xffffffff;
}
else {
puVar2 = (undefined4 *)(**(code **)(*piVar1 + 0xc))(piVar1);
*(undefined4 *)(this + 0x470) = *puVar2;
}
COutputEvent::FireOutput
((COutputEvent *)(this + 0x440),*(CBaseEntity **)param_1,(CBaseEntity *)this,0.0);
if ((*(uint *)(this + 0x148) & 1) != 0) {
UTIL_Remove((CBaseEntity *)this);
return;
}
if ((*(uint *)(this + 0x148) & 2) == 0) {
this[0x475] = (CLogicRelay)0x1;
lVar3 = (longdouble)CBaseEntityOutput::GetMaxDelay((CBaseEntityOutput *)(this + 0x440));
CEventQueue::AddEvent
((CEventQueue *)g_EventQueue,(CBaseEntity *)this,"EnableRefire",(float)lVar3 + 0.001
,(CBaseEntity *)this,(CBaseEntity *)this,0);
return;
}
}
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.