public class Hopper extends MaterialData implements Directional, Redstone
Material.HOPPER| 限定符和类型 | 字段和说明 |
|---|---|
protected static boolean |
DEFAULT_ACTIVE |
protected static BlockFace |
DEFAULT_DIRECTION |
| 构造器和说明 |
|---|
Hopper()
构造一个默认朝向(下)、激活的漏斗.
|
Hopper(BlockFace facingDirection)
构造一个指定朝向、激活的漏斗.
|
Hopper(BlockFace facingDirection,
boolean isActive)
构造一个指定朝向、指定激活状态的漏斗.
|
Hopper(int type)
已过时。
不安全的参数
|
Hopper(int type,
byte data)
已过时。
不安全的参数
|
Hopper(Material type) |
Hopper(Material type,
byte data)
已过时。
不安全的参数
|
| 限定符和类型 | 方法和说明 |
|---|---|
Hopper |
clone() |
BlockFace |
getFacing()
获取这个漏斗的朝向.
|
boolean |
isActive()
检测这个漏斗是否被激活.
|
boolean |
isPowered()
检测这个漏斗是否充能.
|
void |
setActive(boolean isActive)
设置这个漏斗是否被激活.
|
void |
setFacingDirection(BlockFace face)
设置这个漏斗的朝向.
|
java.lang.String |
toString() |
equals, getData, getItemType, getItemTypeId, hashCode, setData, toItemStack, toItemStackprotected static final BlockFace DEFAULT_DIRECTION
protected static final boolean DEFAULT_ACTIVE
public Hopper()
原文:Constructs a hopper facing the default direction (down) and initially active.
public Hopper(BlockFace facingDirection)
原文:Constructs a hopper facing the specified direction and initially active.
facingDirection - 朝向BlockFacepublic Hopper(BlockFace facingDirection, boolean isActive)
原文:Constructs a hopper facing the specified direction and either active or not.
facingDirection - 朝向isActive - 这个漏斗是否被激活BlockFace@Deprecated public Hopper(int type)
type - the raw type idpublic Hopper(Material type)
@Deprecated
public Hopper(int type,
byte data)
type - the raw type iddata - the raw data value@Deprecated public Hopper(Material type, byte data)
type - the typedata - the raw data valuepublic void setActive(boolean isActive)
原文:Sets whether the hopper is active or not.
isActive - 这个漏斗是否被激活public boolean isActive()
原文:Checks whether the hopper is active or not.
public void setFacingDirection(BlockFace face)
原文:Sets the direction this hopper is facing
setFacingDirection 在接口中 Directionalface - 朝向BlockFacepublic BlockFace getFacing()
原文:Gets the direction this hopper is facing
getFacing 在接口中 DirectionalBlockFacepublic java.lang.String toString()
toString 在类中 MaterialDatapublic Hopper clone()
clone 在类中 MaterialData