CScriptSpeechQueue::Add
0x005daf90 · 172 bytes · __thiscall
_ZN18CScriptSpeechQueue3AddEP9HSCRIPT__S1_fP11CBaseEntityP14AI_CriteriaSet
Decompiled
undefined (6 params)
/* CScriptSpeechQueue::Add(HSCRIPT__*, HSCRIPT__*, float, CBaseEntity*, AI_CriteriaSet*) */
void __thiscall
CScriptSpeechQueue::Add
(CScriptSpeechQueue *this,HSCRIPT__ *param_1,HSCRIPT__ *param_2,float param_3,
CBaseEntity *param_4,AI_CriteriaSet *param_5)
{
int iVar1;
CQueuedScriptEvent *this_00;
CQueuedScriptEvent local_4c [60];
CQueuedScriptEvent::CQueuedScriptEvent(local_4c,param_1,param_2,param_3,param_4,param_5);
/* try { // try from 005dafd9 to 005db02a has its CatchHandler @ 005db045 */
this_00 = (CQueuedScriptEvent *)
CUtlLinkedList<CScriptSpeechQueue::CQueuedScriptEvent,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CScriptSpeechQueue::CQueuedScriptEvent,int>>>
::AllocInternal((CUtlLinkedList<CScriptSpeechQueue::CQueuedScriptEvent,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CScriptSpeechQueue::CQueuedScriptEvent,int>>>
*)this,false);
if (this_00 == (CQueuedScriptEvent *)0x0) {
CQueuedScriptEvent::~CQueuedScriptEvent(local_4c);
return;
}
CUtlLinkedList<CScriptSpeechQueue::CQueuedScriptEvent,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CScriptSpeechQueue::CQueuedScriptEvent,int>>>
::Unlink((CUtlLinkedList<CScriptSpeechQueue::CQueuedScriptEvent,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CScriptSpeechQueue::CQueuedScriptEvent,int>>>
*)this,(int)this_00);
*(undefined4 *)(this_00 + 0x34) = 0;
iVar1 = *(int *)(this + 0x10);
*(int *)(this_00 + 0x30) = iVar1;
*(CQueuedScriptEvent **)(this + 0x10) = this_00;
if (iVar1 == 0) {
*(CQueuedScriptEvent **)(this + 0xc) = this_00;
}
else {
*(CQueuedScriptEvent **)(iVar1 + 0x34) = this_00;
}
*(int *)(this + 0x18) = *(int *)(this + 0x18) + 1;
CQueuedScriptEvent::CQueuedScriptEvent(this_00,local_4c);
CQueuedScriptEvent::~CQueuedScriptEvent(local_4c);
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.