Battery
Bots have rechargable batteries which are drained each turn by the
current speed they are traveling. Each turn the bot is not invisible,
the battery recharges by 5 pts. The battery has a maximum capacity
of 500 pts. When the battery reaches zero, the bot's engines will
disengage and the bot will coast to a standstill.
Health
Health starts at 100 pts. and will be drained from collisions with
projectiles, bots, walls or mines. When health reaches 0, the bot
is dead. Reduced health does not affect the bot's performance.
Invisibility
Bots can enable a "cloaking device" which will make the bot invisible
to scans from other bots. The bot will still collide with other objects
and take damage normally. While the bot is invisible, the battery will
not recharge. Additionally, a bot can stay invisible for a maximum of
500 turns. Once a bot becomes visible (by disabling the cloaking device
or exceeding the time-limit), it must stay visible for as many turns
as it was invisible. The bot will be unable to fire projectiles when
invisible. If an invisible bot collides with another bot, it will still
be dectected as normal.
Driving
To move, a bot must call the Drive() method with a direction specified
in radians or as a vector. Directions specified in radians that are
outside 0-2PI will be converted to an equivalent value in this range.
Vectors will be converted to their corresponding unit vector values.
Speed can be in the range from 0-20 units per turn. Negative values will
have undefined results. Multiple Drive() commands may be issued in
a turn, however, only the last command will take effect. If the battery is
zero, calls to Drive() will fail -- the bot will neither turn nor accelerate.
When a bot issues a Drive() command, it will begin acceleration
to achieve the desired speed and direction. Acceleration and deceleration
will take 1 pt. of speed per turn.
Firing
Firing is the main mode of attack for a bot. The Fire() method will
take a radian or vector value like Drive().
Fire() will shoot a projectile that moves at 40 units per turn. When
a projectile collides with any object (wall, bot, powerup), the projectile
will explode. When a projectile hits a bot, that bot's health will
be decreased by 1 pt. Bots have only 500 projectiles at the start
of the match and may need to attain more ammo in the forms of powerups.
Bots will be able to call getProjectileInfo() to receive an update on
their projectiles' current position and info on bots which the projectile
has hit. Each time a projectile is fired, a bot's gun will heat by 10 pts.
The gun will overheat when heat is equal to or above 40 pts. Each turn,
the gun will dissipate 1 pt. of heat. If Fire() is called multiple turns
a round only the first call will take effect. Note that this is the
opposite of how the Drive() method works.
Scanning
Scan() will give a bot information on bots, projectiles and powerups
in a 45 degree sweep. The direction specified will center the sweep in the
desired direction. Scans will have no distance constraints and are not
obstructed by objects in the arena. The Scan() method will notify
the simulator of the end of a bot's turn and so must be called by the
bot to let its actions take effect.
Back to the main JavaBots page.