Index
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form
A
- A - Enum constant in enum class battlecode.common.Team
-
Team A.
- actionCooldown - Variable in enum class battlecode.common.UnitType
- actionRadiusSquared - Variable in enum class battlecode.common.UnitType
- add(Direction) - Method in class battlecode.common.MapLocation
-
Returns a new MapLocation object representing a location one unit in distance from this one in the given direction.
- adjacentLocation(Direction) - Method in interface battlecode.common.RobotController
-
Returns the location adjacent to current location in the given direction.
- allDirections() - Static method in enum class battlecode.common.Direction
-
Returns a list of all directions.
- ALLY_PRIMARY - Enum constant in enum class battlecode.common.PaintType
- ALLY_SECONDARY - Enum constant in enum class battlecode.common.PaintType
- aoeAttackStrength - Variable in enum class battlecode.common.UnitType
- attack(MapLocation) - Method in interface battlecode.common.RobotController
-
Performs the specific attack for this robot type, defaulting to the primary color
- attack(MapLocation, boolean) - Method in interface battlecode.common.RobotController
-
Performs the specific attack for this robot type.
- ATTACK_MOPPER_SWING_COOLDOWN - Static variable in class battlecode.common.GameConstants
-
The amount added to the action cooldown counter after attacking (as a mopper for the swing attack)
- attackCost - Variable in enum class battlecode.common.UnitType
- attackMoneyBonus - Variable in enum class battlecode.common.UnitType
- attackStrength - Variable in enum class battlecode.common.UnitType
B
- B - Enum constant in enum class battlecode.common.Team
-
Team B.
- battlecode.common - package battlecode.common
- BROADCAST_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maxmimum squared radius a tower can broadcast a message
- broadcastMessage(int) - Method in interface battlecode.common.RobotController
-
Broadcasts a message to all friendly towers within the broadcasting radius.
- BUILD_ROBOT_COOLDOWN - Static variable in class battlecode.common.GameConstants
-
The amount added to the action cooldown counter after a tower builds a robot
- BUILD_ROBOT_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance from a tower for building robots
- BUILD_TOWER_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance from a robot for building and upgrading towers
- buildRobot(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Spawns a robot at the given location.
C
- canAttack(MapLocation) - Method in interface battlecode.common.RobotController
-
Tests whether this robot can attack the given location.
- canBroadcastMessage() - Method in interface battlecode.common.RobotController
-
Returns true if this tower can broadcast a message.
- canBuildRobot(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if a tower can spawn a robot at the given location.
- canCompleteResourcePattern(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if the robot can complete a 5x5 special resource pattern centered at the given location.
- canCompleteTowerPattern(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if the robot can build a tower at the given location.
- canMark(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if the location can be marked.
- canMarkResourcePattern(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if the robot can mark a 5x5 special resource pattern centered at the given location.
- canMarkTowerPattern(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if the robot can build a tower by marking a 5x5 pattern centered at the given location.
- canMopSwing(Direction) - Method in interface battlecode.common.RobotController
-
Tests whether this robot (which must be a mopper) can perform a mop swing in a specific direction
- canMove(Direction) - Method in interface battlecode.common.RobotController
-
Checks whether this robot can move one step in the given direction.
- canPaint(MapLocation) - Method in interface battlecode.common.RobotController
-
Tests whether this robot can paint the given location.
- canRemoveMark(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if a mark at the location can be removed.
- canSendMessage(MapLocation) - Method in interface battlecode.common.RobotController
-
Returns true if the unit can send a message to a specific location, false otherwise.
- canSendMessage(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Returns true if the unit can send a message to a specific location, false otherwise.
- canSenseLocation(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks whether the given location is within the robot's vision range, and if it is on the map.
- canSenseRobot(int) - Method in interface battlecode.common.RobotController
-
Tests whether the given robot exists and if it is within this robot's vision range.
- canSenseRobotAtLocation(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks whether a robot is at a given location.
- CANT_DO_THAT - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to perform an action it can't.
- CANT_MOVE_THERE - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to move into a non-empty location.
- CANT_SENSE_THAT - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to sense a robot that no longer exists or is no longer in this robot's vision range.
- canTransferPaint(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Tests whether you can transfer paint to a given robot/tower.
- canUpgradeTower(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks if a tower can be upgraded by verifying conditions on the location, team, tower level, and cost.
- canUpgradeType() - Method in enum class battlecode.common.UnitType
- cardinalDirections() - Static method in enum class battlecode.common.Direction
-
Returns a list of all cardinal directions.
- CENTER - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing nowhere.
- Clock - Class in battlecode.common
-
Clock is a singleton that allows contestants to introspect the state of their running code.
- compareTo(MapLocation) - Method in class battlecode.common.MapLocation
-
A comparison function for MapLocations.
- COMPLETE_RESOURCE_PATTERN_COST - Static variable in class battlecode.common.GameConstants
-
The money cost of completing a resource pattern
- completeResourcePattern(MapLocation) - Method in interface battlecode.common.RobotController
-
Completes a 5x5 special resource pattern centered at the given location.
- completeTowerPattern(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Builds a tower at the given location.
- COOLDOWN_LIMIT - Static variable in class battlecode.common.GameConstants
-
If the amount of cooldown is at least this value, a robot cannot act.
- COOLDOWNS_PER_TURN - Static variable in class battlecode.common.GameConstants
-
The number of cooldown turns reduced per turn.
- copy() - Method in class battlecode.common.Message
D
- DEFENSE_ATTACK_BUFF_AOE_EFFECTIVENESS - Static variable in class battlecode.common.GameConstants
-
The percent of the defense tower damage buff that is applied to AoE attacks
- DEFENSE_TOWER_PATTERN - Static variable in class battlecode.common.GameConstants
-
The 32 bit representation of the defense tower pattern.
- Direction - Enum Class in battlecode.common
-
This enumeration represents a direction from one MapLocation to another.
- DIRECTION_ORDER - Static variable in enum class battlecode.common.Direction
- directionTo(MapLocation) - Method in class battlecode.common.MapLocation
-
Returns the closest approximate Direction from this MapLocation to
location. - disintegrate() - Method in interface battlecode.common.RobotController
-
Destroys the robot.
- distanceSquaredTo(MapLocation) - Method in class battlecode.common.MapLocation
-
Computes the squared distance from this location to the specified location.
- dx - Variable in enum class battlecode.common.Direction
-
Change in x.
- dy - Variable in enum class battlecode.common.Direction
-
Change in y.
E
- EAST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing east (right on screen).
- EMPTY - Enum constant in enum class battlecode.common.PaintType
- ENEMY_PRIMARY - Enum constant in enum class battlecode.common.PaintType
- ENEMY_SECONDARY - Enum constant in enum class battlecode.common.PaintType
- equals(Object) - Method in class battlecode.common.MapLocation
-
Two MapLocations are regarded as equal iff their coordinates are the same.
- equals(Object) - Method in class battlecode.common.RobotInfo
- EXCEPTION_BYTECODE_PENALTY - Static variable in class battlecode.common.GameConstants
-
The bytecode penalty that is imposed each time an exception is thrown.
- EXTRA_DAMAGE_FROM_DEFENSE_TOWER - Static variable in class battlecode.common.GameConstants
-
The extra damage all ally towers get for each level 1 defense tower
- EXTRA_RESOURCES_FROM_PATTERN - Static variable in class battlecode.common.GameConstants
-
The extra resources per turn that resource patterns give
- EXTRA_TOWER_DAMAGE_LEVEL_INCREASE - Static variable in class battlecode.common.GameConstants
-
The increase in extra damage for ally towers for upgrading a defense tower
G
- GAME_DEFAULT_SEED - Static variable in class battlecode.common.GameConstants
-
The default game seed.
- GAME_MAX_NUMBER_OF_ROUNDS - Static variable in class battlecode.common.GameConstants
-
The maximum number of rounds in a game.
- GameActionException - Exception Class in battlecode.common
-
An exception caused by a robot's interaction with the game world.
- GameActionException(GameActionExceptionType, String) - Constructor for exception class battlecode.common.GameActionException
-
Creates a GameActionException with the given type and message.
- GameActionExceptionType - Enum Class in battlecode.common
-
Enumerates the possible errors in GameWorld interactions that cause a GameActionException to be thrown.
- GameConstants - Class in battlecode.common
-
GameConstants defines constants that affect gameplay.
- GameConstants() - Constructor for class battlecode.common.GameConstants
- getActionCooldownTurns() - Method in interface battlecode.common.RobotController
-
Returns the number of action cooldown turns remaining before this unit can act again.
- getAllLocationsWithinRadiusSquared(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Returns a list of all locations within the given radiusSquared of a location.
- getBaseType() - Method in enum class battlecode.common.UnitType
- getBytecodeNum() - Static method in class battlecode.common.Clock
-
Returns the number of bytecodes the current robot has executed since the beginning of the current round.
- getBytecodesLeft() - Static method in class battlecode.common.Clock
-
Returns the number of bytecodes this robot has left in this round.
- getBytes() - Method in class battlecode.common.Message
- getChips() - Method in interface battlecode.common.RobotController
-
Alias for getMoney
- getDeltaX() - Method in enum class battlecode.common.Direction
-
Returns the delta X of the direction.
- getDeltaY() - Method in enum class battlecode.common.Direction
-
Returns the delta Y of the direction.
- getDirectionOrderNum() - Method in enum class battlecode.common.Direction
- getHealth() - Method in interface battlecode.common.RobotController
-
Returns this robot's current health.
- getHealth() - Method in class battlecode.common.RobotInfo
-
Returns the health of this robot.
- getID() - Method in interface battlecode.common.RobotController
-
Returns the ID of this robot.
- getID() - Method in class battlecode.common.RobotInfo
-
Returns the ID of this robot.
- getLocation() - Method in interface battlecode.common.RobotController
-
Returns this robot's current location.
- getLocation() - Method in class battlecode.common.RobotInfo
-
Returns the location of this robot.
- getMapHeight() - Method in interface battlecode.common.RobotController
-
Returns the height of the game map.
- getMapLocation() - Method in class battlecode.common.MapInfo
-
Returns the location of this square
- getMapWidth() - Method in interface battlecode.common.RobotController
-
Returns the width of the game map.
- getMark() - Method in class battlecode.common.MapInfo
-
Returns the mark value of this square
- getMoney() - Method in interface battlecode.common.RobotController
-
Returns the amount of money that this robot's team has.
- getMovementCooldownTurns() - Method in interface battlecode.common.RobotController
-
Returns the number of movement cooldown turns remaining before this unit can move again.
- getNextLevel() - Method in enum class battlecode.common.UnitType
- getNumberTowers() - Method in interface battlecode.common.RobotController
-
Returns how many allied towers are currently alive.
- getPaint() - Method in class battlecode.common.MapInfo
-
Returns the paint value of this square
- getPaint() - Method in interface battlecode.common.RobotController
-
Returns this robot's current paint amount.
- getPaintAmount() - Method in class battlecode.common.RobotInfo
-
Returns the paint amount of this robot.
- getResourcePattern() - Method in interface battlecode.common.RobotController
-
Returns the 5x5 resource pattern.
- getRound() - Method in class battlecode.common.Message
- getRoundNum() - Method in interface battlecode.common.RobotController
-
Returns the current round number, where round 1 is the first round of the match.
- getSenderID() - Method in class battlecode.common.Message
- getTeam() - Method in interface battlecode.common.RobotController
-
Returns this robot's Team.
- getTeam() - Method in class battlecode.common.RobotInfo
-
Returns the team that this robot is on.
- getTimeElapsed() - Static method in class battlecode.common.Clock
-
Returns the total amount of time that this team's robots have collectively spent executing since the beginning of the match.
- getTimeLeft() - Static method in class battlecode.common.Clock
-
Returns the total amount of execution time left this team has before they timeout
- getTowerPattern(UnitType) - Method in interface battlecode.common.RobotController
-
Returns the 5x5 pattern needed to be drawn to build a tower of the specified type.
- getType() - Method in exception class battlecode.common.GameActionException
-
Gives the type of gameworld interaction that caused this GameActionException, which was specified when this instance was constructed.
- getType() - Method in interface battlecode.common.RobotController
-
Returns what UnitType this robot is.
- getType() - Method in class battlecode.common.RobotInfo
-
Returns this robot's type.
H
- hashCode() - Method in class battlecode.common.MapLocation
- hashCode() - Method in class battlecode.common.RobotInfo
- hasRuin() - Method in class battlecode.common.MapInfo
-
Returns if this square has a ruin.
- health - Variable in class battlecode.common.RobotInfo
-
The health of the robot.
- health - Variable in enum class battlecode.common.UnitType
I
- ID - Variable in class battlecode.common.RobotInfo
-
The unique ID of the robot.
- INCREASED_COOLDOWN_INTERCEPT - Static variable in class battlecode.common.GameConstants
-
Intercept in the formula for the increased cooldown
- INCREASED_COOLDOWN_SLOPE - Static variable in class battlecode.common.GameConstants
-
Slope of paint in the formula for the increased cooldown
- INCREASED_COOLDOWN_THRESHOLD - Static variable in class battlecode.common.GameConstants
-
Percent of paint capacity at which a robot begins to face increased cooldowns
- INDICATOR_STRING_MAX_LENGTH - Static variable in class battlecode.common.GameConstants
-
The maximum length of indicator strings that a player can associate with a robot.
- INITIAL_ROBOT_PAINT_PERCENTAGE - Static variable in class battlecode.common.GameConstants
-
The percentage of a robot's paint capacity that is full when first built.
- INITIAL_TEAM_MONEY - Static variable in class battlecode.common.GameConstants
-
The amount of money each team starts with.
- INITIAL_TOWER_PAINT_AMOUNT - Static variable in class battlecode.common.GameConstants
-
How much paint that towers start with when first built
- INTERNAL_ERROR - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Internal error in the GameWorld engine.
- IS_NOT_READY - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to execute an action, but is not currently idle.
- isActionReady() - Method in interface battlecode.common.RobotController
-
Tests whether the robot can act.
- isAdjacentTo(MapLocation) - Method in class battlecode.common.MapLocation
-
Determines whether this location is adjacent to a given location.
- isAlly() - Method in enum class battlecode.common.PaintType
- isEnemy() - Method in enum class battlecode.common.PaintType
- isLocationOccupied(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks whether a robot is at a given location.
- isMovementReady() - Method in interface battlecode.common.RobotController
-
Tests whether the robot can move.
- isPassable() - Method in class battlecode.common.MapInfo
-
Returns if this square is passable.
- isPlayer() - Method in enum class battlecode.common.Team
-
Returns whether a robot of this team is a player-controlled entity (team A or team B).
- isResourcePatternCenter() - Method in class battlecode.common.MapInfo
-
Returns whether this tile is at the center of an ally resource pattern (regardless of whether the pattern is active yet)
- isRobotType() - Method in enum class battlecode.common.UnitType
- isSecondary() - Method in enum class battlecode.common.PaintType
- isTowerType() - Method in enum class battlecode.common.UnitType
- isWall() - Method in class battlecode.common.MapInfo
-
Returns if this square is a wall.
- isWithinDistanceSquared(MapLocation, int) - Method in class battlecode.common.MapLocation
-
Determines whether this location is within a specified distance from target location.
L
- level - Variable in enum class battlecode.common.UnitType
- LEVEL_ONE_DEFENSE_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_ONE_MONEY_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_ONE_PAINT_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_THREE_DEFENSE_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_THREE_MONEY_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_THREE_PAINT_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_TWO_DEFENSE_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_TWO_MONEY_TOWER - Enum constant in enum class battlecode.common.UnitType
- LEVEL_TWO_PAINT_TOWER - Enum constant in enum class battlecode.common.UnitType
- location - Variable in class battlecode.common.RobotInfo
-
The current location of the robot.
M
- MAP_MAX_HEIGHT - Static variable in class battlecode.common.GameConstants
-
The maximum possible map height.
- MAP_MAX_WIDTH - Static variable in class battlecode.common.GameConstants
-
The maximum possible map width.
- MAP_MIN_HEIGHT - Static variable in class battlecode.common.GameConstants
-
The minimum possible map height.
- MAP_MIN_WIDTH - Static variable in class battlecode.common.GameConstants
-
The minimum possible map width.
- MapInfo - Class in battlecode.common
- MapInfo(MapLocation, boolean, boolean, PaintType, PaintType, boolean, boolean) - Constructor for class battlecode.common.MapInfo
- MapLocation - Class in battlecode.common
-
This class is an immutable representation of two-dimensional coordinates in the battlecode world.
- MapLocation(int, int) - Constructor for class battlecode.common.MapLocation
-
Creates a new MapLocation representing the location with the given coordinates.
- mark(MapLocation, boolean) - Method in interface battlecode.common.RobotController
-
Adds a mark at the given location.
- MARK_PATTERN_PAINT_COST - Static variable in class battlecode.common.GameConstants
-
The paint cost of marking a resource or tower pattern
- MARK_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance for marking a map location or removing a marker
- markResourcePattern(MapLocation) - Method in interface battlecode.common.RobotController
-
Marks a 5x5 special resource pattern centered at the given location.
- markTowerPattern(UnitType, MapLocation) - Method in interface battlecode.common.RobotController
-
Builds a tower by marking a 5x5 pattern centered at the given location.
- MAX_MESSAGE_BYTES - Static variable in class battlecode.common.GameConstants
-
The maximum amount of bytes that can be encoded in a message
- MAX_MESSAGES_SENT_ROBOT - Static variable in class battlecode.common.GameConstants
-
The maximum number of messages a robot can send per turn
- MAX_MESSAGES_SENT_TOWER - Static variable in class battlecode.common.GameConstants
-
The maximum number of messages a tower can send per turn
- MAX_NUMBER_OF_TOWERS - Static variable in class battlecode.common.GameConstants
-
The maximum number of towers that a team can have.
- MAX_TEAM_EXECUTION_TIME - Static variable in class battlecode.common.GameConstants
-
The maximum execution time that can be spent on a team in one match.
- MAX_TURNS_WITHOUT_PAINT - Static variable in class battlecode.common.GameConstants
-
DEPRECATED: See NO_PAINT_DAMAGE
- MAX_WALL_PERCENTAGE - Static variable in class battlecode.common.GameConstants
-
The maximum percentage of the map that can be walls
- Message - Class in battlecode.common
- Message(int, int, int) - Constructor for class battlecode.common.Message
- MESSAGE_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum squared radius a robot can send a message to
- MESSAGE_ROUND_DURATION - Static variable in class battlecode.common.GameConstants
-
The maximum number of rounds a message will exist for
- MIN_RUIN_SPACING_SQUARED - Static variable in class battlecode.common.GameConstants
-
The minimum distance between ruins on the map
- MONEY_TOWER_PATTERN - Static variable in class battlecode.common.GameConstants
-
The 32 bit representation of the money tower pattern.
- moneyCost - Variable in enum class battlecode.common.UnitType
- moneyPerTurn - Variable in enum class battlecode.common.UnitType
- MOPPER - Enum constant in enum class battlecode.common.UnitType
- MOPPER_ATTACK_PAINT_ADDITION - Static variable in class battlecode.common.GameConstants
-
The amount of paint added to self in a regular mopper attack
- MOPPER_ATTACK_PAINT_DEPLETION - Static variable in class battlecode.common.GameConstants
-
The amount of paint depleted from enemy in a regular mopper attack
- MOPPER_PAINT_PENALTY_MULTIPLIER - Static variable in class battlecode.common.GameConstants
-
Multiplier for paint penalties moppers face for ending on non-ally territory.
- MOPPER_SWING_PAINT_DEPLETION - Static variable in class battlecode.common.GameConstants
-
The amount of paint depleted from enemies in a swing mopper attack
- mopSwing(Direction) - Method in interface battlecode.common.RobotController
-
Performs a mop swing in the given direction (only for moppers!)
- move(Direction) - Method in interface battlecode.common.RobotController
-
Moves one step in the given direction.
- MOVEMENT_COOLDOWN - Static variable in class battlecode.common.GameConstants
-
The amount added to the movement cooldown counter when moving
N
- NEUTRAL - Enum constant in enum class battlecode.common.Team
-
Neutral robots.
- NO_PAINT_DAMAGE - Static variable in class battlecode.common.GameConstants
-
A robot takes this much damage every time it ends a turn with 0 paint
- NO_ROBOT_THERE - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to perform an action on another robot, but there is no suitable robot there.
- NORTH - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing north (up on screen).
- NORTHEAST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing northeast (up and to the right on screen).
- NORTHWEST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing northwest (up and to the left on screen).
- NOT_ENOUGH_RESOURCE - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to perform an action for which it does not have enough resources.
- NUMBER_INITIAL_DEFENSE_TOWERS - Static variable in class battlecode.common.GameConstants
-
The number of defense towers a player starts with
- NUMBER_INITIAL_MONEY_TOWERS - Static variable in class battlecode.common.GameConstants
-
The number of money towers a player starts with
- NUMBER_INITIAL_PAINT_TOWERS - Static variable in class battlecode.common.GameConstants
-
The number of paint towers a player starts with
- NUMBER_INITIAL_TOWERS - Static variable in class battlecode.common.GameConstants
-
The number of towers a player starts with.
O
- onTheMap(MapLocation) - Method in interface battlecode.common.RobotController
-
Checks whether a MapLocation is on the map.
- opponent() - Method in enum class battlecode.common.Team
-
Determines the team that is the opponent of this team.
- opposite() - Method in enum class battlecode.common.Direction
-
Computes the direction opposite this one.
- OUT_OF_RANGE - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when a robot tries to perform an action on a location that is outside its range.
P
- PAINT_PERCENT_TO_WIN - Static variable in class battlecode.common.GameConstants
-
The percent of the map which a team needs to paint to win.
- PAINT_TOWER_PATTERN - Static variable in class battlecode.common.GameConstants
-
The 32 bit representation of the paint tower pattern.
- PAINT_TRANSFER_COOLDOWN - Static variable in class battlecode.common.GameConstants
-
THe amount added to the action cooldown counter after transferring paint
- PAINT_TRANSFER_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance for transferring paint from/to an ally robot or tower
- paintAmount - Variable in class battlecode.common.RobotInfo
-
The current paint amount of the robot.
- paintCapacity - Variable in enum class battlecode.common.UnitType
- paintCost - Variable in enum class battlecode.common.UnitType
- paintPerTurn - Variable in enum class battlecode.common.UnitType
- PaintType - Enum Class in battlecode.common
- PATTERN_SIZE - Static variable in class battlecode.common.GameConstants
-
The width and height of the patterns that robots can draw
- PENALTY_ENEMY_TERRITORY - Static variable in class battlecode.common.GameConstants
-
Paint penalty for ending a turn on enemy territory
- PENALTY_NEUTRAL_TERRITORY - Static variable in class battlecode.common.GameConstants
-
Paint penalty for ending a turn on neutral territory
R
- readMessages(int) - Method in interface battlecode.common.RobotController
-
Reads all messages sent to this unit within the past 5 rounds if roundNum = -1, or only messages sent from the specified round otherwise
- removeMark(MapLocation) - Method in interface battlecode.common.RobotController
-
Removes the mark at the given location.
- resign() - Method in interface battlecode.common.RobotController
-
Causes your team to lose the game.
- RESOURCE_PATTERN - Static variable in class battlecode.common.GameConstants
-
The 32 bit representation of the special resource pattern.
- RESOURCE_PATTERN_ACTIVE_DELAY - Static variable in class battlecode.common.GameConstants
-
Resource patterns must exist for this many turns before they start producing resources
- RESOURCE_PATTERN_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance from a robot for completing special resource patterns
- ROBOT_BYTECODE_LIMIT - Static variable in class battlecode.common.GameConstants
-
The maximum number of bytecodes a robot is allowed to use in one turn
- RobotController - Interface in battlecode.common
-
A RobotController allows contestants to make their robot sense and interact with the game world.
- RobotInfo - Class in battlecode.common
-
RobotInfo stores basic information that was 'sensed' of another Robot.
- RobotInfo(int, Team, UnitType, int, MapLocation, int) - Constructor for class battlecode.common.RobotInfo
- rotateLeft() - Method in enum class battlecode.common.Direction
-
Computes the direction 45 degrees to the left (counter-clockwise) of this one.
- rotateRight() - Method in enum class battlecode.common.Direction
-
Computes the direction 45 degrees to the right (clockwise) of this one.
- ROUND_OUT_OF_RANGE - Enum constant in enum class battlecode.common.GameActionExceptionType
-
Indicates when round number is out of range.
S
- sendMessage(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Sends a message (contained in an int, so 4 bytes) to a specific unit at a location on the map, if it is possible
- senseMapInfo(MapLocation) - Method in interface battlecode.common.RobotController
-
Senses the map info at a location.
- senseNearbyMapInfos() - Method in interface battlecode.common.RobotController
-
Return map info for all senseable locations.
- senseNearbyMapInfos(int) - Method in interface battlecode.common.RobotController
-
Return map info for all senseable locations within a radius squared.
- senseNearbyMapInfos(MapLocation) - Method in interface battlecode.common.RobotController
-
Return map info for all senseable locations within vision radius of a center location.
- senseNearbyMapInfos(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Return map info for all senseable locations within a radius squared of a center location.
- senseNearbyRobots() - Method in interface battlecode.common.RobotController
-
Returns all robots within vision radius.
- senseNearbyRobots(int) - Method in interface battlecode.common.RobotController
-
Returns all robots that can be sensed within a certain distance of this robot.
- senseNearbyRobots(int, Team) - Method in interface battlecode.common.RobotController
-
Returns all robots of a given team that can be sensed within a certain distance of this robot.
- senseNearbyRobots(MapLocation, int, Team) - Method in interface battlecode.common.RobotController
-
Returns all robots of a given team that can be sensed within a certain radius of a specified location.
- senseNearbyRuins(int) - Method in interface battlecode.common.RobotController
-
Returns the location of all nearby ruins that are visible to the robot.
- sensePassability(MapLocation) - Method in interface battlecode.common.RobotController
-
Given a senseable location, returns whether that location is passable (a wall).
- senseRobot(int) - Method in interface battlecode.common.RobotController
-
Senses information about a particular robot given its ID.
- senseRobotAtLocation(MapLocation) - Method in interface battlecode.common.RobotController
-
Senses the robot at the given location, or null if there is no robot there.
- setIndicatorDot(MapLocation, int, int, int) - Method in interface battlecode.common.RobotController
-
Draw a dot on the game map for debugging purposes.
- setIndicatorLine(MapLocation, MapLocation, int, int, int) - Method in interface battlecode.common.RobotController
-
Draw a line on the game map for debugging purposes.
- setIndicatorString(String) - Method in interface battlecode.common.RobotController
-
Sets the indicator string for this robot for debugging purposes.
- setTimelineMarker(String, int, int, int) - Method in interface battlecode.common.RobotController
-
Adds a marker to the timeline at the current round for debugging purposes.
- SOLDIER - Enum constant in enum class battlecode.common.UnitType
- SOUTH - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing south (down on screen).
- SOUTHEAST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing southeast (down and to the right on screen).
- SOUTHWEST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing southwest (down and to the left on screen).
- SPEC_VERSION - Static variable in class battlecode.common.GameConstants
-
The current spec version the server compiles with.
- SPLASHER - Enum constant in enum class battlecode.common.UnitType
- SPLASHER_ATTACK_AOE_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The area effected by the splasher's attack.
- SPLASHER_ATTACK_ENEMY_PAINT_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The smaller area within the splasher's attack at which enemy paint is also replaced by allied paint
- subtract(Direction) - Method in class battlecode.common.MapLocation
-
Returns a new MapLocation object representing a location one unit in distance from this one in the opposite direction of the given direction.
T
- team - Variable in class battlecode.common.RobotInfo
-
The Team that the robot is on.
- Team - Enum Class in battlecode.common
-
This enum represents the team of a robot.
- TIMELINE_LABEL_MAX_LENGTH - Static variable in class battlecode.common.GameConstants
-
The maximum length of a label to add to the timeline.
- toString() - Method in class battlecode.common.MapInfo
- toString() - Method in class battlecode.common.MapLocation
- toString() - Method in class battlecode.common.Message
- toString() - Method in class battlecode.common.RobotInfo
- TOWER_BYTECODE_LIMIT - Static variable in class battlecode.common.GameConstants
-
The maximum number of bytecodes a tower is allowed to use in one turn
- transferPaint(MapLocation, int) - Method in interface battlecode.common.RobotController
-
Transfers paint from the robot's stash to the stash of the allied robot or tower at loc.
- translate(int, int) - Method in class battlecode.common.MapLocation
-
Returns a new MapLocation object translated from this location by a fixed amount.
- type - Variable in class battlecode.common.RobotInfo
-
The type of the robot.
U
- UnitType - Enum Class in battlecode.common
- upgradeTower(MapLocation) - Method in interface battlecode.common.RobotController
-
Upgrades a tower if possible; subtracts the corresponding amount of money from the team.
V
- valueOf(String) - Static method in enum class battlecode.common.Direction
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class battlecode.common.GameActionExceptionType
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in class battlecode.common.MapLocation
- valueOf(String) - Static method in enum class battlecode.common.PaintType
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class battlecode.common.Team
-
Returns the enum constant of this class with the specified name.
- valueOf(String) - Static method in enum class battlecode.common.UnitType
-
Returns the enum constant of this class with the specified name.
- values() - Static method in enum class battlecode.common.Direction
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class battlecode.common.GameActionExceptionType
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class battlecode.common.PaintType
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class battlecode.common.Team
-
Returns an array containing the constants of this enum class, in the order they are declared.
- values() - Static method in enum class battlecode.common.UnitType
-
Returns an array containing the constants of this enum class, in the order they are declared.
- VISION_RADIUS_SQUARED - Static variable in class battlecode.common.GameConstants
-
The maximum distance from a robot where information can be sensed
W
- WEST - Enum constant in enum class battlecode.common.Direction
-
Direction that represents pointing west (left on screen).
X
- x - Variable in class battlecode.common.MapLocation
-
The x-coordinate.
Y
- y - Variable in class battlecode.common.MapLocation
-
The y-coordinate.
- yield() - Static method in class battlecode.common.Clock
-
Ends the processing of this robot during the current round.
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form