diff options
author | Ekaitz Zarraga <ekaitz@elenq.tech> | 2021-12-24 19:53:16 +0100 |
---|---|---|
committer | Ekaitz Zarraga <ekaitz@elenq.tech> | 2021-12-24 19:53:16 +0100 |
commit | 9a9a0e090190dc7a2dba833d1d4efa8417283edc (patch) | |
tree | 4ba43ee254a1362e8400d4a78f6fcaa5c6f3b12b /src/command.h | |
parent | 4eee72704bd85db58981636109fdb456eb78a3c1 (diff) |
Overall cleaning and restructuring using commands
Diffstat (limited to 'src/command.h')
-rw-r--r-- | src/command.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/command.h b/src/command.h new file mode 100644 index 0000000..5af7517 --- /dev/null +++ b/src/command.h @@ -0,0 +1,32 @@ +#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 + +#endif |