Turn Based Patterns and Ideas using Bevy ECS #3370
Replies: 1 comment 1 reply
-
Turns out I am making a hybrid turn based game in bevy. This may be surprising, but I've had no issues with modelling it in the ECS. My approach consists of having two states "Planning" (where the player actually choses the action for the game to run) and "Running" (where the actions are being played) Typically the World variables for the "Running" state are immediately set as soon as the player decides to end his turn. Then, all the setup systems for the "Running" state are ran. You will probably need to set an execution order on those, because it is likely that you will need outputs of some systems as input of others. The World once setup, is available to all the real time systems that do game simulation and animations (like moving pieces on a chessboard). I have an always running system that detects if all the Running simulations and animations are done and then switch back the game state to "Planning". The loop then repeats. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Considering a complex turn-based game.
What are some good patterns/practices when using Bevy ECS?
Ideas derived from a brief read of a Discord thread:
Beta Was this translation helpful? Give feedback.
All reactions