So, seeing some more unbearable bug-hunt pain on certain stream, I've decided to give surrender mechanic a try.
I know it's highly arguable, but let's at least try, maybe something comes out of it... and if not, well, we tried.
So basic idea is that once the surrender-condition applies, all your units will get X psi vision (e.g. X=20) until the end of the battle.
I don't want to auto-end battle, last enemies can be the most dangerous ones, I just want to spend (a lot) less time searching for them.
Basic (global, configurable) attributes for surrender are:
1. max number of enemies that can surrender (e.g. 2)
2. min turn for surrendering (e.g. 20)
If those two are not met, nothing else is checked.
3. enemies which cannot surrender (e.g. VIPs, mercs, star gods?)
If any of these remain, surrender doesn't happen. No more checks.
Then, we introduce a few rules (if any of them applies, surrender):
Rule A: if no enemy has a weapon anymore (i.e. both hands are empty), surrender
Rule B: if average morale of all remaining enemies is below Y (e.g. Y=40), surrender
Rule C: if no enemy moved at least Z tiles (e.g. Z=20) in the last Q turns (e.g. Q=3), surrender -- distance moved per turn is measured at the beginning and the end of their turn (i.e. running in circles in the toilet is no distance).
Checks would be done at the beginning of each player's turn.
Once surrendered, a special avatar (e.g. angry glowing-eyes monster
) would be displayed instead of usual avatar... to indicate to the player, that surrender mode was activated.
Feedback is welcome... but please try to keep it simple, only if there is something really wrong with my algorithm or if I have missed some super-important rule.