L L4D2node

CBasePlayer::EyeAngles

0x00416080 · 416 bytes · __thiscall

_ZN11CBasePlayer9EyeAnglesEv

Decompiled

undefined (1 param)

/* CBasePlayer::EyeAngles() */

CBasePlayer * __thiscall CBasePlayer::EyeAngles(CBasePlayer *this)

{
  uint uVar1;
  int *piVar2;
  CBaseEntity *pCVar3;
  char cVar4;
  undefined *puVar5;
  CBasePlayer *pCVar6;
  int iVar7;
  matrix3x4_t local_7c [48];
  matrix3x4_t local_4c [60];
  
  cVar4 = CDirector::IsFinaleEscapeInProgress(TheDirector);
  if (((((cVar4 != '\0') && (g_bIsVisibleCallLock == '\0')) &&
       (uVar1 = *(uint *)(this + 0x2088), uVar1 != 0xffffffff)) &&
      ((puVar5 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar5 != (undefined *)0xfffffffc &&
       (*(uint *)(puVar5 + 8) == uVar1 >> 0xc)))) &&
     (pCVar3 = *(CBaseEntity **)(puVar5 + 4), pCVar3 != (CBaseEntity *)0x0)) {
    if (((byte)pCVar3[0x14d] & 8) != 0) {
      CBaseEntity::CalcAbsolutePosition(pCVar3);
    }
    return (CBasePlayer *)(pCVar3 + 0x37c);
  }
  if (((this != (CBasePlayer *)0x0) &&
      (cVar4 = (**(code **)(*(int *)this + 0x16c))(this), cVar4 != '\0')) &&
     ((uVar1 = *(uint *)(this + 0x3edc), uVar1 != 0xffffffff &&
      (((puVar5 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar5 != (undefined *)0xfffffffc &&
        (*(uint *)(puVar5 + 8) == uVar1 >> 0xc)) &&
       (piVar2 = *(int **)(puVar5 + 4), piVar2 != (int *)0x0)))))) {
    pCVar6 = (CBasePlayer *)(**(code **)(*piVar2 + 0x238))(piVar2);
    return pCVar6;
  }
  uVar1 = *(uint *)(this + 0x188);
  if (((uVar1 != 0xffffffff) &&
      (puVar5 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar5 != (undefined *)0xfffffffc)) &&
     ((*(uint *)(puVar5 + 8) == uVar1 >> 0xc &&
      (pCVar3 = *(CBaseEntity **)(puVar5 + 4), pCVar3 != (CBaseEntity *)0x0)))) {
    AngleMatrix((QAngle *)(this + 0x1c84),local_7c);
    if (((byte)pCVar3[0x14d] & 8) != 0) {
      CBaseEntity::CalcAbsolutePosition(pCVar3);
    }
    ConcatTransforms((matrix3x4_t *)(pCVar3 + 0x28c),local_7c,local_4c);
    if ((EyeAngles()::angEyeWorld == '\0') &&
       (iVar7 = __cxa_guard_acquire(&EyeAngles()::angEyeWorld), iVar7 != 0)) {
      __cxa_guard_release(&EyeAngles()::angEyeWorld);
    }
    MatrixAngles(local_4c,(float *)EyeAngles()::angEyeWorld);
    return (CBasePlayer *)EyeAngles()::angEyeWorld;
  }
  return this + 0x1c84;
}

SourceMod gamedata

paste into addons/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.



        

        

          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)