Cassidy Hilts

Game Developer

<-- Back to archive

New types of upgrade costs

March 29, 2025

Today I spent a bit of time looking at the save system I implemented for the main upgrade data for the player character. Primarily a lot of this data is static and not changeable, such as how much the upgrade impacts the player. Because of this there isnt much data to save in general, with the file totaling 20kb at most. I did a pass today to run the data through a ZLIB compression, resulting in what is appearing to be 30-40% compression on the data file size. I'd like to take another pass on the data later since there is a lot of derived data, like the cost of the upgrade for the next stage of it, that is being stored along and could be removed by adding some functions for determining the cost after data is loaded.

Speaking of costs! I wasn't fully satisfied with all costs scaling only on the same resource, ie: only costing bronze unless I wanted to make an upgrade down the line with a similar effect that was costed differently. This lead me to develop a way for my costs to have stages to them, that when passed they could transition to different resources, different scaling factors etc. I'm pretty happy with the design overall, although the UI is a bit clunky in unreal for it at the moment, but the flexibility is well worth it!