Package megamek.common.enums
Enum Class FacingArc
- All Implemented Interfaces:
Serializable
,Comparable<FacingArc>
,Constable
All the different possible facing arcs
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Method Summary
Modifier and TypeMethodDescriptionint
int
int
boolean
isInsideArc
(int angle) boolean
isInsideArc
(Coords source, int facing, Targetable target) boolean
isInsideArc
(UnitPosition source, UnitPosition target) static FacingArc
valueOf
(int arcCode) Returns the enum constant of this type with the legacy specified arcCode.static FacingArc
Returns the enum constant of this class with the specified name.static FacingArc[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ARC_360
-
ARC_FORWARD
-
ARC_LEFTARM
-
ARC_RIGHTARM
-
ARC_REAR
-
ARC_LEFTSIDE
-
ARC_RIGHTSIDE
-
ARC_MAINGUN
-
ARC_NORTH
-
ARC_EAST
-
ARC_WEST
-
ARC_NOSE
-
ARC_LWING
-
ARC_RWING
-
ARC_LWINGA
-
ARC_RWINGA
-
ARC_LEFTSIDE_SPHERE
-
ARC_RIGHTSIDE_SPHERE
-
ARC_LEFTSIDEA_SPHERE
-
ARC_RIGHTSIDEA_SPHERE
-
ARC_LEFT_BROADSIDE
-
ARC_RIGHT_BROADSIDE
-
ARC_AFT
-
ARC_LEFT_SPHERE_GROUND
-
ARC_RIGHT_SPHERE_GROUND
-
ARC_TURRET
-
ARC_SPONSON_TURRET_LEFT
-
ARC_SPONSON_TURRET_RIGHT
-
ARC_PINTLE_TURRET_LEFT
-
ARC_PINTLE_TURRET_RIGHT
-
ARC_PINTLE_TURRET_FRONT
-
ARC_PINTLE_TURRET_REAR
-
ARC_VGL_FRONT
-
ARC_VGL_RF
-
ARC_VGL_RR
-
ARC_VGL_REAR
-
ARC_VGL_LR
-
ARC_VGL_LF
-
ARC_NOSE_WPL
-
ARC_LWING_WPL
-
ARC_RWING_WPL
-
ARC_LWINGA_WPL
-
ARC_RWINGA_WPL
-
ARC_LEFTSIDE_SPHERE_WPL
-
ARC_RIGHTSIDE_SPHERE_WPL
-
ARC_LEFTSIDEA_SPHERE_WPL
-
ARC_RIGHTSIDEA_SPHERE_WPL
-
ARC_AFT_WPL
-
ARC_LEFT_BROADSIDE_WPL
-
ARC_RIGHT_BROADSIDE_WPL
-
-
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
-
getArcCode
public int getArcCode() -
getStartAngle
public int getStartAngle() -
getEndAngle
public int getEndAngle() -
isInsideArc
public boolean isInsideArc(int angle) -
isInsideArc
-
isInsideArc
-
valueOf
Returns the enum constant of this type with the legacy specified arcCode. The arcCode must match exactly an arcCode used to declare an enum constant in this type.- Returns:
- the enum constant with the specified legacy arcCode
- Throws:
IllegalArgumentException
- – if this enum type has no constant with the specified arcCode
-