Package mindustry.editor
Enum Class EditorTool
- All Implemented Interfaces:
Serializable
,Comparable<EditorTool>
,Constable
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final EditorTool[]
final String[]
All the internal alternate placement modes of this tool.boolean
Whether this tool should be dragged across the canvas when the mouse moves.boolean
Whether this tool causes canvas changes when touched.Key to activate this tool.int
The current alternate placement mode. -
Method Summary
Modifier and TypeMethodDescriptionvoid
touched
(int x, int y) void
touchedLine
(int x1, int y1, int x2, int y2) static EditorTool
Returns the enum constant of this class with the specified name.static EditorTool[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
zoom
-
pick
-
line
-
pencil
-
eraser
-
fill
-
spray
-
-
Field Details
-
all
-
altModes
All the internal alternate placement modes of this tool. -
key
Key to activate this tool. -
mode
public int modeThe current alternate placement mode. -1 is the standard mode, no changes. -
edit
public boolean editWhether this tool causes canvas changes when touched. -
draggable
public boolean draggableWhether this tool should be dragged across the canvas when the mouse moves.
-
-
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
-
touched
public void touched(int x, int y) -
touchedLine
public void touchedLine(int x1, int y1, int x2, int y2)
-