diff options
Diffstat (limited to 'src/main.cpp')
| -rw-r--r-- | src/main.cpp | 18 |
1 files changed, 10 insertions, 8 deletions
| diff --git a/src/main.cpp b/src/main.cpp index 4157350..d51da7d 100644 --- a/src/main.cpp +++ b/src/main.cpp | |||
| @@ -1,25 +1,27 @@ | |||
| 1 | #include <ctime> | 1 | #include <ctime> |
| 2 | #include <list> | 2 | #include <list> |
| 3 | #include "renderer.h" | ||
| 4 | #include <cstdlib> | 3 | #include <cstdlib> |
| 5 | #include "game.h" | 4 | #include "renderer.h" |
| 6 | #include "muxer.h" | 5 | #include "muxer.h" |
| 6 | #include "game.h" | ||
| 7 | 7 | ||
| 8 | int main() | 8 | int main() |
| 9 | { | 9 | { |
| 10 | srand(time(NULL)); | 10 | srand(time(NULL)); |
| 11 | 11 | ||
| 12 | GLFWwindow* window = initRenderer(); | 12 | GLFWwindow* window = initRenderer(); |
| 13 | glfwSwapInterval(1); | ||
| 14 | |||
| 13 | initMuxer(); | 15 | initMuxer(); |
| 14 | 16 | ||
| 15 | // Put this in a block so game goes out of scope before we destroy the renderer | 17 | // Put this in a block so game goes out of scope before we destroy the renderer |
| 16 | { | 18 | { |
| 17 | Game game {"res/maps.xml"}; | 19 | Game game {window}; |
| 18 | game.execute(window); | 20 | game.execute(); |
| 19 | } | 21 | } |
| 20 | 22 | ||
| 21 | destroyMuxer(); | 23 | destroyMuxer(); |
| 22 | destroyRenderer(); | 24 | destroyRenderer(); |
| 23 | 25 | ||
| 24 | return 0; | 26 | return 0; |
| 25 | } | 27 | } |
