|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<RobotType>
battlecode.common.RobotType
public enum RobotType
Enum Constant Summary | |
---|---|
ARCHON
|
|
DISRUPTER
|
|
SCORCHER
|
|
SCOUT
|
|
SOLDIER
|
|
TOWER
|
Field Summary | |
---|---|
double |
attackAngle
The range of angles that this robot can attack. |
double |
attackCosHalfTheta
|
int |
attackDelay
The number of turns that it takes this robot to attack. |
double |
attackPower
The amount of damage that this robot does when it attacks. |
int |
attackRadiusMaxSquared
The square of the maximum distance that the robot can attack. |
int |
attackRadiusMinSquared
The square of the minimum distance that the robot can attack. |
boolean |
canAttackAir
Whether or not the robot can attack air units. |
boolean |
canAttackGround
Whether or not the robot can attack ground units. |
RobotLevel |
level
The robot's level. |
double |
maxEnergon
The maximum amount of energon the robot can have. |
double |
maxFlux
The maximum amount of flux the robot can have. |
double |
moveCost
The cost in flux to move the robot one square. |
int |
moveDelayDiagonal
The number of turns it takes the robot to move diagonally. |
int |
moveDelayOrthogonal
The number of turns it takes the robot to move orthogonally. |
double |
sensorAngle
The range of angles that the robot can sense. |
double |
sensorCosHalfTheta
|
int |
sensorRadiusSquared
The square of the maximum distance that the robot can sense. |
double |
spawnCost
The amount of flux needed to spawn the robot. |
Method Summary | |
---|---|
boolean |
canAttack(RobotLevel level)
Returns true if the robot can attack robots at the given level. |
boolean |
isAirborne()
Returns true if this robot's level is
RobotLevel.IN_AIR . |
static RobotType |
valueOf(String name)
Returns the enum constant of this type with the specified name. |
static RobotType[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final RobotType ARCHON
public static final RobotType SOLDIER
public static final RobotType SCOUT
public static final RobotType DISRUPTER
public static final RobotType SCORCHER
public static final RobotType TOWER
Field Detail |
---|
public final RobotLevel level
public final double maxEnergon
public final double maxFlux
public final double spawnCost
public final int moveDelayOrthogonal
public final int moveDelayDiagonal
(int)Math.round(moveDelayOrthogonal*Math.sqrt(2.))
.
public final double moveCost
public final int sensorRadiusSquared
public final double sensorAngle
public final int attackRadiusMaxSquared
public final int attackRadiusMinSquared
public final double attackAngle
public final int attackDelay
public final double attackPower
public final boolean canAttackAir
public final boolean canAttackGround
public final double sensorCosHalfTheta
public final double attackCosHalfTheta
Method Detail |
---|
public static RobotType[] values()
for (RobotType c : RobotType.values()) System.out.println(c);
public static RobotType valueOf(String name)
name
- the name of the enum constant to be returned.
IllegalArgumentException
- if this enum type has no constant
with the specified name
NullPointerException
- if the argument is nullpublic boolean canAttack(RobotLevel level)
public boolean isAirborne()
true
if this robot's level is
RobotLevel.IN_AIR
.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |