From e24b8d0591e795053d694f91a4ab03ae1d938dee Mon Sep 17 00:00:00 2001 From: Mikko Ahlroth Date: Thu, 17 Oct 2019 12:05:50 +0300 Subject: [PATCH] Fix compiling, use enum class --- src/config.hpp | 4 ++++ src/game.cpp | 2 +- src/game.hpp | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/config.hpp b/src/config.hpp index 4fb0be8..258beb8 100644 --- a/src/config.hpp +++ b/src/config.hpp @@ -1,3 +1,7 @@ +#include + +#pragma once + /** * Set to true to enable debug prints (via serial console) and false to disable. */ diff --git a/src/game.cpp b/src/game.cpp index 2003826..e9ccaaf 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -11,7 +11,7 @@ Game::Game(Debugger* debugger, Randomiser* randomiser) state(State::MENU), currentDelay(DELAY_START), currentScore(0), - waitingBeeps({}), + waitingBeeps{}, waitingBeepsAmount(0) { debugger->print("Initialising new game..."); } diff --git a/src/game.hpp b/src/game.hpp index 6ce6f1c..8fd222f 100644 --- a/src/game.hpp +++ b/src/game.hpp @@ -2,7 +2,7 @@ #include "debugger.hpp" #include "randomiser.hpp" -enum State { MENU, GAME, SCORE }; +enum class State { MENU, GAME, SCORE }; class Game { Debugger* debugger;