void CGrenade::State(u32 state) { switch (state) { case MS_THREATEN: { Fvector C; Center (C); PlaySound (sndCheckout,C); }break; case MS_HIDDEN: { if(m_thrown) { if (m_pPhysicsShell) m_pPhysicsShell->Deactivate(); xr_delete (m_pPhysicsShell); m_dwDestroyTime = 0xffffffff; PutNextToSlot (); if (Local()) DestroyObject (); }; }break; }; inherited::State(state); }
void CGrenade::State(u32 state) { switch (state) { case MS_THREATEN: { Fvector C; Center (C); PlaySound (sndCheckout,C); }break; case MS_HIDDEN: { if(m_thrown) { if (m_pPhysicsShell) m_pPhysicsShell->Deactivate(); xr_delete (m_pPhysicsShell); m_dwDestroyTime = 0xffffffff; if(H_Parent()) PutNextToSlot (); if (Local()) { #ifdef DEBUG Msg("Destroying local grenade[%d][%d]",ID(),Device.dwFrame); #endif DestroyObject (); } }; }break; }; inherited::State(state); }
void CGrenade::State(u32 state) { switch (state) { case eThrowStart: { Fvector C; Center (C); PlaySound ("sndCheckout", C); }break; case eThrowEnd: { if(m_thrown) { if (m_pPhysicsShell) m_pPhysicsShell->Deactivate(); xr_delete ( m_pPhysicsShell ); m_dwDestroyTime = 0xffffffff; PutNextToSlot (); if (Local()) { #ifndef MASTER_GOLD Msg( "Destroying local grenade[%d][%d]", ID(), Device.dwFrame ); #endif // #ifndef MASTER_GOLD DestroyObject(); } }; }break; }; inherited::State( state ); }