diff options
author | Justin Worthe <justin.worthe@gmail.com> | 2015-06-03 22:11:59 +0200 |
---|---|---|
committer | Justin Worthe <justin.worthe@gmail.com> | 2015-06-03 22:11:59 +0200 |
commit | a197a92893cff416b63da359db8c8059c7f333bf (patch) | |
tree | 7ff3c908a73231edda1f2ba7308a98da599f9169 /src/spacebot.cpp | |
parent | e42727977b3dab7aecff0ce8afa5b16abcd8b26b (diff) |
Added remaining objects for game state
Diffstat (limited to 'src/spacebot.cpp')
-rw-r--r-- | src/spacebot.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/spacebot.cpp b/src/spacebot.cpp index 7460fe3..a6c4953 100644 --- a/src/spacebot.cpp +++ b/src/spacebot.cpp @@ -4,8 +4,8 @@ #include <string> Spacebot::Spacebot(std::string outputPath) - : outputPath(std::move(outputPath)), - gameState(std::ifstream(outputPath+"/map.txt")) + : outputFilename(outputPath+"/move.txt"), + gameState(outputPath+"/map.txt") { } @@ -27,7 +27,7 @@ Move Spacebot::chooseMove() void Spacebot::writeMove(const Move& move) { - std::ofstream resultStream(outputPath+"/move.txt"); + std::ofstream resultStream(outputFilename); switch (move) { case Move::NOTHING: |