summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorIsaac <minuskube@gmail.com>2017-08-20 00:31:12 +0200
committerIsaac <minuskube@gmail.com>2017-08-20 00:31:12 +0200
commit08224bb7e0765b34125f2028e3bfbd619f6ea480 (patch)
treef8bdf8c5d3da4dc9ad53afcc3fd5f9c3cad07b58 /src
parentb44d1d7b0940236deb5798b0f7a964bd94d089b4 (diff)
downloadbukkit-08224bb7e0765b34125f2028e3bfbd619f6ea480.tar
bukkit-08224bb7e0765b34125f2028e3bfbd619f6ea480.tar.gz
bukkit-08224bb7e0765b34125f2028e3bfbd619f6ea480.tar.lz
bukkit-08224bb7e0765b34125f2028e3bfbd619f6ea480.tar.xz
bukkit-08224bb7e0765b34125f2028e3bfbd619f6ea480.zip
Add non-deprecated constructor for MapCursor
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/bukkit/map/MapCursor.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/main/java/org/bukkit/map/MapCursor.java b/src/main/java/org/bukkit/map/MapCursor.java
index a79dc412..b93886c6 100644
--- a/src/main/java/org/bukkit/map/MapCursor.java
+++ b/src/main/java/org/bukkit/map/MapCursor.java
@@ -28,6 +28,23 @@ public final class MapCursor {
}
/**
+ * Initialize the map cursor.
+ *
+ * @param x The x coordinate, from -128 to 127.
+ * @param y The y coordinate, from -128 to 127.
+ * @param direction The facing of the cursor, from 0 to 15.
+ * @param type The type (color/style) of the map cursor.
+ * @param visible Whether the cursor is visible by default.
+ */
+ public MapCursor(byte x, byte y, byte direction, Type type, boolean visible) {
+ this.x = x;
+ this.y = y;
+ setDirection(direction);
+ setType(type);
+ this.visible = visible;
+ }
+
+ /**
* Get the X position of this cursor.
*
* @return The X coordinate.