#ifndef COMMAND_H #define COMMAND_H #include "game.h" class Command{ public: virtual ~Command(); virtual void execute( GameState &state ) =0; }; class Nop: public Command { ~Nop(); void execute( GameState &state ) override; }; // Window commands class WindowClose: public Command { ~WindowClose(); void execute( GameState &state ) override; }; class WindowFocus: public Command { ~WindowFocus(); void execute( GameState &state ) override; }; class WindowUnFocus: public Command { ~WindowUnFocus(); void execute( GameState &state ) override; }; // Keyboard commands class KeyboardDownReleased: public Command { ~KeyboardDownReleased(); void execute( GameState &state ) override; }; class KeyboardDownPressed: public Command { ~KeyboardDownPressed(); void execute( GameState &state ) override; }; class KeyboardLeftPressed: public Command { ~KeyboardLeftPressed(); void execute( GameState &state ) override; }; class KeyboardRightPressed: public Command { ~KeyboardRightPressed(); void execute( GameState &state ) override; }; class KeyboardSpacePressed: public Command { ~KeyboardSpacePressed(); void execute( GameState &state ) override; }; #endif