mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-07-18 18:23:06 +00:00
Fixes
This commit is contained in:
parent
a27bb66fef
commit
ccd59278e5
@ -4,6 +4,7 @@
|
||||
-libraryjars 'C:\Program Files\Java\jre1.8.0_221\lib\rt.jar'
|
||||
-libraryjars lib
|
||||
|
||||
-dontwarn org.slf4j.**
|
||||
-dontskipnonpubliclibraryclassmembers
|
||||
-dontshrink
|
||||
-optimizations !code/simplification/advanced,code/simplification/*
|
||||
|
5
pom.xml
5
pom.xml
@ -43,11 +43,6 @@
|
||||
</goals>
|
||||
<configuration>
|
||||
<minimizeJar>false</minimizeJar>
|
||||
<artifactSet>
|
||||
<excludes>
|
||||
<exclude>org.slf4j:*</exclude>
|
||||
</excludes>
|
||||
</artifactSet>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
|
@ -132,6 +132,8 @@ public class Iris extends MortarPlugin
|
||||
}
|
||||
|
||||
public void onDisable()
|
||||
{
|
||||
if(IrisSettings.get().isStudio())
|
||||
{
|
||||
proj.close();
|
||||
|
||||
@ -142,10 +144,12 @@ public class Iris extends MortarPlugin
|
||||
((IrisChunkGenerator) i.getGenerator()).close();
|
||||
}
|
||||
}
|
||||
|
||||
for(GroupedExecutor i : executors)
|
||||
{
|
||||
i.close();
|
||||
}
|
||||
}
|
||||
|
||||
executors.clear();
|
||||
board.disable();
|
||||
|
@ -1,13 +1,14 @@
|
||||
package com.volmit.iris.command;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.WorldCreator;
|
||||
import org.bukkit.WorldType;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.zeroturnaround.zip.ZipUtil;
|
||||
import org.zeroturnaround.zip.commons.FileUtils;
|
||||
|
||||
import com.volmit.iris.Iris;
|
||||
import com.volmit.iris.IrisDataManager;
|
||||
@ -15,6 +16,7 @@ import com.volmit.iris.IrisSettings;
|
||||
import com.volmit.iris.gen.IrisChunkGenerator;
|
||||
import com.volmit.iris.object.IrisDimension;
|
||||
import com.volmit.iris.util.Form;
|
||||
import com.volmit.iris.util.IO;
|
||||
import com.volmit.iris.util.J;
|
||||
import com.volmit.iris.util.MortarCommand;
|
||||
import com.volmit.iris.util.MortarSender;
|
||||
@ -86,7 +88,38 @@ public class CommandIrisCreate extends MortarCommand
|
||||
Iris.globaldata.dump();
|
||||
Iris.globaldata.preferFolder(null);
|
||||
Iris.proj.downloadSearch(sender, type, false);
|
||||
ZipUtil.unpack(Iris.proj.compilePackage(sender, type, true, true), iris);
|
||||
File downloaded = Iris.instance.getDataFolder("packs", type);
|
||||
|
||||
for(File i : downloaded.listFiles())
|
||||
{
|
||||
if(i.isFile())
|
||||
{
|
||||
try
|
||||
{
|
||||
FileUtils.copyFile(i, new File(iris, i.getName()));
|
||||
}
|
||||
|
||||
catch(IOException e)
|
||||
{
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
try
|
||||
{
|
||||
FileUtils.copyDirectory(i, new File(iris, i.getName()));
|
||||
}
|
||||
|
||||
catch(IOException e)
|
||||
{
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
IO.delete(downloaded);
|
||||
}
|
||||
|
||||
if(!dimf.exists() || !dimf.isFile())
|
||||
@ -169,28 +202,12 @@ public class CommandIrisCreate extends MortarCommand
|
||||
{
|
||||
world.save();
|
||||
|
||||
for(Player i : world.getPlayers())
|
||||
{
|
||||
i.kickPlayer("Please Rejoin in a different world.");
|
||||
}
|
||||
|
||||
if(!Bukkit.unloadWorld(world, true))
|
||||
{
|
||||
sender.sendMessage("Couldn't unload the world for some reason.... Aborting zip.");
|
||||
return;
|
||||
}
|
||||
|
||||
if(Iris.linkMultiverseCore.supported())
|
||||
{
|
||||
Iris.linkMultiverseCore.addWorld(worldName, dimm, seedd + "");
|
||||
sender.sendMessage("Added " + worldName + " to MultiverseCore.");
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
sender.sendMessage("No MVC?");
|
||||
}
|
||||
|
||||
sender.sendMessage("All Done!");
|
||||
});
|
||||
});
|
||||
|
@ -21,6 +21,12 @@ public class CommandIrisPregen extends MortarCommand
|
||||
@Override
|
||||
public boolean handle(MortarSender sender, String[] args)
|
||||
{
|
||||
if(args.length == 0)
|
||||
{
|
||||
sender.sendMessage("/iris pregen <blocks-wide|stop>");
|
||||
return true;
|
||||
}
|
||||
|
||||
if(args[0].equalsIgnoreCase("stop"))
|
||||
{
|
||||
if(PregenJob.task == -1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user