Class RepeatingEntityTask<T extends org.bukkit.entity.Entity>

java.lang.Object
org.bukkit.scheduler.BukkitRunnable
studio.magemonkey.fabled.task.RepeatingEntityTask<T>
All Implemented Interfaces:
Runnable

public class RepeatingEntityTask<T extends org.bukkit.entity.Entity> extends org.bukkit.scheduler.BukkitRunnable
A simple task for performing an action on a list of entities every tick
  • Constructor Summary

    Constructors
    Constructor
    Description
    RepeatingEntityTask(List<T> entities, EntityTask<T> entityTask)
    Initializes a new task to perform a given action on an entity every tick
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    run()
    Applies the entity task

    Methods inherited from class org.bukkit.scheduler.BukkitRunnable

    cancel, getTaskId, isCancelled, runTask, runTaskAsynchronously, runTaskLater, runTaskLaterAsynchronously, runTaskTimer, runTaskTimerAsynchronously

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • RepeatingEntityTask

      public RepeatingEntityTask(List<T> entities, EntityTask<T> entityTask)
      Initializes a new task to perform a given action on an entity every tick
      Parameters:
      entities - entities to affect
      entityTask - the task to apply on all remaining projectiles
  • Method Details

    • run

      public void run()
      Applies the entity task