类 Rails
java.lang.Object
org.bukkit.material.MaterialData
org.bukkit.material.Rails
- 所有已实现的接口:
Cloneable
- 直接已知子类:
ExtendedRails
代表Minecraft的铁轨.
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明clone()protected byte已过时。不安全的参数booleanisCurve()booleanvoidsetDirection(BlockFace face, boolean isOnSlope) 设置这个轨道的方向.toString()从类继承的方法 org.bukkit.material.MaterialData
equals, getData, getItemType, getItemTypeId, hashCode, setData, toItemStack, toItemStack
-
构造器详细资料
-
Rails
public Rails() -
Rails
已过时。不安全的参数- 参数:
type- the raw type id
-
Rails
-
Rails
已过时。不安全的参数- 参数:
type- the raw type iddata- the raw data value
-
Rails
已过时。不安全的参数- 参数:
type- the typedata- the raw data value
-
-
方法详细资料
-
isOnSlope
public boolean isOnSlope()- 返回:
- 这个铁轨是否在斜坡上
-
isCurve
public boolean isCurve()- 返回:
- 这个铁轨是否被作为弯道
-
getDirection
- 返回:
- 轨道建立的方向
注意轨道是双向的,并且如果铁轨设置在斜坡上将返回上升方向.如果这个铁轨被作为弯道,则返回拐角方向
-
toString
- 覆盖:
toString在类中MaterialData
-
getConvertedData
已过时。不安全的参数返回没有使用PoweredRail和DetectorRail扩展属性的数据值. 于ExtendedRails重写.原文:Return the data without the extended properties used by
PoweredRailandDetectorRail. Overridden inExtendedRails- 返回:
- 没有扩展属性的数据值
-
setDirection
设置这个轨道的方向.注意轨道是双向的,并且如果铁轨设置在斜坡上将返回上升方向.如果这个铁轨被作为弯道,
原文:Set the direction of these tracks
Note that tracks are bidirectional and that the direction returned is the ascending direction if the track is set on a slope. If it is set as a curve, the corner of the track should be supplied.
- 参数:
face- 轨道的朝向isOnSlope- 轨道应不应该在斜坡上
-
clone
- 覆盖:
clone在类中MaterialData
-