类 TrapDoor

所有已实现的接口:
Cloneable, Attachable, Directional, Openable

public class TrapDoor extends SimpleAttachableMaterialData implements Openable
代表活板门
  • 构造器详细资料

    • TrapDoor

      public TrapDoor()
    • TrapDoor

      @Deprecated public TrapDoor(int type)
      已过时。
      不安全的参数
      参数:
      type - the raw type id
    • TrapDoor

      public TrapDoor(Material type)
    • TrapDoor

      @Deprecated public TrapDoor(int type, byte data)
      已过时。
      不安全的参数
      参数:
      type - the raw type id
      data - the raw data value
    • TrapDoor

      @Deprecated public TrapDoor(Material type, byte data)
      已过时。
      不安全的参数
      参数:
      type - the type
      data - the raw data value
  • 方法详细资料

    • isOpen

      public boolean isOpen()
      从接口复制的说明: Openable
      检测这个门是否开着.

      原文:Check to see if the door is open.

      指定者:
      isOpen 在接口中 Openable
      返回:
      门是否开着
    • setOpen

      public void setOpen(boolean isOpen)
      从接口复制的说明: Openable
      设置这个门是否开着.

      原文:Configure this door to be either open or closed;

      指定者:
      setOpen 在接口中 Openable
      参数:
      isOpen - 门是否开着
    • isInverted

      public boolean isInverted()
      这个活板门是否被反转.

      原文:Test if trapdoor is inverted

      返回:
      true为反转的(上半), false为正常形态(下半)
    • setInverted

      public void setInverted(boolean inv)
      设置这个台阶是否被反转。

      原文:Set trapdoor inverted state

      参数:
      inv - true为反转的(上半), false为正常形态(下半)
    • getAttachedFace

      public BlockFace getAttachedFace()
      从接口复制的说明: Attachable
      获取这个方块附着的朝向.

      原文: Gets the face that this block is attached on

      指定者:
      getAttachedFace 在接口中 Attachable
      返回:
      朝向
    • setFacingDirection

      public void setFacingDirection(BlockFace face)
      从接口复制的说明: Directional
      设置这个方块的朝向.

      原文:Sets the direction that this block is facing in

      指定者:
      setFacingDirection 在接口中 Directional
      参数:
      face - 这个方块的朝向
    • toString

      public String toString()
      覆盖:
      toString 在类中 SimpleAttachableMaterialData
    • clone

      public TrapDoor clone()
      覆盖:
      clone 在类中 SimpleAttachableMaterialData