Turn Based Combat System
UI Event System done in Unity
Created a new system for implementing a UI Battle system using an Event system that allows it to be prefab free and allow for art and design changes without breaking functionality on the programming side in terms of the battle system.
UI Event System
In this project I decided to utilize Unity's Action system and create a custom event system to handle UI calls. This allowed me to create a UIEventManager singleton that made it so the Battle Manager and any other system can properly edit the information in the UI.
Dual Scene Loading
By using an additive UI scene with the world it allowed the UI to work completely separately from the battle system allowing them to be fully decoupled. It also helps keep systems separate and less overlap with prefabs creating issues between each scene that they persist in.
To give a good display of the UI being initialized I created encounter boxes that start the battle phase with a random enemy based on certain stats set in each encounter box. This also allows you to see the intro and outro UI animations
My primary plan with this project is wanting to find a way to do UI in a way that will scale with architecture of the game. While working on past games I've found that halfway through the project when new UI systems are added there tends to be a required large restructure based on most UI being handled in a few separate classes like PauseUI, MainMenuUI, etc. This led me to want to create a version of UI that would allow designers to create a set Scene for whether it be in game UI or a pause menu and then load it in separately so that it remains decoupled. This ended up working pretty well although I definitely ran into issues with references between the two scenes. While the UI scene can access anything from the main scene, the main scene cannot directly reference the UI scene. Thus using the event system was very handy. I think if I were to do it in the future I would create scripts with unique names for buttons to make it even more robust and versatile being able to use the UI manager across a slew of Menus and UI.