Class ConfigureRgbTileAction
- java.lang.Object
-
- page.codeberg.terratactician_expandoria.bots.actions.Action
-
- page.codeberg.terratactician_expandoria.bots.actions.ConfigureRgbTileAction
-
public class ConfigureRgbTileAction extends Action
ConfigureRgb is an Action to change the color of a placed rgb tile. Will only work in creative mode.
-
-
Field Summary
Fields Modifier and Type Field Description intbcolor blue value: in [0, 255]CubeCoordinatecoordCoordinate of tile to be configured.intgcolor green value: in [0, 255]intrcolor red value: in [0, 255]
-
Constructor Summary
Constructors Constructor Description ConfigureRgbTileAction(CubeCoordinate coord, int red, int green, int blue)Generates an action that reconfigures an rgb tile.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetName()Name of the action in the json package.booleanisLimited()Returns true if the action is limited in challenge mode, by the action cap.java.lang.ObjectserializeData()Serializes the data of the Action.
-
-
-
Field Detail
-
coord
public CubeCoordinate coord
Coordinate of tile to be configured.
-
r
public int r
color red value: in [0, 255]
-
g
public int g
color green value: in [0, 255]
-
b
public int b
color blue value: in [0, 255]
-
-
Constructor Detail
-
ConfigureRgbTileAction
public ConfigureRgbTileAction(CubeCoordinate coord, int red, int green, int blue) throws java.lang.IllegalArgumentException
Generates an action that reconfigures an rgb tile. The Arguments describe the color values of the red, green and blue channels (values between 0 and 255)- Parameters:
coord- Coordinate of the targeted Rgb Tilered- Red color channel (0-255)blue- Blue color channel (0-255)green- Green color channel (0-255)- Throws:
java.lang.IllegalArgumentException- will be thrown the limits from the other args are exceeded.
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from class:ActionName of the action in the json package.
-
serializeData
public java.lang.Object serializeData()
Description copied from class:ActionSerializes the data of the Action. This may returns a JSONObject or String or an other supported datatype.- Specified by:
serializeDatain classAction- Returns:
- JSONObject or String
-
-