add demo mode
This commit is contained in:
@ -2,6 +2,8 @@
|
||||
|
||||
#include "gui/common/NamedField.hpp"
|
||||
|
||||
#include "../../Core/Inc/config.h"
|
||||
|
||||
FrontendApplication::FrontendApplication(Model &m, FrontendHeap &heap)
|
||||
: FrontendApplicationBase(m, heap), canChangeFromMissionSelect(false) {
|
||||
namedFieldSort();
|
||||
@ -14,5 +16,8 @@ void FrontendApplication::setCanChangeFromMissionSelect(
|
||||
|
||||
// controls if next screen button works on mission select screen
|
||||
bool FrontendApplication::getCanChangeFromMissionSelect() const {
|
||||
#ifdef DEMO_MODE
|
||||
return true;
|
||||
#endif
|
||||
return canChangeFromMissionSelect;
|
||||
}
|
||||
|
||||
@ -2,6 +2,7 @@
|
||||
#include "texts/TextKeysAndLanguages.hpp"
|
||||
#include <gui/missionselect_screen/MissionSelectView.hpp>
|
||||
|
||||
#include "config.h"
|
||||
#include "stw_defines.h"
|
||||
#include "vehicle.h"
|
||||
#include "vehicle_state.h"
|
||||
@ -54,6 +55,12 @@ void MissionSelectView::confirmMission() {
|
||||
return;
|
||||
}
|
||||
vehicle_select_mission(selectedMission);
|
||||
|
||||
#ifdef DEMO_MODE
|
||||
vehicle_state.active_mission = selectedMission;
|
||||
presenter->vehicleStateUpdated();
|
||||
#endif
|
||||
|
||||
#ifdef SIMULATOR
|
||||
vehicle_state.active_mission = selectedMission;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user