程序包 org.bukkit.map
类 MapCursor
java.lang.Object
org.bukkit.map.MapCursor
表示一个地图上的光标.
原文: Represents a cursor on a map.
-
嵌套类概要
嵌套类 -
构造器概要
构造器构造器说明MapCursor(byte x, byte y, byte direction, byte type, boolean visible) 已过时。不安全的参数MapCursor(byte x, byte y, byte direction, MapCursor.Type type, boolean visible) 初始化地图光标. -
方法概要
修饰符和类型方法说明byte获取这个光标的朝向.byte已过时。不安全的参数getType()获取这个光标的类型.bytegetX()获取这个光标的X坐标.bytegetY()获取这个光标的Y坐标.boolean获取这个光标的可见情况.voidsetDirection(byte direction) 设置这个光标的方向.voidsetRawType(byte type) 已过时。不安全的参数voidsetType(MapCursor.Type type) 设置这个光标的类型.voidsetVisible(boolean visible) 设置这个光标的可见情况.voidsetX(byte x) 设置这个光标的X坐标.voidsetY(byte y) 设置这个光标的Y坐标.
-
构造器详细资料
-
MapCursor
已过时。不安全的参数初始化地图光标.原文: Initialize the map cursor.
- 参数:
x- x坐标,范围为-128到127y- y坐标,范围为-128到127direction- 光标的朝向,范围为0到15type- 地图光标的类型(颜色、风格)visible- 光标在默认情况下是否可见
-
MapCursor
初始化地图光标.原文: Initialize the map cursor.
- 参数:
x- The x coordinate, from -128 to 127.y- The y coordinate, from -128 to 127.direction- The facing of the cursor, from 0 to 15.type- The type (color/style) of the map cursor.visible- Whether the cursor is visible by default.
-
-
方法详细资料
-
getX
public byte getX()获取这个光标的X坐标.原文: Get the X position of this cursor.
- 返回:
- X坐标
-
getY
public byte getY()获取这个光标的Y坐标.原文: Get the Y position of this cursor.
- 返回:
- Y坐标
-
getDirection
public byte getDirection()获取这个光标的朝向.原文: Get the direction of this cursor.
- 返回:
- 光标的朝向,范围为0到15
-
getType
获取这个光标的类型.原文: Get the type of this cursor.
- 返回:
- 地图光标的类型(颜色、风格)
-
getRawType
已过时。不安全的参数获取这个光标的类型.原文: Get the type of this cursor.
- 返回:
- 地图光标的类型(颜色、风格)
-
isVisible
public boolean isVisible()获取这个光标的可见情况.原文: Get the visibility status of this cursor.
- 返回:
- 可见则返回true,否则返回false
-
setX
public void setX(byte x) 设置这个光标的X坐标.原文: Set the X position of this cursor.
- 参数:
x- X坐标
-
setY
public void setY(byte y) 设置这个光标的Y坐标.原文: Set the Y position of this cursor.
- 参数:
y- Y坐标
-
setDirection
public void setDirection(byte direction) 设置这个光标的方向.原文: Set the direction of this cursor.
- 参数:
direction- 这个光标的朝向,范围为0到15
-
setType
设置这个光标的类型.原文: Set the type of this cursor.
- 参数:
type- 地图光标的类型(颜色、风格)
-
setRawType
已过时。不安全的参数设置这个光标的类型.原文: Set the type of this cursor.
- 参数:
type- 地图光标的类型(颜色、风格)
-
setVisible
public void setVisible(boolean visible) 设置这个光标的可见情况.原文: Set the visibility status of this cursor.
- 参数:
visible- 可见则为true
-