接口 UseCooldownComponent

所有超级接口:
ConfigurationSerializable

@Experimental public interface UseCooldownComponent extends ConfigurationSerializable
Represents a component which determines the cooldown applied to use of this item.
  • 方法详细资料

    • getCooldownSeconds

      float getCooldownSeconds()
      Gets the time in seconds it will take for an item in this cooldown group to be available to use again.
      返回:
      cooldown time
    • setCooldownSeconds

      void setCooldownSeconds(float cooldown)
      Sets the time in seconds it will take for an item in this cooldown group to be available to use again.
      参数:
      cooldown - new eat time, must be greater than 0
    • getCooldownGroup

      @Nullable @Nullable NamespacedKey getCooldownGroup()
      Gets the custom cooldown group to be used for similar items, if set.
      返回:
      the cooldown group
    • setCooldownGroup

      void setCooldownGroup(@Nullable @Nullable NamespacedKey song)
      Sets the custom cooldown group to be used for similar items.
      参数:
      song - the cooldown group