# Deprecated API

## Contents

- Interfaces
- Methods
- Constructors

Deprecated Interfaces
Interface
Description
robocode.control.RobocodeListener
Since 1.6.2. Use the `IBattleListener` instead.

A listener interface for receiving callbacks from the `RobocodeEngine`.

Deprecated Methods
Method
Description
robocode._AdvancedRobot.endTurn()
Use `execute` instead.
robocode._AdvancedRobot.getGunHeadingDegrees()
Use `getGunHeading()` instead.
robocode._AdvancedRobot.getHeadingDegrees()
Use `getHeading()` instead.
robocode._AdvancedRobot.getMaxWaitCount()
This method is no longer functional. Use `AdvancedRobot.onSkippedTurn(SkippedTurnEvent)` instead.
robocode._AdvancedRobot.getRadarHeadingDegrees()
Use `getRadarHeading()` instead.
robocode._AdvancedRobot.getWaitCount()
This method is no longer functional. Use `AdvancedRobot.onSkippedTurn(SkippedTurnEvent)` instead.
robocode._AdvancedRobot.setTurnGunLeftDegrees(double)
Use `setTurnGunLeft` instead.
robocode._AdvancedRobot.setTurnGunRightDegrees(double)
Use `setTurnGunRight` instead.
robocode._AdvancedRobot.setTurnLeftDegrees(double)
Use `setTurnLeft(double)` instead.
robocode._AdvancedRobot.setTurnRadarLeftDegrees(double)
Use `setTurnRadarLeft(double)` instead.
robocode._AdvancedRobot.setTurnRadarRightDegrees(double)
Use `setTurnRadarRight` instead.
robocode._AdvancedRobot.setTurnRightDegrees(double)
Use `setTurnRight(double)` instead.
robocode._AdvancedRobot.turnGunLeftDegrees(double)
Use `turnGunLeft` instead.
robocode._AdvancedRobot.turnGunRightDegrees(double)
Use `turnGunRight` instead.
robocode._AdvancedRobot.turnLeftDegrees(double)
Use `turnLeft(double)` instead.
robocode._AdvancedRobot.turnRadarLeftDegrees(double)
Use `turnRadarLeft` instead.
robocode._AdvancedRobot.turnRadarRightDegrees(double)
Use `turnRadarRight` instead.
robocode._AdvancedRobot.turnRightDegrees(double)
Use `turnRight(double)` instead.
robocode._Robot.getBattleNum()
Use `getRoundNum()` instead.
robocode._Robot.getGunCharge()
Use `getGunHeat()` instead.
robocode._Robot.getGunImageName()
This call is not used.
robocode._Robot.getLife()
Use `getEnergy()` instead.
robocode._Robot.getNumBattles()
Use `getNumRounds()` instead.
robocode._Robot.getRadarImageName()
This call is not used.
robocode._Robot.getRobotImageName()
This call is not used.
robocode._Robot.setGunImageName(String)
This call is not used.
robocode._Robot.setRadarImageName(String)
This call is not used.
robocode._Robot.setRobotImageName(String)
This call is not used.
robocode.BulletHitEvent.getLife()
Use `BulletHitEvent.getEnergy()` instead.
robocode.BulletHitEvent.getRobotLife()
Use `BulletHitEvent.getEnergy()` instead.
robocode.BulletHitEvent.getRobotName()
Use `BulletHitEvent.getName()` instead.
robocode.control.RobocodeListener.battleAborted(BattleSpecification)
Since 1.6.2. Use the `IBattleListener.onBattleFinished()` instead.

This method is called when a battle has been aborted.

robocode.control.RobocodeListener.battleComplete(BattleSpecification, RobotResults[])
Since 1.6.2. Use the `IBattleListener.onBattleCompleted()` instead.

This method is called when a battle completes successfully.

robocode.control.RobocodeListener.battleMessage(String)
Since 1.6.2. Use the `IBattleListener.onBattleMessage()` instead.

This method is called when the game logs messages that is normally written out to the console.

robocode.HitByBulletEvent.getHeadingDegrees()
Use `HitByBulletEvent.getHeading()` instead.
robocode.HitRobotEvent.getBearingDegrees()
Use `HitRobotEvent.getBearing()` instead.
robocode.HitRobotEvent.getRobotName()
Use `HitRobotEvent.getName()` instead.
robocode.HitWallEvent.getBearingDegrees()
Use `HitWallEvent.getBearing()` instead.
robocode.RobotDeathEvent.getRobotName()
Use `RobotDeathEvent.getName()` instead.
robocode.ScannedRobotEvent.getLife()
Use `ScannedRobotEvent.getEnergy()` instead.
robocode.ScannedRobotEvent.getRobotBearing()
Use `ScannedRobotEvent.getBearing()` instead.
robocode.ScannedRobotEvent.getRobotBearingDegrees()
Use `ScannedRobotEvent.getBearing()` instead.
robocode.ScannedRobotEvent.getRobotBearingRadians()
Use `ScannedRobotEvent.getBearingRadians()` instead.
robocode.ScannedRobotEvent.getRobotDistance()
Use `ScannedRobotEvent.getDistance()` instead.
robocode.ScannedRobotEvent.getRobotHeading()
Use `ScannedRobotEvent.getHeading()` instead.
robocode.ScannedRobotEvent.getRobotHeadingDegrees()
Use `ScannedRobotEvent.getHeading()` instead.
robocode.ScannedRobotEvent.getRobotHeadingRadians()
Use `ScannedRobotEvent.getHeadingRadians()` instead.
robocode.ScannedRobotEvent.getRobotLife()
Use `ScannedRobotEvent.getEnergy()` instead.
robocode.ScannedRobotEvent.getRobotName()
Use `ScannedRobotEvent.getName()` instead.
robocode.ScannedRobotEvent.getRobotVelocity()
Use `ScannedRobotEvent.getVelocity()` instead.

Deprecated Constructors
Constructor
Description
robocode.control.RobocodeEngine(File, RobocodeListener)
Since 1.6.2. Use `RobocodeEngine(File)` and `addBattleListener()` instead.

Creates a new RobocodeEngine for controlling Robocode.

robocode.control.RobocodeEngine(RobocodeListener)
Since 1.6.2. Use `RobocodeEngine()` and `addBattleListener()` instead.

Creates a new RobocodeEngine for controlling Robocode. The JAR file of Robocode is used to determine the root directory of Robocode.

robocode.ScannedRobotEvent()
Use `ScannedRobotEvent(String, double, double, double, double, double, boolean)` instead.
robocode.ScannedRobotEvent(String, double, double, double, double, double)
Use `ScannedRobotEvent(String, double, double, double, double, double, boolean)` instead.