Package battlecode.common
Enum Class GameActionExceptionType
- All Implemented Interfaces:
Serializable,Comparable<GameActionExceptionType>,Constable
Enumerates the possible errors in GameWorld interactions that cause a GameActionException to be thrown.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionIndicates when a robot tries to perform an action it can't.Indicates when a robot tries to move into a non-empty location.Indicates when a robot tries to sense a robot that no longer exists or is no longer in this robot's vision range.Internal error in the GameWorld engine.Indicates when a robot tries to execute an action, but is not currently idle.Indicates when a robot tries to perform an action on another robot, but there is no suitable robot there.Indicates when a robot tries to perform an action for which it does not have enough resources.Indicates when a robot tries to perform an action on a location that is outside its range.Indicates when round number is out of range. -
Method Summary
Modifier and TypeMethodDescriptionstatic GameActionExceptionTypeReturns the enum constant of this class with the specified name.static GameActionExceptionType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INTERNAL_ERROR
Internal error in the GameWorld engine. This is bad. -
NOT_ENOUGH_RESOURCE
Indicates when a robot tries to perform an action for which it does not have enough resources. -
CANT_MOVE_THERE
Indicates when a robot tries to move into a non-empty location. -
IS_NOT_READY
Indicates when a robot tries to execute an action, but is not currently idle. -
CANT_SENSE_THAT
Indicates when a robot tries to sense a robot that no longer exists or is no longer in this robot's vision range. -
OUT_OF_RANGE
Indicates when a robot tries to perform an action on a location that is outside its range. -
CANT_DO_THAT
Indicates when a robot tries to perform an action it can't. -
NO_ROBOT_THERE
Indicates when a robot tries to perform an action on another robot, but there is no suitable robot there. -
ROUND_OUT_OF_RANGE
Indicates when round number is out of range.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-