Remove anvil handling (obsolete)

This commit is contained in:
Alayan-stk-2 2018-04-11 04:16:13 +02:00 committed by GitHub
parent 22b69e10f4
commit 074065f274
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1327,25 +1327,9 @@ void SkiddingAI::handleItems(const float dt, const Vec3 *aim_point, int last_nod
m_controls->setFire(true);
break; // POWERUP_PARACHUTE
case PowerupManager::POWERUP_ANVIL:
// Wait one second more than a previous anvil
if(m_time_since_last_shot < m_kart->getKartProperties()->getAnvilDuration() + 1.0f) break;
if(race_manager->getMinorMode()==RaceManager::MINOR_MODE_FOLLOW_LEADER)
{
m_controls->setFire(m_world->getTime()<1.0f &&
m_kart->getPosition()>2 );
}
else
{
m_controls->setFire(m_time_since_last_shot > 3.0f &&
m_kart->getPosition()>1 );
}
break; // POWERUP_ANVIL
case PowerupManager::POWERUP_SWATTER:
{
// if the kart has a shield, do not return it by using a swatter.
// if the kart has a shield, do not break it by using a swatter.
if(m_kart->getShieldTime() > min_bubble_time)
break;