mirror of
https://github.com/s1lentq/ReGameDLL_CS.git
synced 2025-01-13 15:18:00 +03:00
CGrenade::Use: Fixed spam sound on defuse start, if player in air
This commit is contained in:
parent
22f5fe3831
commit
c35545a5b8
@ -1151,21 +1151,20 @@ void CGrenade::Use(CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE useTy
|
||||
{
|
||||
#ifdef REGAMEDLL_FIXES
|
||||
if (m_pBombDefuser == pPlayer)
|
||||
#endif
|
||||
{
|
||||
if ((pPlayer->pev->flags & FL_ONGROUND) != FL_ONGROUND) // Defuse should start only on ground
|
||||
m_fNextDefuse = gpGlobals->time + NEXT_DEFUSE_TIME;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
#ifdef REGAMEDLL_FIXES
|
||||
else if ((pPlayer->pev->flags & FL_ONGROUND) != FL_ONGROUND) // Defuse should start only on ground
|
||||
{
|
||||
ClientPrint(pPlayer->pev, HUD_PRINTCENTER, "#C4_Defuse_Must_Be_On_Ground");
|
||||
return;
|
||||
}
|
||||
|
||||
m_fNextDefuse = gpGlobals->time + NEXT_DEFUSE_TIME;
|
||||
}
|
||||
#else
|
||||
m_fNextDefuse = gpGlobals->time + NEXT_DEFUSE_TIME;
|
||||
#endif // #ifdef REGAMEDLL_FIXES
|
||||
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
DefuseBombStart(pPlayer);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user