r/howdidtheycodeit • u/Flohhhhhh • Jul 03 '22
Question How do they code rogue like upgrades??
I’m looking at making a game with a roguelike progression style. The main thing that is confusing me is how having such a wide variety of effects would work.
For example, stat bonuses would be easy. But say I’m making effects that add new mechanics to projectiles, new mechanics to movement, or more complex things. How would I handle coding that?
I assume I would have a database of all the upgrades and their effects, but on the actual classes do I just need 1000 boolean variables for if it has that effect or not and check all of them one by one in the events? How could I approach that? By
View all comments
Show parent comment
2
u/Natural_Soda Jul 03 '22
To explain further, the up to date list of upgrades would work because you have each upgrade named something different even if it’s just a slight name change like (projectile 2.0).