[Home]FastTargeting/HeadOnTargeting

Robo Home | FastTargeting | Changes | Preferences | AllPages

Showing revision 2
To shoot using HeadOnTargeting:

In onScannedRobot, add:

double absoluteBearing = getHeadingRadians() + e.getBearingRadians();
setTurnGunRightRadians(robocode.util.Utils.normalRelativeAngle(absoluteBearing - getGunHeadingRadians());


The simple strategy of Targeting where you last saw the enemy. Works surprisingly well against surprisingly many bots. Especially in Melee battle. -- PEZ

Bots using this technique:


Robo Home | FastTargeting | Changes | Preferences | AllPages
Edit revision 2 of this page | View other revisions | View current revision
Edited July 5, 2005 6:28 EST by Jokester (diff)
Search: