    001    package net.minecraft.src;
    002
    003    import net.minecraft.server.MinecraftServer;
    004
    005    public class CommandServerSaveOn extends CommandBase
    006    {
    007        public String getCommandName()
    008        {
    009            return "save-on";
    010        }
    011
    012        /**
    013         * Return the required permission level for this command.
    014         */
    015        public int getRequiredPermissionLevel()
    016        {
    017            return 4;
    018        }
    019
    020        public void processCommand(ICommandSender par1ICommandSender, String[] par2ArrayOfStr)
    021        {
    022            MinecraftServer var3 = MinecraftServer.getServer();
    023
    024            for (int var4 = 0; var4 < var3.worldServers.length; ++var4)
    025            {
    026                if (var3.worldServers[var4] != null)
    027                {
    028                    WorldServer var5 = var3.worldServers[var4];
    029                    var5.canNotSave = false;
    030                }
    031            }
    032
    033            notifyAdmins(par1ICommandSender, "commands.save.enabled", new Object[0]);
    034        }
    035    }