I was making a plugin in Java, Bukkit, but, I can not seem to make this work: Code: public void test() { Bukkit.getScheduler().scheduleSyncRepeatingTask(plugin, new Runnable() { @Override public void run() { try { if (!started && playersJoined >= 1 && startingIn > 0 && startedTimer) { System.out.println(startingIn); startingIn--; } else if (!started && playersJoined >= 1 && startingIn == 0 && startedTimer) { System.out.println("EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE"); started = true; Bukkit.getScheduler().scheduleSyncRepeatingTask(plugin, new Runnable() { @Override public void run() { int y = 1; for (int x = 1; x > 369; x++) { for (int z = 1; z > 369; z++) { Location location = new Location(gettWorld(), x, y, z);// me spammed willy now gib reward location.getBlock().setType(Material.REDSTONE_BLOCK); } } } }, 0, 200L); } } catch (Exception ex) { System.out.println("The error is" + ex);// } } }, 0, 20); } . What I want to do is spawn those blocks on the coordinates.
So I have a timer in the code in another thread and when the timer reaches 0, this code is supposed to spawn Red stone block in the x,y and z cordinates but it's not spawning the blocks when the timer reaches 0