No option to abort grand prix on last track (#3003)
* Small clarification to prevent build errors Building outside of this directory prevents the executable from launching, this small addition can help prevent this issue from happening. * Initial Commit * Code cleanup * Fix compile error * Fix incorrect comparison
This commit is contained in:
parent
2cc160d7cc
commit
a94d22cce7
@ -613,6 +613,8 @@ public:
|
||||
// ------------------------------------------------------------------------
|
||||
int getTrackNumber() const { return m_track_number; }
|
||||
// ------------------------------------------------------------------------
|
||||
int getNumOfTracks() const { return (int)m_tracks.size(); }
|
||||
// ------------------------------------------------------------------------
|
||||
/** Returns the list of AI karts to use. Used for networking, and for
|
||||
* the --ai= command line option. */
|
||||
const std::vector<std::string>& getAIKartList() const
|
||||
|
@ -205,8 +205,11 @@ void RaceResultGUI::enableAllButtons()
|
||||
middle->setText(_("Continue"));
|
||||
middle->setVisible(true);
|
||||
|
||||
bottom->setText(_("Abort Grand Prix"));
|
||||
bottom->setVisible(true);
|
||||
if (race_manager->getTrackNumber() + 1 < race_manager->getNumOfTracks())
|
||||
{
|
||||
bottom->setText(_("Abort Grand Prix"));
|
||||
bottom->setVisible(true);
|
||||
}
|
||||
|
||||
middle->setFocusForPlayer(PLAYER_ID_GAME_MASTER);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user