diff --git a/src/DesktopLauncher.cpp b/src/DesktopLauncher.cpp index 5514cc9..6438d82 100755 --- a/src/DesktopLauncher.cpp +++ b/src/DesktopLauncher.cpp @@ -4,6 +4,8 @@ #include #include + +#include "Desktoplauncher.h" #include "DarkRP2D.h" using namespace std; diff --git a/src/DesktopLauncher.h b/src/DesktopLauncher.h new file mode 100644 index 0000000..861fd27 --- /dev/null +++ b/src/DesktopLauncher.h @@ -0,0 +1,12 @@ +#ifndef DESKTOPLAUNCHER_H +#define DESKTOPLAUNCHER_H + +namespace Game { + +#define WINDOW_WIDTH = 800; +#define WINDOW_HEIGHT = 600; + +void exit(int code); + +} +#endif \ No newline at end of file diff --git a/src/InputHandler.cpp b/src/InputHandler.cpp index 8655fb1..17cb160 100644 --- a/src/InputHandler.cpp +++ b/src/InputHandler.cpp @@ -15,6 +15,9 @@ Command* InputHandler::handleInput(SDL_Event *event) { return NULL; } switch (event->type) { + case SDL_QUIT: + return NULL; + break; case SDL_KEYDOWN: std::cout << "The Key " << SDL_GetKeyName(event->key.keysym.sym) << " has been pressed!" << std::endl; return NULL;