Prevented Crash when the manual was open during a world crash or kick

This commit is contained in:
Ellpeck 2015-10-31 21:42:16 +01:00
parent 5e5173cf54
commit b24cd48984

View file

@ -54,7 +54,10 @@ public class PersistentClientData{
}
private static String getName(){
return Minecraft.getMinecraft().isIntegratedServerRunning() ? Minecraft.getMinecraft().getIntegratedServer().getFolderName() : Minecraft.getMinecraft().func_147104_D().serverIP;
if(Minecraft.getMinecraft().theWorld != null){
return Minecraft.getMinecraft().isIntegratedServerRunning() ? Minecraft.getMinecraft().getIntegratedServer().getFolderName() : Minecraft.getMinecraft().func_147104_D().serverIP;
}
return "Invalid";
}
private static NBTTagCompound getCompoundForWorld(NBTTagCompound mainCompound){