gordon-david / 2DGame

0 stars 0 forks source link

Game Balance #16

Closed gordon-david closed 5 years ago

gordon-david commented 5 years ago

If Enemies and Players can use the same Creature class, we can make a 'combat metric' based off of their stats. It could be a weighted sum of the abilities (with higher weights given to more 'combat important' stats like attack).

combatMetric = A attack + B defense + C agility + D maxHealth -> here A, B, C, D are constants that give each ability 'more' or 'less' weight in relation to the other abilities.

This way, we could generate Enemy stats that fit to an appropriate combat metric to the player's combat metric. Sort of like the leveling system in Skyrim, where enemies change their level depending on the players level, except we don't have 'levels'.

gordon-david commented 5 years ago

Thinking more about this, this is not super effective/would need a good neural net to train for those weights. I might look into a way to just increase or decrease a standard array of abilities to keep up with the player's stats. I.e. [2, 2, 2, 10] * (sum of player's stats/4), some simpler function.