接口 Arrow

所有超级接口:
CommandSender, Entity, Metadatable, Nameable, Permissible, Projectile, ServerOperator
所有已知子接口:
SpectralArrow, TippedArrow

public interface Arrow extends Projectile
表示一只箭矢.
  • 方法详细资料

    • getKnockbackStrength

      int getKnockbackStrength()
      获取箭头的击退强度,这表示附魔力量等级.

      原文:Gets the knockback strength for an arrow, which is the KnockBack level of the bow that shot it.mine

      返回:
      附魔击退等级
    • setKnockbackStrength

      void setKnockbackStrength(int knockbackStrength)
      设置箭矢的附魔击退等级.

      原文: Sets the knockback strength for an arrow.

      参数:
      knockbackStrength - 附魔击退等级
    • isCritical

      boolean isCritical()
      获取此箭矢是否产生暴击.
      产生暴击的箭矢会产生更多的伤害并伴随粒子效果.
      暴击箭矢通常发生在玩家满弓射箭时.

      原文: Gets whether this arrow is critical.
      Critical arrows have increased damage and cause particle effects.
      Critical arrows generally occur when a player fully draws a bow before firing.

      返回:
      如果是暴击箭矢则返回true
    • setCritical

      void setCritical(boolean critical)
      设置这个箭矢是否是否产生了暴击.

      原文:Sets whether or not this arrow should be critical.

      参数:
      critical - 它是否是否产生了暴击
    • isInBlock

      boolean isInBlock()
      获取此箭矢是否嵌入于一个方块中.

      嵌入于方块中的箭矢是静止的,并且可能被玩家拾取.

      原文:Gets whether this arrow is in a block or not.

      Arrows in a block are motionless and may be picked up by players.

      返回:
      此箭矢是否嵌入于方块中
    • getAttachedBlock

      Block getAttachedBlock()
      获取该箭矢附着在哪个方块上.

      原文:Gets the block to which this arrow is attached.

      返回:
      箭矢附着(嵌入)的方块,若箭矢没有嵌入于方块中返回null
    • getPickupStatus

      Arrow.PickupStatus getPickupStatus()
      获取此箭矢的当前拾取状态.

      原文:Gets the current pickup status of this arrow.

      返回:
      此箭矢的拾取状态
    • setPickupStatus

      void setPickupStatus(Arrow.PickupStatus status)
      设置此箭矢的当前拾取状态.

      原文:Sets the current pickup status of this arrow.

      参数:
      status - 此箭矢新的拾取状态