Interface BukkitModelScheduler
- All Superinterfaces:
kr.toxicity.model.api.scheduler.ModelScheduler
public interface BukkitModelScheduler
extends kr.toxicity.model.api.scheduler.ModelScheduler
Represents a Bukkit-specific scheduler for model tasks.
This interface extends ModelScheduler to provide methods for scheduling tasks
that are synchronized with specific locations (e.g., for Folia compatibility).
- Since:
- 2.0.0
-
Method Summary
Modifier and TypeMethodDescription@Nullable kr.toxicity.model.api.scheduler.ModelTaskSchedules a task to run on the next tick, synchronized with the given location.@Nullable kr.toxicity.model.api.scheduler.ModelTaskSchedules a task to run after a delay, synchronized with the given location.Methods inherited from interface kr.toxicity.model.api.scheduler.ModelScheduler
asyncTask, asyncTaskLater, asyncTaskTimer
-
Method Details
-
task
@Nullable @Nullable kr.toxicity.model.api.scheduler.ModelTask task(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull Runnable runnable) Schedules a task to run on the next tick, synchronized with the given location.- Parameters:
location- the location to synchronize withrunnable- the task to run- Returns:
- the scheduled task, or null if scheduling failed
- Since:
- 2.0.0
-
taskLater
@Nullable @Nullable kr.toxicity.model.api.scheduler.ModelTask taskLater(@NotNull @NotNull org.bukkit.Location location, long delay, @NotNull @NotNull Runnable runnable) Schedules a task to run after a delay, synchronized with the given location.- Parameters:
location- the location to synchronize withdelay- the delay in ticksrunnable- the task to run- Returns:
- the scheduled task, or null if scheduling failed
- Since:
- 2.0.0
-