Noobs introduction to the scheduler

Discussion in 'Plugin Development' started by tips48, Apr 20, 2013.

Thread Status:
Not open for further replies.
  1. So, I was hanging out at stackoverflow because that's what all the kool kats do, and some poor misguided fellow asked about Bukkit. After directing him here, I proceeded to answer his question, and basically gave a good overview of the scheduler. If your struggling to understand how it works, try giving it a read as I thought it was a pretty good introduction.

    P.S.: No idea what this runTaskTimer and runTaskLater new-fangled stuff is, so somebody smart may want to check my answer.

    http://stackoverflow.com/questions/16126978/bukkit-how-to-make-a-function-be-called-every-2-ticks/
     
  2. You're not really asking for help so this should be in the Resources section :}

    Also BukkitRunnable class is alot easier to use when dealing with canceling from within it.
    Code:
    new BukkitRunnable()
    {
        public void run()
        {
            cancel();
        }
    }.runTaskTimer(plugin, 0, 2);
    For getScheduler() the run*() methods are just replacements for schedule*() methods and the async one were deprecated because some people thought it said "a sync" instead of "an async".
     
  3. Ahh, thanks. I won't edit my answer because it's not really relevant but now atleast I know what it is.
     
Thread Status:
Not open for further replies.

Share This Page