guys im trying to get this working for a long time im trying to run a scheduleSyncRepeatingTask but randomizing the delay everytime at first i tried running a delayedtask inside a repeating one and didnt worked well "it was getting the delay of repeating task , delay of delayedtask was not doing anything" http://hastebin.com/cozawegoha.coffee than i tried running with bukkitrunnable and delayedtasks / delayed runnable's and couldnt work out so i want to ask how can i make a delayedtask to call itself after an if ? also I would like to learn what does bukkitrunnable exists if we have schedulers ?
Code:java BukkitTask task = new BukkitRunnable() { @Overridepublic void run() { // Your code here.... this.runTaskLater(plugin, 300 + (Math.random() * 200));}}.runTaskLater(plugin, 100); Will first call the runnable after 100 ticks (5 seconds), and it will re-run itself after a random delay, going from 300 ticks (15 seconds) to 500 ticks (25 seconds).