CResponseQueue::Add
0x005daae0 · 286 bytes · __thiscall
_ZN14CResponseQueue3AddERK11CAI_ConceptPK14AI_CriteriaSetfRKNS_21CFollowupTargetSpec_tEP11CBaseEntity
Decompiled
undefined (6 params)
/* CResponseQueue::Add(CAI_Concept const&, AI_CriteriaSet const*, float,
CResponseQueue::CFollowupTargetSpec_t const&, CBaseEntity*) */
void __thiscall
CResponseQueue::Add(CResponseQueue *this,CAI_Concept *param_1,AI_CriteriaSet *param_2,float param_3,
CFollowupTargetSpec_t *param_4,CBaseEntity *param_5)
{
undefined4 uVar1;
int iVar2;
undefined2 *puVar3;
undefined4 *puVar4;
AI_CriteriaSet *this_00;
puVar3 = (undefined2 *)
CUtlLinkedList<CResponseQueue::CDeferredResponse,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CResponseQueue::CDeferredResponse,int>>>
::AllocInternal((CUtlLinkedList<CResponseQueue::CDeferredResponse,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CResponseQueue::CDeferredResponse,int>>>
*)this,false);
if (puVar3 == (undefined2 *)0x0) {
this_00 = (AI_CriteriaSet *)0x8;
puVar3 = (undefined2 *)0x0;
}
else {
CUtlLinkedList<CResponseQueue::CDeferredResponse,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CResponseQueue::CDeferredResponse,int>>>
::Unlink((CUtlLinkedList<CResponseQueue::CDeferredResponse,int,true,int,CUtlFixedMemory<UtlLinkedListElem_t<CResponseQueue::CDeferredResponse,int>>>
*)this,(int)puVar3);
*(undefined4 *)(puVar3 + 0x1e) = 0;
iVar2 = *(int *)(this + 0x10);
*(int *)(puVar3 + 0x1c) = iVar2;
*(undefined2 **)(this + 0x10) = puVar3;
if (iVar2 == 0) {
*(undefined2 **)(this + 0xc) = puVar3;
}
else {
*(undefined2 **)(iVar2 + 0x3c) = puVar3;
}
*(int *)(this + 0x18) = *(int *)(this + 0x18) + 1;
*(undefined4 *)(puVar3 + 2) = 0xffffffff;
*puVar3 = 0xffff;
this_00 = (AI_CriteriaSet *)(puVar3 + 4);
AI_CriteriaSet::AI_CriteriaSet(this_00);
*(undefined4 *)(puVar3 + 0x16) = 0xffffffff;
*(undefined4 *)(puVar3 + 0x18) = 3;
*(undefined4 *)(puVar3 + 0x1a) = 0xffffffff;
}
*puVar3 = *(undefined2 *)param_1;
uVar1 = *(undefined4 *)(param_1 + 4);
*(float *)(puVar3 + 0x14) = param_3;
*(undefined4 *)(puVar3 + 2) = uVar1;
*(undefined4 *)(puVar3 + 0x18) = *(undefined4 *)param_4;
*(undefined4 *)(puVar3 + 0x1a) = *(undefined4 *)(param_4 + 4);
if (param_5 == (CBaseEntity *)0x0) {
*(undefined4 *)(puVar3 + 0x16) = 0xffffffff;
}
else {
puVar4 = (undefined4 *)(**(code **)(*(int *)param_5 + 0xc))(param_5);
*(undefined4 *)(puVar3 + 0x16) = *puVar4;
}
DeferContextsFromCriteriaSet(this_00,param_2);
return;
}
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.