diff options
Diffstat (limited to 'src/GameInitDispose.cpp')
-rw-r--r-- | src/GameInitDispose.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/GameInitDispose.cpp b/src/GameInitDispose.cpp index 8c9ea72..bd8a05f 100644 --- a/src/GameInitDispose.cpp +++ b/src/GameInitDispose.cpp @@ -20,11 +20,17 @@ // You should have received a copy of the GNU General Public License // along with Black Shades. If not, see <https://www.gnu.org/licenses/>. +#include <fstream> + +#include <time.h> + #include <AL/alc.h> +#include <GL/glu.h> #include "config.h" #include "misc.h" #include "Game.h" +#include "Support.h" extern unsigned int gSourceID[37]; extern unsigned int gSampleSet[37]; @@ -88,11 +94,11 @@ Game* makeGame(Config config) game->debug = config.debug; // TODO: Read high score - ifstream ipstream2 {"highscore.txt"}; + std::ifstream ipstream2 {"highscore.txt"}; if (!ipstream2) { - ofstream opstream("highscore.txt"); - opstream << (game->highscore = 0) << endl; - opstream << (game->beatgame = 0) << endl; + std::ofstream opstream("highscore.txt"); + opstream << (game->highscore = 0) << std::endl; + opstream << (game->beatgame = 0) << std::endl; opstream.close(); } else { ipstream2 >> game->highscore; @@ -250,7 +256,7 @@ void initGame(Game* game) game->timeremaining = 50; game->difficulty= 0.8f; - ifstream ipstream {"data/customlevels.txt"}; + std::ifstream ipstream {"data/customlevels.txt"}; if (ipstream) { ipstream.ignore(256,'\n');//ignore descriptive text ipstream >> game->nummissions; |