接口 Hanging

所有超级接口:
Attachable, CommandSender, Directional, Entity, Metadatable, Nameable, Permissible, PersistentDataHolder, ServerOperator
所有已知子接口:
GlowItemFrame, ItemFrame, LeashHitch, Painting

public interface Hanging extends Entity, Attachable
代表悬挂实体.
  • 方法详细资料

    • setFacingDirection

      boolean setFacingDirection(@NotNull @NotNull BlockFace face, boolean force)
      设置悬挂实体的方向,这可能会重写所有规则. 注意:如果结果无效,实体可能会掉落为物品.

      原文:Sets the direction of the hanging entity, potentially overriding rules of placement. Note that if the result is not valid the object would normally drop as an item.

      参数:
      face - 新的方向
      force - 是否强制
      返回:
      如果强制执行失败或者那里没有方块附着给定的方向则为false