CMultiPlayerAnimState::DebugShowAnimStateForPlayer
0x0046d290 · 1889 bytes · __thiscall
_ZN21CMultiPlayerAnimState27DebugShowAnimStateForPlayerEb
Decompiled
undefined (2 params)
/* CMultiPlayerAnimState::DebugShowAnimStateForPlayer(bool) */
void __thiscall
CMultiPlayerAnimState::DebugShowAnimStateForPlayer(CMultiPlayerAnimState *this,bool param_1)
{
CBaseEntity *pCVar1;
char *pcVar2;
char *pcVar3;
char *pcVar4;
char *pcVar5;
int iVar6;
int iVar7;
CBaseEntity *pCVar8;
undefined4 uVar9;
longdouble lVar10;
double dVar11;
double dVar12;
double dVar13;
double dVar14;
double dVar15;
double dVar16;
undefined8 uVar17;
int local_a4;
int local_a0;
int local_9c;
int local_98;
int local_94;
int local_90;
int local_8c;
int local_88;
int local_84;
int local_80;
float local_7c;
float local_78;
float local_70;
float local_6c;
float local_68;
undefined4 local_64;
undefined4 local_60;
undefined4 local_5c;
float local_58;
float local_54;
float local_50;
Vector local_4c [12];
Vector local_40 [12];
float local_34;
float local_30;
float local_2c;
float local_28;
float local_24;
float local_20;
GetOuterAbsVelocity(this,(Vector *)&local_7c);
if (param_1) {
local_84 = 0x13;
iVar7 = 0x11;
pcVar5 = "Server";
local_a4 = 0x1b;
local_a0 = 0x1a;
local_9c = 0x19;
iVar6 = *(int *)(*(int *)(this + 0x1c) + 0x30);
local_98 = 0x18;
uVar9 = *(undefined4 *)(gpGlobals + 4);
local_94 = 0x17;
local_90 = 0x16;
local_8c = 0x15;
local_80 = 0x12;
local_88 = 0x14;
if (iVar6 != 0) goto LAB_0046d339;
LAB_0046d976:
iVar6 = 0;
}
else {
local_84 = 7;
iVar7 = 5;
pcVar5 = "Client";
local_a4 = 0xf;
local_a0 = 0xe;
local_9c = 0xd;
iVar6 = *(int *)(*(int *)(this + 0x1c) + 0x30);
local_98 = 0xc;
uVar9 = *(undefined4 *)(gpGlobals + 4);
local_94 = 0xb;
local_90 = 10;
local_8c = 9;
local_80 = 6;
local_88 = 8;
if (iVar6 == 0) goto LAB_0046d976;
LAB_0046d339:
iVar6 = iVar6 - *(int *)(gpGlobals + 0x58) >> 4;
}
Anim_StatePrintf(iVar7,"------------- (%d) %s: frame %d -----------------\n",iVar6,pcVar5,uVar9);
pCVar8 = *(CBaseEntity **)(this + 0x1c);
if (((byte)pCVar8[0x14d] & 8) == 0) {
dVar12 = (double)*(float *)(pCVar8 + 0x2e8);
}
else {
CBaseEntity::CalcAbsolutePosition(pCVar8);
pCVar1 = pCVar8 + 0x2e8;
pCVar8 = *(CBaseEntity **)(this + 0x1c);
dVar12 = (double)*(float *)pCVar1;
if (((byte)pCVar8[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(pCVar8);
pCVar1 = pCVar8 + 0x2e4;
pCVar8 = *(CBaseEntity **)(this + 0x1c);
dVar11 = (double)*(float *)pCVar1;
if (((byte)pCVar8[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(pCVar8);
}
goto LAB_0046d381;
}
}
dVar11 = (double)*(float *)(pCVar8 + 0x2e4);
LAB_0046d381:
pcVar5 = "ACT_MP_GESTURE_VC_NODYES";
Anim_StatePrintf(local_80,"Location: %2.2f %2.2f %2.2f\n",(double)*(float *)(pCVar8 + 0x2e0),
dVar11,dVar12);
lVar10 = (longdouble)(**(code **)(*(int *)this + 0x6c))(this);
Anim_StatePrintf(local_84,"Time: %.2f, Speed: %.2f, MaxSpeed: %.2f",
(double)*(float *)(gpGlobals + 0xc),
(double)SQRT(local_78 * local_78 + local_7c * local_7c),(double)(float)lVar10);
Anim_StatePrintf(local_88,"Head Yaw: %.2f, Head Pitch: %.2f",(double)*(float *)(this + 0x8c),
(double)*(float *)(this + 0x88));
Anim_StatePrintf(local_8c,"Body Yaw: %.2f, Body Pitch: %.2f",(double)*(float *)(this + 0x94),
(double)*(float *)(this + 0x90));
dVar11 = (double)*(float *)(this + 0xd8);
dVar14 = (double)*(float *)(this + 0xd4);
dVar16 = (double)*(float *)(this + 200);
dVar12 = (double)*(float *)(this + 0xc4);
dVar13 = (double)*(float *)(this + 0xc0);
dVar15 = (double)*(float *)(this + 0xbc);
Anim_StatePrintf(local_90,
"Walk: (%.2f, %.2f), Run: (%.2f, %.2f), Crouch: (%.2f, %.2f), Dismount: %.2f, Tongue: %.2f"
,(double)*(float *)(this + 0xb4),(double)*(float *)(this + 0xb8),dVar15,dVar13,
dVar12,dVar16,dVar14,dVar11);
pcVar2 = "ACT_MP_GESTURE_VC_NODYES";
if (this[0xa0] == (CMultiPlayerAnimState)0x0) {
pcVar2 = "ACT_MP_GESTURE_VC_NODNO";
}
uVar9 = (undefined4)((ulonglong)dVar15 >> 0x20);
uVar17 = CONCAT44(uVar9,pcVar2 + 0x15);
Anim_StatePrintf(local_94,"Foot Current: %.2f, Goal: %.2f, Backpedaling: %s",
(double)*(float *)(this + 0x98),(double)*(float *)(this + 0x9c),pcVar2 + 0x15,
uVar9,dVar13,dVar12,dVar16,dVar14,dVar11);
dVar15 = (double)*(float *)(this + 0xa8);
Anim_StatePrintf(local_98,"EyeFootDelta: %.2f, EyeGoalDelta: %.2f",(double)*(float *)(this + 0xa4)
,dVar15);
pcVar2 = "ACT_MP_GESTURE_VC_NODYES";
pcVar3 = "ACT_MP_GESTURE_VC_NODYES";
pcVar4 = "ACT_MP_GESTURE_VC_NODYES";
if (this[0xae] == (CMultiPlayerAnimState)0x0) {
pcVar2 = "ACT_MP_GESTURE_VC_NODNO";
}
if (this[0xad] == (CMultiPlayerAnimState)0x0) {
pcVar3 = "ACT_MP_GESTURE_VC_NODNO";
}
uVar9 = (undefined4)((ulonglong)dVar15 >> 0x20);
if (this[0xac] == (CMultiPlayerAnimState)0x0) {
pcVar4 = "ACT_MP_GESTURE_VC_NODNO";
}
Anim_StatePrintf(local_9c,"Jumping: %s, Falling: %s, InAir: %s",pcVar4 + 0x15,pcVar3 + 0x15,
pcVar2 + 0x15,uVar9,uVar17,dVar13,dVar12,dVar16,dVar14,dVar11);
pcVar2 = "ACT_MP_GESTURE_VC_NODYES";
pcVar3 = "ACT_MP_GESTURE_VC_NODYES";
if (this[0xb1] == (CMultiPlayerAnimState)0x0) {
pcVar2 = "ACT_MP_GESTURE_VC_NODNO";
}
if (this[0xb0] == (CMultiPlayerAnimState)0x0) {
pcVar3 = "ACT_MP_GESTURE_VC_NODNO";
}
if (this[0xaf] == (CMultiPlayerAnimState)0x0) {
pcVar5 = "ACT_MP_GESTURE_VC_NODNO";
}
Anim_StatePrintf(local_a0,"Incap: %s, Reviving: %s, Hanging: %s",pcVar5 + 0x15,pcVar3 + 0x15,
pcVar2 + 0x15,uVar9,uVar17,dVar13,dVar12,dVar16,dVar14,dVar11);
Anim_StatePrintf(local_a4,"--------------------------------------------\n\n");
pCVar8 = *(CBaseEntity **)(this + 0x1c);
if (((byte)pCVar8[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(pCVar8);
}
local_70 = *(float *)(pCVar8 + 0x2e0);
local_64 = 0;
local_5c = 0;
local_6c = *(float *)(pCVar8 + 0x2e4);
local_68 = *(float *)(pCVar8 + 0x2e8) + 3.0;
local_60 = *(undefined4 *)(this + 0x98);
AngleVectors((QAngle *)&local_64,(Vector *)&local_58,local_4c,local_40);
local_24 = local_54 * 30.0 + local_6c;
local_28 = local_58 * 30.0 + local_70;
local_20 = local_50 * 30.0 + local_68;
(**(code **)(*debugoverlay + 0xc))(debugoverlay,&local_70,&local_28,0xff,0,0,1,0x3a83126f);
local_60 = *(undefined4 *)(this + 0x9c);
AngleVectors((QAngle *)&local_64,(Vector *)&local_58,local_4c,local_40);
local_24 = local_54 * 30.0 + local_6c;
local_28 = local_58 * 30.0 + local_70;
local_20 = local_50 * 30.0 + local_68;
(**(code **)(*debugoverlay + 0xc))(debugoverlay,&local_70,&local_28,0xff,0xff,0,1,0x3a83126f);
local_60 = *(undefined4 *)(this + 0xe4);
local_64 = *(undefined4 *)(this + 0xe8);
AngleVectors((QAngle *)&local_64,(Vector *)&local_58,local_4c,local_40);
local_2c = local_68 + 60.0;
local_28 = local_58 * 30.0 + local_70;
local_24 = local_54 * 30.0 + local_6c;
local_34 = local_70;
local_20 = local_50 * 30.0 + local_2c;
local_30 = local_6c;
(**(code **)(*debugoverlay + 0xc))(debugoverlay,&local_34,&local_28,0xff,0xff,0xff,1,0x3a83126f);
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.