From b782af29491809956e35cf1a64f45fcb0d6cedcc Mon Sep 17 00:00:00 2001 From: Ethan Uzarowski Date: Fri, 23 Feb 2018 20:43:46 -0500 Subject: [PATCH] Remove "Final lap!" message in one-lap races (#3127) * Fix "Final lap!" message on one-lap races When starting a one-lap race, the game gives the message "Final lap!". This should only be given when there is more than one lap in the race. This commit changes linear_world.cpp so that this message is only given when the number of laps in the race is greater than 1. * Fix spacing I accidentally changed the spacing when making my last commit. This commit fixes that accident. --- src/modes/linear_world.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/modes/linear_world.cpp b/src/modes/linear_world.cpp index 388df6a75..678a07acd 100644 --- a/src/modes/linear_world.cpp +++ b/src/modes/linear_world.cpp @@ -284,8 +284,11 @@ void LinearWorld::newLap(unsigned int kart_index) // Last lap message (kart_index's assert in previous block already) if (raceHasLaps() && kart_info.m_race_lap+1 == lap_count) { - m_race_gui->addMessage(_("Final lap!"), kart, + if (lap_count > 1) + { + m_race_gui->addMessage(_("Final lap!"), kart, 3.0f, GUIEngine::getSkin()->getColor("font::normal"), true); + } if(!m_last_lap_sfx_played && lap_count > 1) { if (UserConfigParams::m_music)