actually disable default weather cycle (oops)

This commit is contained in:
Jack
2022-10-28 15:20:00 -04:00
committed by GitHub
parent f307c35ad7
commit 123ed65d36

View File

@@ -153,7 +153,11 @@ public final class RealTimeWeather extends JavaPlugin implements Listener {
weatherEnabled = false;
return;
}
for (World world : getServer().getWorlds())
if (world.getEnvironment().equals(World.Environment.NORMAL))
world.setGameRule(GameRule.DO_WEATHER_CYCLE, false);
getServer().getScheduler().scheduleSyncRepeatingTask(this, () -> {
debug("Syncing weather...");