diff options
author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2021-03-05 20:50:51 -0500 |
---|---|---|
committer | Kelly Rauchenberger <fefferburbia@gmail.com> | 2021-03-05 20:50:51 -0500 |
commit | 1c462ef3780b33468ed93dde3ab6178765807ffe (patch) | |
tree | 6ee2f34ed3514c10d146c91b0e8e935cf9d1ccb6 /src/main.cpp | |
parent | 937875c4e1432b418f0f5051759e02c8d4c9ffa4 (diff) | |
download | tanetane-1c462ef3780b33468ed93dde3ab6178765807ffe.tar.gz tanetane-1c462ef3780b33468ed93dde3ab6178765807ffe.tar.bz2 tanetane-1c462ef3780b33468ed93dde3ab6178765807ffe.zip |
Added MirrorSystem
This is really just for letting one sprite mirror another's movement and animation. I tried doing it in the BehaviourSystem, but you get stuttering if you do it earlier in the loop than the CharacterSystem, so I ended up having to make a new system just for this thing that will not happen very often.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index d0220fc..772fff8 100644 --- a/src/main.cpp +++ b/src/main.cpp | |||
@@ -14,6 +14,7 @@ | |||
14 | #include "script_system.h" | 14 | #include "script_system.h" |
15 | #include "effect_system.h" | 15 | #include "effect_system.h" |
16 | #include "behaviour_system.h" | 16 | #include "behaviour_system.h" |
17 | #include "mirror_system.h" | ||
17 | 18 | ||
18 | void loop(Renderer& renderer, std::mt19937& rng) { | 19 | void loop(Renderer& renderer, std::mt19937& rng) { |
19 | Game game(renderer, rng); | 20 | Game game(renderer, rng); |
@@ -22,6 +23,7 @@ void loop(Renderer& renderer, std::mt19937& rng) { | |||
22 | game.emplaceSystem<InputSystem>(); | 23 | game.emplaceSystem<InputSystem>(); |
23 | game.emplaceSystem<BehaviourSystem>(); | 24 | game.emplaceSystem<BehaviourSystem>(); |
24 | game.emplaceSystem<CharacterSystem>(); | 25 | game.emplaceSystem<CharacterSystem>(); |
26 | game.emplaceSystem<MirrorSystem>(); | ||
25 | game.emplaceSystem<AnimationSystem>(); | 27 | game.emplaceSystem<AnimationSystem>(); |
26 | game.emplaceSystem<CameraSystem>(); | 28 | game.emplaceSystem<CameraSystem>(); |
27 | game.emplaceSystem<MessageSystem>(); | 29 | game.emplaceSystem<MessageSystem>(); |