For context, I am contributing to a sequential turn based strategy game. I have an idea how to improve it but I feel I need some input to help me evaluate and improve it. We currently have a really dumb AI that just follows a rough set of rules each turn. I'm considering to upgrade it to a basic search based AI to not be guaranteed to win every time I play it.

There are many reason why an AI could be behind the curve. These include that is wasn't able to grow its economy well due to bad luck with map generation, that its economy was disrupted early by an enemy raid while the defending army was out of reach, that the starter army was defeated early and resources had to be invested to replace it instead of economic upgrades or more importantly there being a big awesome deciding battle with all units involved and it lost. A search based AI will be able to know when it is obvious that it is growing slower than it should, can't recover and it is now impossible to win due to runaway success. Such a runaway success is often boring to play especially if it happened 3 times in a row.

Assume there is no meta game where multiple players can gang up on the strongest one. I am open to nudge the game rules in the AI's favor if this happens. However rubber banding can give the player the impression that they are punished for playing well, the AI drags out a game into an almost stalemate or even wins unfairly.

The problem I'm trying to solve is not that the AI is losing but that the AI rolling over and dying is not fun or interesting.

It is even worse. If the player is sufficiently good he will experience that every time.

In some theories of literature, after the conclusion seems forgone and the tension is falling a new small conflict that is relevant enough or something else that justifies further elaboration and excitement. enter image description here

My idea is to have a library of endgame scenarios, a handful of which end up with player loosing unless he plays really well, most pose a small challenge that the player is entirely able to deal with and some are a "I roll over, just kill me already, please".

Are you aware of anyone trying something like this before? If someone tried this in a strategy game or even outside of strategy games before I would like to learn from them.

Can you spot some obvious problems with this idea? I already considered the AI misjudging the impossibility of winning. However, I might be to enamored with my idea to spot different problems.

How can I make sure that this still feels fair? It is easy for the AI to get some extra resources however if a player is losing I am afraid that he would feel cheapened if he got some extra money and units.

How do I help the player having fun or at-least variety when they are losing? I really have no ideas for this.

  • 1
    \$\begingroup\$ How about reinforcing the losing AI in the final battle? I'm referring to a "reinforcements have arrived" scenario. The amount of reinforcement could be proportional to the time taken by the player in mounting their assault. Ergo, if someone takes too long, they are going to be up against a large army. You can introduce stochasticity within this model as well. \$\endgroup\$ – Hassan Baig Mar 28 at 10:02

One thing you could do is give the AI an "all or nothing" response to losing. If he thinks he's going to lose, he could do something crazy like, spend all his money on the lottery. Gather all his forces and attack your fortress. Invest all his money into research for a new weapon. Hire barbarians to attack you at the risk of getting attacked himself. The options are limitless. Basically these events would keep his defeat from being boring, while also offering a chance for him to win, be strengthened, or another enemy to rise in his place. The player experience would have several options. The player would think, "He is definitely going to lose." Then he would think, "Is he seriously attacking my fortress with everything he has? Well, he's stupid". Or, "What!? He hired Barbarians! I didn't even know that was possible! I better work on a defense strategy." Whether it causes the AI to lose, or helps him, I think it would add flavor and keep it from being boring, especially if you add cool dialogue for the AI when he takes these approaches. Anyway, I hope this helps. =)


Use random events which are not actually that random.

When the player is losing the game, throw them a bone by giving them a "random" event which lets them catch up.

When there is nothing left which can stop the player from winning and the game becomes just a matter of playing down the clock, then give them a "random" event which creates a new challenge for them to solve. Not one which prevents them from winning, but one which prevents the road to victory from becoming a cakewalk from here on.


A potential problem with the endgame scenarios is that you change the already established win conditions in a way that could feel unfair to the player if they have a "certain" victory snatched away from them.

You could instead introduce extra endgame objectives. You still win regardless but completing them for "bonus points" gives you something to (optionally) focus on instead of running down the clock.

The war is practically won but the enemies has not yet given up:

  • We want to capture Berlin before the Soviets
  • Minimize civilian losses by not destroying city terrain tiles/not use bombing
  • Also capture their rocket scientists

In a similar way you could add new objectives when losing. Trying for them could become a different experience to playing the normal game and leave the player with some sense of achievement even from a lost game.

  • Don't go down without a fight, kill X amount of enemy units before you lose
  • The final charge, capture an enemy city even if you can only hold it for a turn
  • Escape in a starship to another system for a chance to rebuild and return another time (the next game)

If you can fit them within existing game mechanics (like unit movement to certain map coordinates or whatever you have) you could probably add enough of them that you can randomize which ones appear each game to add further variation. Having the same one always would be predictable and therefore less of a challenge.

  • \$\begingroup\$ This is super interesting. Thanks for making it this explicit. \$\endgroup\$ – worldsmithhelper Apr 29 at 12:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.