UI Mayhem!
Grabbing all related information can be rough when you don't preplan for everything from the get go!
While developing the in game UI, we wanted to display our stats for the player on the side during the pause menu. This ended up being a lot of lines, hardcoding each value with a name as we originally setup stats to be singly float values, no other information. Although this doesn't directly affect the user (YOU!), it can affect the speed in which we add in changes and how those values differ from the defaults.
After a bit of team discussion, we turned around and made a cozy little struct to house this information, allowing us to store the name of this stat, the base value of it, a copy of the current modifier on this stat (whether it is positive or negative!), and any other information we may choose to add in the future.
As you can see in the above image, this takes our (potentially 100's of lines long) code and shrink it down to a cozy little for loop, no matter how many new stats we decide to add. As seen in the following image:
In the end, I hope we can bring a little better communication and pre-planning to ourselves to save a little time about our design decisions. But this is also part of the process of growing as a team and learning how each other codes and makes design decisions!
Get Banana Hell
Banana Hell
Banana Supremecy shall reign!!!!!
Status | In development |
Author | brokenbananastudio |
Genre | Action, Shooter |
Languages | English |
More posts
- Music and some SFX5 days ago
- Unsuccessful Features5 days ago
- Squeezing Frames: Performance Pass and Optimization Wins5 days ago
- V0.0.3 Released! Official Prototype for class!5 days ago
- Building out stats and stat buffs11 days ago
- Balancing Chaos: Introducing the Overseer11 days ago
- Page Updates and V0.0.2 available!12 days ago
- Fixing Bugs: Enemies Now Remember to Swing Back18 days ago
- The beginnings of AI development18 days ago
Leave a comment
Log in with itch.io to leave a comment.