Energy Drop

From RoboWiki
Jump to: navigation, search

A decrease of energy observed in another robot. Because Robocode robots cannot see mid-air bullets, the only way to detect that a bullet was fired is by noticing a change in the opponent's energy level.

How it works

The following events impact a robot's energy level between scans:

  1. Getting hit by a bullet
  2. Hitting another bot with a bullet
  3. Running into another robot
  4. Running into a wall
  5. Firing a bullet
  6. Inactivity energy drop

In a duel, bullet damage (#1), life gained (#2), and robot collisions (#3) can be fully accounted for - i.e., you are made aware of them through other events before onScannedRobot . Another bot running into a wall (#4) can only be approximated: he can change speed, hit the wall, receive damage based on speed, and come to a stop, without his opponent ever knowing what speed he used. This is largely moot, though, since such wall collisions are rare and gun heat tracking can often prove that no bullet was fired.

Since it is possible to account for nearly every other energy-changing event happening to your opponent, any remaining energy drop is the firepower of a bullet that he fired.

See also

Personal tools
This is a cached copy of the requested page, and may not be up to date.

Sorry! This site is experiencing technical difficulties.

Try waiting a few minutes and reloading.

(Can't contact the database server: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) (localhost))


You can try searching via Google in the meantime.
Note that their indexes of our content may be out of date.