Pause the bomb during animations, fixes #2846

This commit is contained in:
auria.mg 2017-05-06 18:46:25 -04:00
parent 58a170b4b7
commit 242c8be90c

View File

@ -486,6 +486,12 @@ void Attachment::handleCollisionWithKart(AbstractKart *other)
void Attachment::update(float dt)
{
if(m_type==ATTACH_NOTHING) return;
// suspend the bomb during animations to avoid having 2 animations at the
// same time should the bomb explode before the previous animation is done
if (m_type == ATTACH_BOMB && m_kart->getKartAnimation() != NULL)
return;
m_time_left -=dt;