Module/Targeting/HeadOnTargeting
Jump to navigation
Jump to search
package jab.targeting; import jab.Module; import jab.Targeting; public class HeadOnTargeting extends Targeting { public HeadOnTargeting(Module bot) { super(bot); } public void target() { double absoluteBearing = bot.getHeadingRadians() + bot.enemy.bearingRadians; bot.setTurnGunRightRadians(robocode.util.Utils.normalRelativeAngle(absoluteBearing -bot.getGunHeadingRadians())); } }