CFuncElevator::StopMoveSoundThink
0x006be870 · 517 bytes · __thiscall
_ZN13CFuncElevator18StopMoveSoundThinkEv
Decompiled
undefined (1 param)
/* CFuncElevator::StopMoveSoundThink() */
void __thiscall CFuncElevator::StopMoveSoundThink(CFuncElevator *this)
{
char *pcVar1;
char *pcVar2;
CFuncElevator *pCVar3;
int iVar4;
int *piVar5;
undefined1 local_94 [20];
undefined **local_80 [8];
undefined4 local_60;
char *local_5c;
undefined4 local_58;
undefined4 local_54;
undefined4 local_50;
undefined4 local_4c;
undefined4 local_48;
undefined4 local_44;
undefined4 local_40;
undefined1 local_3c;
undefined1 local_3b;
undefined1 local_3a;
undefined4 local_38;
undefined4 local_34;
undefined4 local_30;
undefined4 local_2c;
undefined4 local_28;
undefined4 local_24;
undefined2 local_20;
pCVar3 = this + 0x4bc;
if (this[0x508] == (CFuncElevator)0x0) {
pCVar3 = this + 0x4c0;
}
pcVar1 = *(char **)pCVar3;
pcVar2 = *(char **)(this + 0x4c4);
if (pcVar2 != (char *)0x0) {
piVar5 = (int *)&stack0xffffff54;
if (pcVar1 == pcVar2) goto LAB_006bea2a;
if (*(int *)(this + 0x30) == 0) {
iVar4 = 0;
}
else {
iVar4 = *(int *)(this + 0x30) - *(int *)(gpGlobals + 0x58) >> 4;
}
CBaseEntity::StopSound(iVar4,4,pcVar2);
}
piVar5 = (int *)&stack0xffffff54;
if ((pcVar1 != (char *)0x0) &&
(piVar5 = (int *)&stack0xffffff54, pcVar1 != *(char **)(this + 0x4c4))) {
*(char **)(this + 0x4c4) = pcVar1;
(**(code **)(*(int *)this + 0x28c))();
CRecipientFilter::CRecipientFilter((CRecipientFilter *)local_80);
local_80[0] = &PTR__CPASFilter_00bfaf28;
/* try { // try from 006be91f to 006be923 has its CatchHandler @ 006bead9 */
CRecipientFilter::AddRecipientsByPAS((CRecipientFilter *)local_80,(Vector *)&local_60);
local_80[0] = &PTR__CPASAttenuationFilter_00c08ec8;
/* try { // try from 006be937 to 006be956 has its CatchHandler @ 006beac0 */
(**(code **)(*(int *)this + 0x28c))();
piVar5 = (int *)&stack0xffffff4c;
CPASAttenuationFilter::Filter((CPASAttenuationFilter *)local_80,(Vector *)&local_60,0.8);
local_58 = 0x3f800000;
local_20 = 0xffff;
local_50 = 0;
local_4c = 100;
local_48 = 0;
local_44 = 0;
local_40 = 0;
local_3c = 1;
local_3b = 0;
local_3a = 0;
local_38 = 0xffffffff;
local_34 = 0;
local_30 = 0;
local_2c = 0;
local_28 = 0;
local_24 = 0;
local_60 = 4;
local_54 = 0x4b;
if (*(int *)(this + 0x30) == 0) {
iVar4 = 0;
}
else {
iVar4 = *(int *)(this + 0x30) - *(int *)(gpGlobals + 0x58) >> 4;
}
local_5c = pcVar1;
/* try { // try from 006be9f6 to 006be9fa has its CatchHandler @ 006bea87 */
CBaseEntity::EmitSound((IRecipientFilter *)local_80,iVar4,(EmitSound_t *)&local_60);
local_28 = 0;
CUtlMemory<Vector,int>::Purge((CUtlMemory<Vector,int> *)&local_34);
local_24 = local_34;
CUtlMemory<Vector,int>::Purge((CUtlMemory<Vector,int> *)&local_34);
local_80[0] = &PTR__CPASFilter_00bfaf28;
CRecipientFilter::~CRecipientFilter((CRecipientFilter *)local_80);
}
LAB_006bea2a:
piVar5[1] = (int)this;
piVar5[5] = 0;
piVar5[4] = 0;
piVar5[2] = 0;
piVar5[3] = 0;
*piVar5 = (int)local_94;
piVar5[-1] = 0x6bea5c;
CBaseEntity::ThinkSet((_func_void *)*piVar5,(float)piVar5[1],(char *)piVar5[2]);
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.