Home < Dev Blogs < Dev Blog 6: Holy Tester < Week 9: Balancing Enemy Spawning

Week 9: Balancing Enemy Spawning

8/27/19

Hourly Breakdown:

Total: 3 hours


Our last week of work! Unfortunately, the programming team didn’t have much time to spend, as we all had a CS 451 project due on Tuesday. Despite that, I think my changes helped bring a last bit of needed polish to the game, so I’m happy.

I made improvements to enemy spawning: we can now configure how many of each enemy spawn in a room. This gives designers greater control over spawning, allowing us to balance rooms even better now. For example, we can ensure that only 1 Taurush enemy spawns in a room, or that 2-3 hellbats/steamons spawn alongside Asmodeus.

We can use the Max Number field to control how many of each enemy to spawn in a room (in addition to overall enemy count)

I also went and converted these spawn settings into ScriptableObjects! They used to be a set of manually-configured parameters on each Room class, but it became tedious to modify the values on each individual Room prefab when many rooms shared similar enemy variants. Now multiple rooms sharing the same spawn settings can just reference the same ScriptableObject. This will save us a lot of time preparing the remaining levels for gameplay, as we won’t have to specify enemy spawn settings on each Room (of which there’s about 40).

Lots of tedious work saved, thanks to ScriptableObjects!

This was my first opportunity to make my own ScriptableObjects, and I wish I’d tried them out earlier (they’d work great for each Tactic instance).

> Post-Mortem