Updated FML:
MinecraftForge/FML@2a268cd566 Improve mod list GUI, add sort and search MinecraftForge/FML@951fc2d9fd First attempt at making FMLControlledRegistry something a bit more generic than just blocks/items. MinecraftForge/FML@410582222d Merge pull request #614 from tterrag1098/betterModList MinecraftForge/FML@ba0b176430 Fix ModDiscoverer ignoring inner classes. MinecraftForge/FML@9cc313eab9 Merge pull request #617 from diesieben07/innerclass-disc MinecraftForge/FML@01aaa7dc97 Fix mods defined via --mods or --modListFile launch args not being searched for coremods. #560 MinecraftForge/FML@8cecc47b85 Merge pull request #620 from killjoy1221/extra-coremod-fix MinecraftForge/FML@38d9a5f444 Enhance output of common FML errors in crash reports and server Force load anonymous minecraft classes used in crash reports. This prevents some crashes being hiddedn behind class definiton exceptions.GUI.
This commit is contained in:
parent
8d09b39d80
commit
0f162ddc6a
2 changed files with 115 additions and 3 deletions
2
fml
2
fml
|
@ -1 +1 @@
|
|||
Subproject commit 7f96b2c69ab8a2ed07b5b786b3d679ea4c509121
|
||||
Subproject commit 38d9a5f444815810dec3607f5b3b7ff1ac513d4c
|
|
@ -1,8 +1,14 @@
|
|||
package net.minecraftforge.common;
|
||||
|
||||
import java.util.concurrent.Callable;
|
||||
|
||||
import com.google.common.collect.ObjectArrays;
|
||||
|
||||
import net.minecraftforge.fml.common.FMLCommonHandler;
|
||||
import net.minecraftforge.fml.common.FMLLog;
|
||||
import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.eventhandler.EventBus;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraft.crash.CrashReport;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.common.ForgeHooks.SeedEntry;
|
||||
|
@ -47,7 +53,113 @@ public class MinecraftForge
|
|||
OreDictionary.getOreName(0);
|
||||
|
||||
//Force these classes to be defined, Should prevent derp error hiding.
|
||||
new CrashReport("ThisIsFake", new Exception("Not real"));
|
||||
CrashReport fake = new CrashReport("ThisIsFake", new Exception("Not real"));
|
||||
//Lets init World's crash report inner classes to prevent them from hiding errors.
|
||||
String[] handlers = {
|
||||
"net.minecraft.world.World$1",
|
||||
"net.minecraft.world.World$2",
|
||||
"net.minecraft.world.World$3",
|
||||
"net.minecraft.world.World$4",
|
||||
"net.minecraft.world.chunk.Chunk$1",
|
||||
"net.minecraft.world.chunk.Chunk$2",
|
||||
"net.minecraft.world.chunk.Chunk$3",
|
||||
"net.minecraft.command.server.CommandBlockLogic$1",
|
||||
"net.minecraft.command.server.CommandBlockLogic$2",
|
||||
"net.minecraft.crash.CrashReportCategory$1",
|
||||
"net.minecraft.crash.CrashReportCategory$2",
|
||||
"net.minecraft.crash.CrashReportCategory$3",
|
||||
"net.minecraft.entity.Entity$1",
|
||||
"net.minecraft.entity.Entity$2",
|
||||
"net.minecraft.entity.Entity$3",
|
||||
"net.minecraft.entity.Entity$4",
|
||||
"net.minecraft.entity.EntityTracker$1",
|
||||
"net.minecraft.world.gen.layer.GenLayer$1",
|
||||
"net.minecraft.world.gen.layer.GenLayer$2",
|
||||
"net.minecraft.entity.player.InventoryPlayer$1",
|
||||
"net.minecraft.world.gen.structure.MapGenStructure$1",
|
||||
"net.minecraft.world.gen.structure.MapGenStructure$2",
|
||||
"net.minecraft.world.gen.structure.MapGenStructure$3",
|
||||
"net.minecraft.server.MinecraftServer$3",
|
||||
"net.minecraft.server.MinecraftServer$4",
|
||||
"net.minecraft.server.MinecraftServer$5",
|
||||
"net.minecraft.nbt.NBTTagCompound$1",
|
||||
"net.minecraft.nbt.NBTTagCompound$2",
|
||||
"net.minecraft.network.NetHandlerPlayServer$2",
|
||||
"net.minecraft.network.NetworkSystem$3",
|
||||
"net.minecraft.tileentity.TileEntity$1",
|
||||
"net.minecraft.tileentity.TileEntity$2",
|
||||
"net.minecraft.tileentity.TileEntity$3",
|
||||
"net.minecraft.world.storage.WorldInfo$1",
|
||||
"net.minecraft.world.storage.WorldInfo$2",
|
||||
"net.minecraft.world.storage.WorldInfo$3",
|
||||
"net.minecraft.world.storage.WorldInfo$4",
|
||||
"net.minecraft.world.storage.WorldInfo$5",
|
||||
"net.minecraft.world.storage.WorldInfo$6",
|
||||
"net.minecraft.world.storage.WorldInfo$7",
|
||||
"net.minecraft.world.storage.WorldInfo$8",
|
||||
"net.minecraft.world.storage.WorldInfo$9"
|
||||
};
|
||||
String[] client = {
|
||||
"net.minecraft.client.Minecraft$3",
|
||||
"net.minecraft.client.Minecraft$4",
|
||||
"net.minecraft.client.Minecraft$5",
|
||||
"net.minecraft.client.Minecraft$6",
|
||||
"net.minecraft.client.Minecraft$7",
|
||||
"net.minecraft.client.Minecraft$8",
|
||||
"net.minecraft.client.Minecraft$9",
|
||||
"net.minecraft.client.Minecraft$10",
|
||||
"net.minecraft.client.Minecraft$11",
|
||||
"net.minecraft.client.Minecraft$12",
|
||||
"net.minecraft.client.Minecraft$13",
|
||||
"net.minecraft.client.Minecraft$14",
|
||||
"net.minecraft.client.Minecraft$15",
|
||||
"net.minecraft.client.multiplayer.WorldClient$1",
|
||||
"net.minecraft.client.multiplayer.WorldClient$2",
|
||||
"net.minecraft.client.multiplayer.WorldClient$3",
|
||||
"net.minecraft.client.multiplayer.WorldClient$4",
|
||||
"net.minecraft.client.particle,EffectRenderer$1",
|
||||
"net.minecraft.client.particle,EffectRenderer$2",
|
||||
"net.minecraft.client.particle,EffectRenderer$3",
|
||||
"net.minecraft.client.particle,EffectRenderer$4",
|
||||
"net.minecraft.client.renderer.EntityRenderer$1",
|
||||
"net.minecraft.client.renderer.EntityRenderer$2",
|
||||
"net.minecraft.client.renderer.EntityRenderer$3",
|
||||
"net.minecraft.server.integrated.IntegratedServer$1",
|
||||
"net.minecraft.server.integrated.IntegratedServer$2",
|
||||
"net.minecraft.client.renderer.RenderGlobal$1",
|
||||
"net.minecraft.client.renderer.entity.RenderItem$1",
|
||||
"net.minecraft.client.renderer.entity.RenderItem$2",
|
||||
"net.minecraft.client.renderer.entity.RenderItem$3",
|
||||
"net.minecraft.client.renderer.entity.RenderItem$4",
|
||||
"net.minecraft.client.renderer.texture.TextureAtlasSprite$1",
|
||||
"net.minecraft.client.renderer.texture.TextureManager$1",
|
||||
"net.minecraft.client.renderer.texture.TextureMap$1",
|
||||
"net.minecraft.client.renderer.texture.TextureMap$2",
|
||||
"net.minecraft.client.renderer.texture.TextureMap$3"
|
||||
};
|
||||
String[] server = {
|
||||
"net.minecraft.server.dedicated.DedicatedServer$3",
|
||||
"net.minecraft.server.dedicated.DedicatedServer$4"
|
||||
};
|
||||
if (FMLCommonHandler.instance().getSide() == Side.CLIENT)
|
||||
handlers = ObjectArrays.concat(handlers, client, String.class);
|
||||
else
|
||||
handlers = ObjectArrays.concat(handlers, server, String.class);
|
||||
|
||||
FMLLog.info("Preloading CrashReport classes", ForgeVersion.getVersion());
|
||||
for (String s : handlers)
|
||||
{
|
||||
//FMLLog.info("\t" + s);
|
||||
try
|
||||
{
|
||||
Class cls = Class.forName(s, false, MinecraftForge.class.getClassLoader());
|
||||
if (cls != null && !Callable.class.isAssignableFrom(cls))
|
||||
{
|
||||
FMLLog.info("\t% s is not a instance of callable!", s);
|
||||
}
|
||||
}
|
||||
catch (Exception e){}
|
||||
}
|
||||
|
||||
UsernameCache.load();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue