fix: apply gamerules in every world
This commit is contained in:
parent
bc6074436c
commit
cea3366164
1 changed files with 4 additions and 7 deletions
|
@ -8,7 +8,6 @@ import org.bukkit.Difficulty;
|
|||
import org.bukkit.GameRule;
|
||||
import org.bukkit.NamespacedKey;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.World.Environment;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
import org.bukkit.configuration.file.YamlConfiguration;
|
||||
|
@ -67,13 +66,11 @@ public class Varo extends JavaPlugin {
|
|||
getCommand("varo").setExecutor(new VaroCommand(this));
|
||||
|
||||
for (World world : getServer().getWorlds()) {
|
||||
if (world.getEnvironment() == Environment.NORMAL) {
|
||||
// world.setDifficulty(Difficulty.HARD);
|
||||
world.setDifficulty(Difficulty.PEACEFUL); // TODO: REMOVE AFTER DEBUG!!
|
||||
world.setGameRule(GameRule.ANNOUNCE_ADVANCEMENTS, false);
|
||||
world.setGameRule(GameRule.REDUCED_DEBUG_INFO, true);
|
||||
}
|
||||
}
|
||||
getServer().removeRecipe(NamespacedKey.minecraft("fishing_rod"));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue