Another one bites the dust : Post Mortem on my first Killbot battle.

I spent way too much time for this assessment, and ended up last of all in the round-robin tournament.  I think the thing that saved me from finishing last of all in the tournament proper was that I started immediately into round two and then after losing my first match went immediately into round two of the repechage.

The immediate flaw was my accuracy.  I was only taking it from the enemies last known position and its current position.  As a result, many of my bullets were wasted by complete misses, especially when taken from longer ranges.

The next flaw was hitting the wall in the top right hand corner.  I have gone over my code and have seen what that issue was.  The problem was that, if the enemy was firing bullets at me, I was calculating the perpendicular angle to the bullets and moving along that vector.  I had some conditions set up where if the enemy was within a certain rang of my x or y value, I would invert the particular axis of the perpendicular axis so that I wouldn’t get trapped against the wall.  The problem was in the overlap of where x < 8 and y > 26.  I had conflicting versions of where the bot was supposed to go and as a result, it crashed into the wall and lost health continually bumping the wall.

The third immediate flaw was that the movement wasn’t random enough, as was shown by the unmerciful treatment by Quickshot26.  Chris’s accuracy was uncanny, and by his own admission, was really set up to detect linear movement.

There are several things I can do to improve the accuracy of my bot.  The first is that I had been guessing my bullet speed from earlier e_bullet scans and diving by the number if frames I though had occurred between the scans.  I could have been using input.bulletSpeed to give an accurate velocity on the bullets.  The same goes for my bot’s velocity.  I was calculating that from my previous position and my current position.  Again, I should have been using input.velocity to accurately calculate my velocity.

This will be the main thing I will concentrate on as I work out my pathfinding algorithms for the maze battle.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s