Player's turn complete
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
constexpr auto SIZE = 10;
|
||||
constexpr auto SIZE_FOR_ARRAY = SIZE - 1;
|
||||
constexpr auto ARMY = 5;
|
||||
constexpr auto FLAGS = 3;
|
||||
|
||||
class Game {
|
||||
private:
|
||||
@@ -27,6 +28,8 @@ public:
|
||||
void play();
|
||||
|
||||
private:
|
||||
bool handleUnitSelection(const auto&, size_t&, int&, int&);
|
||||
bool handleUnitMovement(auto, int&, int&);
|
||||
void Random(char);
|
||||
void clearScreen();
|
||||
void print_field(int, int);
|
||||
|
||||
@@ -11,6 +11,9 @@ private:
|
||||
public:
|
||||
Player() : score(0.) {};
|
||||
|
||||
void points(double _score){
|
||||
score += _score;
|
||||
}
|
||||
std::vector<std::unique_ptr<Infantry>>& get_army() {
|
||||
return army;
|
||||
}
|
||||
|
||||
@@ -12,6 +12,14 @@
|
||||
#include "Game.h"
|
||||
#include "Player.h"
|
||||
|
||||
// TODO
|
||||
/*enum class State {
|
||||
SELECT_UNIT,
|
||||
MOVE_UNIT,
|
||||
ENEMY_TURN
|
||||
};
|
||||
*/
|
||||
|
||||
enum KEY_CODES
|
||||
{
|
||||
ESC_KEY = 27,
|
||||
|
||||
Reference in New Issue
Block a user