#pragma once #include #include #include #include #include namespace game { class Ship; class Command; class Missile; class Player { public: int id; bool alive; float speed; float energy; float deadTimeCounter; Ship *ship; std::string name; std::vector missiles; Player(int id) : id(id), alive(true), speed(0.01), energy(0.0), ship(nullptr), name("") { } void addCommand(Command *cmd); bool hasCommandInQueue(); Command *peekCommand(); void popCommand(); private: std::deque commands; }; }