[Home]DavesPatentedAntiMirroringGun

Robo Home | Changes | Preferences | AllPages

PerceptualDuelist doesn't have anti-mirroring code anymore - it was not very useful in a perceptual bot because you aren't allowed to store data, so it was hard to tell if the enemy was actually mirroring or if they just happened to be in a position that made it look like they were. It would be more useful in a non-perceptual bot where you could track the enemy's movement over time and thus be more certain that you're being mirrored.

PerceptualDuelist detected x, y, and xy mirroring by checking if the opponent was within 20 units of the mirrored point. When it detected mirroring, PerceptualDuelist's anti-mirroring system did the following:

  1. Select our bot's next destination point.
  2. Calculate time it will take our bot to drive to the destination point. (Don't forget acceleration - you can't just divide by 8)
  3. Calculate mirrored destination point.
  4. Calculate bullet power required for a bullet fired from our current location to reach the mirrored destination point at the time given by step 2. Since they are mirroring us the time for us to drive to our destination is the same as the time for them to drive to the mirrored destination. Remember that bullet speed = 20 - 3 * bullet power.
  5. Turn gun toward mirrored destination point, holding fire until gun turn is complete. Since PerceptualDuelist was a perceptual bot I had to use waitFor(new GunTurnCompleteCondition?(this)). This caused it to do nothing for several turns while the gun was turning.
  6. Fire with bullet power from step 4.

To account for the fact that our enemy's mirroring might not be perfect, PerceptualDuelist stopped at the destination for a while and added 4 to the time calculated in step 2.

This system allowed PerceptualDuelist to win 100-0 vs. some versions of PerceptualCaymic?. :-)

--David Alves

The most interesting part of AntiMirroring? for me would be to get an idea about how to identify that you're being mirrored. -- PEZ

I'd have thought the way to find out if an opponent was mirroring you would be to pattern match between your own history and the targets history. Probably not worth the effort I think. But it might be fun to see someone else do it! :) -wolfman

Marshmallow has had a half-good anti-mirror gun a while now. It simply asks the movement system where the bot is going and shoots there. The problem with knowing if I'm being mirrored or not is solved by the VirtualGuns statistics. -- PEZ


Robo Home | Changes | Preferences | AllPages
Edit text of this page | View other revisions
Last edited February 29, 2004 9:02 EST by David Alves (diff)
Search: