接口 UseEffectsComponent
- 所有超级接口:
ConfigurationSerializable
表示一个决定使用此物品时属性的组件。
-
方法概要
修饰符和类型方法说明boolean获取玩家在使用此物品时是否可以冲刺。float获取使用此物品时应用于玩家的速度倍率。boolean获取使用此物品是否会触发振动。voidsetCanSprint(boolean sprint) 设置玩家在使用此物品时是否可以冲刺。voidsetInteractVibrations(boolean interactVibrations) 设置使用此物品是否会触发振动。voidsetSpeedMultiplier(float multiplier) 设置使用此物品时应用于玩家的速度倍率。从接口继承的方法 org.bukkit.configuration.serialization.ConfigurationSerializable
serialize
-
方法详细资料
-
canSprint
boolean canSprint()获取玩家在使用此物品时是否可以冲刺。原文:Gets whether the player can sprint while using this item.
- 返回:
- 玩家是否可以冲刺
-
setCanSprint
void setCanSprint(boolean sprint) 设置玩家在使用此物品时是否可以冲刺。原文:Sets whether the player can sprint while using this item.
- 参数:
sprint- 玩家是否可以冲刺
-
isInteractVibrations
boolean isInteractVibrations()获取使用此物品是否会触发振动。原文:Gets whether using this item will trigger vibrations.
- 返回:
- 使用是否会触发振动
-
setInteractVibrations
void setInteractVibrations(boolean interactVibrations) 设置使用此物品是否会触发振动。原文:Sets whether using this item will trigger vibrations.
- 参数:
interactVibrations- 使用是否会触发振动
-
getSpeedMultiplier
float getSpeedMultiplier()获取使用此物品时应用于玩家的速度倍率。原文:Gets the speed multiplier applied to the player while using this item.
- 返回:
- 速度倍率
-
setSpeedMultiplier
void setSpeedMultiplier(float multiplier) 设置使用此物品时应用于玩家的速度倍率。原文:Sets the speed multiplier applied to the player while using this item.
- 参数:
multiplier- 新的倍率
-