Fix the rest non-working timer-related function
This commit is contained in:
@@ -407,7 +407,7 @@ void Powerup::hitBonusBox(const Item &item, int add_info)
|
||||
{
|
||||
new_powerup = powerup_manager->getRandomPowerup(position, &n);
|
||||
if(new_powerup != PowerupManager::POWERUP_RUBBERBALL ||
|
||||
( World::getWorld()->getTime() - powerup_manager->getBallCollectTime()) >
|
||||
( World::getWorld()->getTimeSinceStart() - powerup_manager->getBallCollectTime()) >
|
||||
RubberBall::getTimeBetweenRubberBalls() )
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -241,7 +241,7 @@ void AIBaseController::crashed(const Material *m)
|
||||
const unsigned int NUM_COLLISION = 3;
|
||||
const float COLLISION_TIME = 1.5f;
|
||||
|
||||
float time = World::getWorld()->getTime();
|
||||
float time = World::getWorld()->getTimeSinceStart();
|
||||
if(m_collision_times.size()==0)
|
||||
{
|
||||
m_collision_times.push_back(time);
|
||||
|
||||
@@ -1000,7 +1000,7 @@ void Kart::collectedItem(Item *item, int add_info)
|
||||
*/
|
||||
float Kart::getStartupBoost() const
|
||||
{
|
||||
float t = World::getWorld()->getTime();
|
||||
float t = World::getWorld()->getTimeSinceStart();
|
||||
std::vector<float> startup_times = m_kart_properties->getStartupTime();
|
||||
for (unsigned int i = 0; i < startup_times.size(); i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user