L L4D2node

CCSPlayer::ClearFlashbangScreenFade

0x00656ac0 · 244 bytes · __thiscall

_ZN9CCSPlayer24ClearFlashbangScreenFadeEv

Decompiled

undefined (1 param)

/* CCSPlayer::ClearFlashbangScreenFade() */

void __thiscall CCSPlayer::ClearFlashbangScreenFade(CCSPlayer *this)

{
  CBaseEdict *pCVar1;
  int iVar2;
  color32_s local_10;
  undefined1 local_f;
  undefined1 local_e;
  undefined1 local_d;
  
  if (*(float *)(gpGlobals + 0xc) <= *(float *)(this + 0x23a0) &&
      *(float *)(this + 0x23a0) != *(float *)(gpGlobals + 0xc)) {
    local_10 = (color32_s)0x0;
    local_f = 0;
    local_e = 0;
    local_d = 0;
    UTIL_ScreenFade((CBaseEntity *)this,&local_10,0.01,0.0,0x12);
    if (*(float *)(this + 0x2888) != 0.0) {
      if (this[0x6c] == (CCSPlayer)0x0) {
        pCVar1 = *(CBaseEdict **)(this + 0x30);
        if (pCVar1 != (CBaseEdict *)0x0) {
          *(uint *)pCVar1 = *(uint *)pCVar1 | 0x101;
          iVar2 = CBaseEdict::GetChangeAccessor(pCVar1);
          *(undefined2 *)(iVar2 + 2) = 0;
        }
      }
      else {
        this[0x70] = (CCSPlayer)((byte)this[0x70] | 1);
      }
      *(undefined4 *)(this + 0x2888) = 0;
    }
    if (*(float *)(this + 0x288c) != 255.0) {
      if (this[0x6c] == (CCSPlayer)0x0) {
        pCVar1 = *(CBaseEdict **)(this + 0x30);
        if (pCVar1 != (CBaseEdict *)0x0) {
          *(uint *)pCVar1 = *(uint *)pCVar1 | 0x101;
          iVar2 = CBaseEdict::GetChangeAccessor(pCVar1);
          *(undefined2 *)(iVar2 + 2) = 0;
        }
      }
      else {
        this[0x70] = (CCSPlayer)((byte)this[0x70] | 1);
      }
      *(undefined4 *)(this + 0x288c) = 0x437f0000;
    }
  }
  *(undefined4 *)(this + 0x23a0) = 0;
  *(undefined4 *)(this + 0x23a4) = 0;
  return;
}

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)