Advertisement
Guest User

Untitled

a guest
Jun 21st, 2013
537
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.52 KB | None | 0 0
  1. private void lobbyTime()
  2.     {
  3.         Bukkit.getScheduler().scheduleSyncRepeatingTask(this, new Runnable()
  4.         {
  5.             @Override
  6.             public void run()
  7.             {
  8.                 Date today1 = Calendar.getInstance().getTime();
  9.                 DateFormat tm = new SimpleDateFormat("HH:mm");
  10.                 String time = tm.format(today1);
  11.                
  12.                 if(time.equalsIgnoreCase("00:00"))
  13.                 {
  14.                     Bukkit.getWorld("world").setTime(18000);
  15.                 }
  16.                 else if(time.equalsIgnoreCase("00:15"))
  17.                 {
  18.                     Bukkit.getWorld("world").setTime(18250);
  19.                 }
  20.             }
  21.         }, 20L, 20L);
  22.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement