Day 9 - Final rush for the AI


Final day for me.

I rushed the AI like crazy, and added a victory and defeat screen (didn't got time for them in assembly, so I made them in javascript).

I added coins display for each player, a way to move to the next level when defeating all the enemy units, and display the current level number.

For the AI, I spent a lot of time debugging the scanning functions that allows the AI to see what is in front of units, and act accordingly.
In the end, the AI just chooses a random unit each turn (I wanted to make it risky but feasible to walk into an opponent's unit without fearing immediate death). It then scans some 15 tiles around the unit, and tries to find an enemy or a free space to move.

My biggest regret is that when it finds an enemy, it tries to move on it instead of moving close to it.
I had to leave it that way, otherwise the AI would never try to attack, and only move close to units.

Anyways, I had a lot of fun coding this, especially in (lispy) assembly :D
My code tastes like it has been extracted from a NES ROM, and I felt like a game programmer in the 80s. Good vibes :)

Leave a comment

Log in with itch.io to leave a comment.