I am developing a small, turn-based game with spaceships. The user-controlled spaceship has two modes, let's call them offense and defense mode. The user can freely switch between modes. There are three types of enemy-ships. Whenever the user's ship meets one or more enemy-ships, a fight calculation should take place, which can have exactly two outcomes: either the user's ship wins (and does not carry away any damage), or the game is over. Encounters are kinda, but not completely random so one can expect a certain enemy and change the mode accordingly.
For reference, multiple enemy encouters at once might happen, and as a rough idea, the userShip usually is expected to lose if it has to fight 2-5 enemies. Like 2 are too much, if the active fight mode is disadvantageous, whereas the userShip can win against up to four ships, if the mode is advantageous. For encounters with multiple enemy types, the numbers shall be somewhere in between.
My requirements for the combat system are:
- completely deterministic
- one mode must not be clearly superior to the other mode. Ideally, one mode is advantageous against a certain enemy type, while the other mode is advantageous against another enemy type (not sure what to do about the third enemy type though)
- must be somehow scaleable, i.e. there should be three difficulty settings which shall be taken into account.
- ships have three attributes: Attack, Defense, Speed (however, this isn't set in stone and could be changed at will)
My best idea so far:
- assign each ship type base stats (Attack/Defense/Speed, floating point numbers):
enemy 1: (5/10/15)
enemy 2: (15/5/10)
enemy 3: (10/15/5)
create a modifier-table that multiplicates the userShip baseStats with a multiplicator depending on a) userShip-mode and b) enemyShip-type.
have the combat system compare each of the three stats (if multiple enemies involved, their combined strength), and depending on the difficulty setting, the userShip wins if the difference of at least 2 of the 3 attributes is smaller than . That way, I would have the scalability.
However... I was unable to design the modifier table in a way that the modifiers actually make a noticeable difference AND the user has an incentive to switch between modes when he expects a certain enemy in the next turn.
The biggest problem is the nature of the binary combat outcome. This makes it that the floating point multiplicators neglegible most of the time.
Also, I feel like I have way too many parameters (fight mode, attack, defense, speed, difficulty-setting, modifier) for such a simple calculation, but I cannot really remove any other than the modifier, and they all should be at least a little bit relevant for the combat outcome.
Also, I'm not sure how to deal with the third ship type, as there only are two modes. If the mode does not matter at all, that's poor design I think. I could add a third mode for the userShip, however that would introduce even more parameters for the combat. Unsure about that.
Any ideas how to design a combat system under these conditions?