Removed time limit from easter eggs (if used in a challenge, the
challenge will define the time limit), which also fixes #861 (no timer when easter egg mode is started first). Added high-scores for easter egg mode. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12574 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
b7e5480fb6
commit
f857393ca2
@ -27,7 +27,7 @@
|
||||
EasterEggHunt::EasterEggHunt() : WorldWithRank()
|
||||
{
|
||||
WorldStatus::setClockMode(CLOCK_CHRONO);
|
||||
m_use_highscores = false;
|
||||
m_use_highscores = true;
|
||||
m_eggs_found = 0;
|
||||
} // EasterEggHunt
|
||||
|
||||
@ -76,6 +76,7 @@ void EasterEggHunt::readData(const std::string &filename)
|
||||
return;
|
||||
}
|
||||
|
||||
// Search for the closest difficulty set of egg.
|
||||
const XMLNode *data = NULL;
|
||||
std::string difficulty_name;
|
||||
RaceManager::Difficulty diff = race_manager->getDifficulty();
|
||||
@ -94,9 +95,6 @@ void EasterEggHunt::readData(const std::string &filename)
|
||||
return;
|
||||
}
|
||||
|
||||
m_time_limit = 9999;
|
||||
data->get("time-limit", &m_time_limit);
|
||||
|
||||
m_number_of_eggs = 0;
|
||||
for(unsigned int i=0; i<data->getNumNodes(); i++)
|
||||
{
|
||||
@ -113,7 +111,7 @@ void EasterEggHunt::readData(const std::string &filename)
|
||||
|
||||
delete easter;
|
||||
|
||||
WorldStatus::setClockMode(CLOCK_CHRONO, m_time_limit);
|
||||
WorldStatus::setClockMode(CLOCK_CHRONO);
|
||||
|
||||
} // readEasterEggInfo
|
||||
|
||||
|
@ -37,9 +37,6 @@ private:
|
||||
/** Keeps track of how many eggs each kart has found. */
|
||||
std::vector<int> m_eggs_collected;
|
||||
|
||||
/** A time limit for the hunt. */
|
||||
float m_time_limit;
|
||||
|
||||
/** Overall number of easter eggs. */
|
||||
int m_number_of_eggs;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user