mirror of
https://github.com/s1lentq/ReGameDLL_CS.git
synced 2025-01-29 23:18:03 +03:00
Shield constants code cleaning (#843)
* Change constant name (SHIELDREN -> SHIELDGREN) * Correct and separate constant names
This commit is contained in:
parent
8a18969be1
commit
11d6b086b4
@ -534,7 +534,7 @@ enum usp_shield_e
|
|||||||
USP_SHIELD_SHOOT_EMPTY,
|
USP_SHIELD_SHOOT_EMPTY,
|
||||||
USP_SHIELD_RELOAD,
|
USP_SHIELD_RELOAD,
|
||||||
USP_SHIELD_DRAW,
|
USP_SHIELD_DRAW,
|
||||||
USP_SHIELD_UP_IDLE,
|
USP_SHIELD_IDLE_UP,
|
||||||
USP_SHIELD_UP,
|
USP_SHIELD_UP,
|
||||||
USP_SHIELD_DOWN,
|
USP_SHIELD_DOWN,
|
||||||
};
|
};
|
||||||
@ -900,6 +900,19 @@ enum deagle_e
|
|||||||
DEAGLE_DRAW,
|
DEAGLE_DRAW,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enum deagle_shield_e
|
||||||
|
{
|
||||||
|
DEAGLE_SHIELD_IDLE1,
|
||||||
|
DEAGLE_SHIELD_SHOOT,
|
||||||
|
DEAGLE_SHIELD_SHOOT2,
|
||||||
|
DEAGLE_SHIELD_SHOOT_EMPTY,
|
||||||
|
DEAGLE_SHIELD_RELOAD,
|
||||||
|
DEAGLE_SHIELD_DRAW,
|
||||||
|
DEAGLE_SHIELD_IDLE_UP,
|
||||||
|
DEAGLE_SHIELD_UP,
|
||||||
|
DEAGLE_SHIELD_DOWN,
|
||||||
|
};
|
||||||
|
|
||||||
class CDEAGLE: public CBasePlayerWeapon
|
class CDEAGLE: public CBasePlayerWeapon
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
@ -1065,7 +1078,7 @@ enum glock18_shield_e
|
|||||||
GLOCK18_SHIELD_SHOOT_EMPTY,
|
GLOCK18_SHIELD_SHOOT_EMPTY,
|
||||||
GLOCK18_SHIELD_RELOAD,
|
GLOCK18_SHIELD_RELOAD,
|
||||||
GLOCK18_SHIELD_DRAW,
|
GLOCK18_SHIELD_DRAW,
|
||||||
GLOCK18_SHIELD_IDLE,
|
GLOCK18_SHIELD_IDLE_UP,
|
||||||
GLOCK18_SHIELD_UP,
|
GLOCK18_SHIELD_UP,
|
||||||
GLOCK18_SHIELD_DOWN,
|
GLOCK18_SHIELD_DOWN,
|
||||||
};
|
};
|
||||||
@ -1180,7 +1193,7 @@ enum knife_shield_e
|
|||||||
KNIFE_SHIELD_SLASH,
|
KNIFE_SHIELD_SLASH,
|
||||||
KNIFE_SHIELD_ATTACKHIT,
|
KNIFE_SHIELD_ATTACKHIT,
|
||||||
KNIFE_SHIELD_DRAW,
|
KNIFE_SHIELD_DRAW,
|
||||||
KNIFE_SHIELD_UPIDLE,
|
KNIFE_SHIELD_IDLE_UP,
|
||||||
KNIFE_SHIELD_UP,
|
KNIFE_SHIELD_UP,
|
||||||
KNIFE_SHIELD_DOWN,
|
KNIFE_SHIELD_DOWN,
|
||||||
};
|
};
|
||||||
@ -1858,6 +1871,19 @@ enum fiveseven_e
|
|||||||
FIVESEVEN_DRAW,
|
FIVESEVEN_DRAW,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enum fiveseven_shield_e
|
||||||
|
{
|
||||||
|
FIVESEVEN_SHIELD_IDLE1,
|
||||||
|
FIVESEVEN_SHIELD_SHOOT,
|
||||||
|
FIVESEVEN_SHIELD_SHOOT2,
|
||||||
|
FIVESEVEN_SHIELD_SHOOT_EMPTY,
|
||||||
|
FIVESEVEN_SHIELD_RELOAD,
|
||||||
|
FIVESEVEN_SHIELD_DRAW,
|
||||||
|
FIVESEVEN_SHIELD_IDLE_UP,
|
||||||
|
FIVESEVEN_SHIELD_UP,
|
||||||
|
FIVESEVEN_SHIELD_DOWN,
|
||||||
|
};
|
||||||
|
|
||||||
class CFiveSeven: public CBasePlayerWeapon
|
class CFiveSeven: public CBasePlayerWeapon
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -318,25 +318,12 @@ enum AmmoBuyAmount
|
|||||||
AMMO_SMOKEGRENADE_BUY = 1,
|
AMMO_SMOKEGRENADE_BUY = 1,
|
||||||
};
|
};
|
||||||
|
|
||||||
enum shieldgun_e
|
|
||||||
{
|
|
||||||
SHIELDGUN_IDLE,
|
|
||||||
SHIELDGUN_SHOOT1,
|
|
||||||
SHIELDGUN_SHOOT2,
|
|
||||||
SHIELDGUN_SHOOT_EMPTY,
|
|
||||||
SHIELDGUN_RELOAD,
|
|
||||||
SHIELDGUN_DRAW,
|
|
||||||
SHIELDGUN_DRAWN_IDLE,
|
|
||||||
SHIELDGUN_UP,
|
|
||||||
SHIELDGUN_DOWN,
|
|
||||||
};
|
|
||||||
|
|
||||||
// custom
|
// custom
|
||||||
enum shieldgren_e
|
enum shieldgren_e
|
||||||
{
|
{
|
||||||
SHIELDREN_IDLE = 4,
|
SHIELDGREN_IDLE = 4, // 3 is last grenade viewmodel sequence
|
||||||
SHIELDREN_UP,
|
SHIELDGREN_UP,
|
||||||
SHIELDREN_DOWN
|
SHIELDGREN_DOWN
|
||||||
};
|
};
|
||||||
|
|
||||||
enum InventorySlotType
|
enum InventorySlotType
|
||||||
|
@ -93,7 +93,7 @@ void CDEAGLE::PrimaryAttack()
|
|||||||
|
|
||||||
void CDEAGLE::SecondaryAttack()
|
void CDEAGLE::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_UP, SHIELDGUN_DOWN);
|
ShieldSecondaryFire(DEAGLE_SHIELD_UP, DEAGLE_SHIELD_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CDEAGLE::DEAGLEFire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
void CDEAGLE::DEAGLEFire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
||||||
@ -204,7 +204,7 @@ void CDEAGLE::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(SHIELDGUN_DRAWN_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(DEAGLE_SHIELD_IDLE_UP, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -92,7 +92,7 @@ void CFiveSeven::PrimaryAttack()
|
|||||||
|
|
||||||
void CFiveSeven::SecondaryAttack()
|
void CFiveSeven::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_UP, SHIELDGUN_DOWN);
|
ShieldSecondaryFire(FIVESEVEN_SHIELD_UP, FIVESEVEN_SHIELD_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CFiveSeven::FiveSevenFire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
void CFiveSeven::FiveSevenFire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
||||||
@ -208,7 +208,7 @@ void CFiveSeven::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(SHIELDGUN_DRAWN_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(FIVESEVEN_SHIELD_IDLE_UP, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (m_iClip)
|
else if (m_iClip)
|
||||||
|
@ -142,7 +142,7 @@ bool CFlashbang::ShieldSecondaryFire(int iUpAnim, int iDownAnim)
|
|||||||
|
|
||||||
void CFlashbang::SecondaryAttack()
|
void CFlashbang::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_DRAW, SHIELDGUN_DRAWN_IDLE);
|
ShieldSecondaryFire(SHIELDGREN_UP, SHIELDGREN_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CFlashbang::SetPlayerShieldAnim()
|
void CFlashbang::SetPlayerShieldAnim()
|
||||||
@ -236,7 +236,7 @@ void CFlashbang::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(SHIELDREN_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(SHIELDGREN_IDLE, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -295,7 +295,7 @@ void CGLOCK18::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(GLOCK18_SHIELD_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(GLOCK18_SHIELD_IDLE_UP, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// only idle if the slid isn't back
|
// only idle if the slid isn't back
|
||||||
|
@ -144,7 +144,7 @@ bool CHEGrenade::ShieldSecondaryFire(int iUpAnim, int iDownAnim)
|
|||||||
|
|
||||||
void CHEGrenade::SecondaryAttack()
|
void CHEGrenade::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_DRAW, SHIELDGUN_DRAWN_IDLE);
|
ShieldSecondaryFire(SHIELDGREN_UP, SHIELDGREN_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CHEGrenade::SetPlayerShieldAnim()
|
void CHEGrenade::SetPlayerShieldAnim()
|
||||||
@ -247,7 +247,7 @@ void CHEGrenade::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(SHIELDREN_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(SHIELDGREN_IDLE, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -92,7 +92,7 @@ void CP228::PrimaryAttack()
|
|||||||
|
|
||||||
void CP228::SecondaryAttack()
|
void CP228::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_UP, SHIELDGUN_DOWN);
|
ShieldSecondaryFire(P228_SHIELD_UP, P228_SHIELD_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CP228::P228Fire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
void CP228::P228Fire(float flSpread, float flCycleTime, BOOL fUseSemi)
|
||||||
|
@ -145,7 +145,7 @@ bool CSmokeGrenade::ShieldSecondaryFire(int iUpAnim, int iDownAnim)
|
|||||||
|
|
||||||
void CSmokeGrenade::SecondaryAttack()
|
void CSmokeGrenade::SecondaryAttack()
|
||||||
{
|
{
|
||||||
ShieldSecondaryFire(SHIELDGUN_DRAW, SHIELDGUN_DRAWN_IDLE);
|
ShieldSecondaryFire(SHIELDGREN_UP, SHIELDGREN_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CSmokeGrenade::SetPlayerShieldAnim()
|
void CSmokeGrenade::SetPlayerShieldAnim()
|
||||||
@ -251,7 +251,7 @@ void CSmokeGrenade::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(SHIELDREN_IDLE, UseDecrement() != FALSE);
|
SendWeaponAnim(SHIELDGREN_IDLE, UseDecrement() != FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -279,7 +279,7 @@ void CUSP::WeaponIdle()
|
|||||||
|
|
||||||
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
if (m_iWeaponState & WPNSTATE_SHIELD_DRAWN)
|
||||||
{
|
{
|
||||||
SendWeaponAnim(USP_DRAW, UseDecrement());
|
SendWeaponAnim(USP_SHIELD_IDLE_UP, UseDecrement());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (m_iClip)
|
else if (m_iClip)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user