Class CooldownHandler
java.lang.Object
com.hypixel.hytale.server.core.modules.interaction.interaction.CooldownHandler
- All Implemented Interfaces:
Tickable
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetCooldown(String id) getCooldown(String id, float maxTime, float[] chargeTimes, boolean force, boolean interruptRecharge) booleanisOnCooldown(RootInteraction root, String id, float maxTime, float[] chargeTimes, boolean interruptRecharge) voidresetCooldown(String id, float maxTime, float[] chargeTimes, boolean interruptRecharge) voidtick(float dt)
-
Field Details
-
cooldowns
-
-
Constructor Details
-
CooldownHandler
public CooldownHandler()
-
-
Method Details
-
isOnCooldown
public boolean isOnCooldown(@Nonnull RootInteraction root, @Nonnull String id, float maxTime, @Nonnull float[] chargeTimes, boolean interruptRecharge) -
resetCooldown
public void resetCooldown(@Nonnull String id, float maxTime, @Nonnull float[] chargeTimes, boolean interruptRecharge) -
getCooldown
@Nullable public CooldownHandler.Cooldown getCooldown(@Nonnull String id, float maxTime, @Nonnull float[] chargeTimes, boolean force, boolean interruptRecharge) -
getCooldown
-
tick
public void tick(float dt)
-