Advertisement
kman2010

Untitled

May 18th, 2011
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package me.GoldEnchantTeam.GoldEnchant;
  2.  
  3. import org.bukkit.Bukkit;
  4. import org.bukkit.plugin.Plugin;
  5.  
  6. public class GoldEnchantTimer implements Runnable {
  7.     {
  8.  
  9.         Bukkit.getServer().getScheduler()
  10.                 .scheduleAsyncDelayedTask((Plugin) this, new Runnable() {
  11.  
  12.                     @Override
  13.                     public void run() {
  14.                         Bukkit.getServer().broadcastMessage(
  15.                                 "This message is broadcast by the main thread");
  16.  
  17.                     }
  18.  
  19.                 }, 60L);
  20.     }
  21.  
  22.     @Override
  23.     public void run() {
  24.         Bukkit.getServer().broadcastMessage(
  25.                 "This message is broadcast by the main thread");
  26.  
  27.     }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement