diff options
author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2018-05-17 15:55:37 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-17 15:55:37 -0400 |
commit | 90aadf3844386824140a20d7fbb847bc16009a94 (patch) | |
tree | 6f83fce90e71abb22b1a8f3e09c79963b2a34d5d /src/main.cpp | |
parent | bc63fa57ced1c7329f7fdcfd168eaf7e290158bc (diff) | |
parent | 86f0106d0523825549f1e74b835688c78a10cf6c (diff) | |
download | therapy-90aadf3844386824140a20d7fbb847bc16009a94.tar.gz therapy-90aadf3844386824140a20d7fbb847bc16009a94.tar.bz2 therapy-90aadf3844386824140a20d7fbb847bc16009a94.zip |
Merge pull request #7 from hatkirby/es-rewrite
The ECS rewrite exceeds the original branch in functionality, so it is time to merge it in.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/src/main.cpp b/src/main.cpp index 4157350..d59d0f9 100644 --- a/src/main.cpp +++ b/src/main.cpp | |||
@@ -1,25 +1,18 @@ | |||
1 | #include <ctime> | 1 | #include <random> |
2 | #include <list> | ||
3 | #include "renderer.h" | ||
4 | #include <cstdlib> | ||
5 | #include "game.h" | ||
6 | #include "muxer.h" | 2 | #include "muxer.h" |
3 | #include "game.h" | ||
7 | 4 | ||
8 | int main() | 5 | int main() |
9 | { | 6 | { |
10 | srand(time(NULL)); | 7 | std::random_device randomDevice; |
11 | 8 | std::mt19937 rng(randomDevice()); | |
12 | GLFWwindow* window = initRenderer(); | 9 | |
13 | initMuxer(); | 10 | initMuxer(); |
14 | 11 | ||
15 | // Put this in a block so game goes out of scope before we destroy the renderer | 12 | Game game(rng); |
16 | { | 13 | game.execute(); |
17 | Game game {"res/maps.xml"}; | 14 | |
18 | game.execute(window); | ||
19 | } | ||
20 | |||
21 | destroyMuxer(); | 15 | destroyMuxer(); |
22 | destroyRenderer(); | 16 | |
23 | |||
24 | return 0; | 17 | return 0; |
25 | } | 18 | } |