diff options
author | Jordan Byrne <draknyte1@hotmail.com> | 2018-03-20 21:54:54 +1000 |
---|---|---|
committer | Jordan Byrne <draknyte1@hotmail.com> | 2018-03-20 21:54:54 +1000 |
commit | 769b7f51c217f57f6b4c9ef716bd9761f036c861 (patch) | |
tree | 823506e9bad14c0499aea69c15c0d08b8aab08e3 /src/Java/gtPlusPlus/core | |
parent | cbebd3bfd6b66a95f9a9f4fc6eacb29fb8c81e0c (diff) | |
download | GT5-Unofficial-769b7f51c217f57f6b4c9ef716bd9761f036c861.tar.gz GT5-Unofficial-769b7f51c217f57f6b4c9ef716bd9761f036c861.tar.bz2 GT5-Unofficial-769b7f51c217f57f6b4c9ef716bd9761f036c861.zip |
$ Moved Item & Block generation earlier into Pre-Init, before recipes are handled anywhere.
$ Stopped getItemStackOfAmountFromOreDictNoBroken() caching invalid results, so that when they are generated, they can be cached later.
Diffstat (limited to 'src/Java/gtPlusPlus/core')
-rw-r--r-- | src/Java/gtPlusPlus/core/common/CommonProxy.java | 14 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/item/ModItems.java | 8 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/util/minecraft/ItemUtils.java | 2 |
3 files changed, 12 insertions, 12 deletions
diff --git a/src/Java/gtPlusPlus/core/common/CommonProxy.java b/src/Java/gtPlusPlus/core/common/CommonProxy.java index 47a5f61fdd..4d32d66ecd 100644 --- a/src/Java/gtPlusPlus/core/common/CommonProxy.java +++ b/src/Java/gtPlusPlus/core/common/CommonProxy.java @@ -68,6 +68,15 @@ public class CommonProxy { else { Logger.WARNING("Development mode not set."); } + + //Moved from Init after Debug Loading. + //29/01/18 - Alkalus + //Moved earlier into PreInit, so that Items exist before they're called upon in recipes. + //20/03/18 - Alkalus + ModItems.init(); + ModBlocks.init(); + CI.preInit(); + AddToCreativeTab.initialiseTabs(); COMPAT_IntermodStaging.preInit(); BookHandler.run(); @@ -77,11 +86,6 @@ public class CommonProxy { Logger.INFO("[Proxy] Calling Tile Entity registrator."); registerTileEntities(); - //Moved from Init after Debug Loading. - //29/01/18 - Alkalus - ModItems.init(); - ModBlocks.init(); - CI.preInit(); Logger.INFO("[Proxy] Calling Render registrator."); registerRenderThings(); diff --git a/src/Java/gtPlusPlus/core/item/ModItems.java b/src/Java/gtPlusPlus/core/item/ModItems.java index 33215234b9..53fb757539 100644 --- a/src/Java/gtPlusPlus/core/item/ModItems.java +++ b/src/Java/gtPlusPlus/core/item/ModItems.java @@ -260,14 +260,12 @@ public final class ModItems { static { Logger.INFO("Items!"); - } - - public static final void init(){ - - //Default item used when recipes fail, handy for debugging. + //Default item used when recipes fail, handy for debugging. Let's make sure they exist when this class is called upon. AAA_Broken = new BaseItemIngot_OLD("AAA_Broken", "Errors - Tell Alkalus", Utils.rgbtoHexValue(128, 128, 128), 0); ZZZ_Empty = new ItemEmpty(); + } + public static final void init(){ itemAlkalusDisk = new BaseItemDamageable("itemAlkalusDisk", AddToCreativeTab.tabMisc, 1, 0, "Unknown Use", EnumRarity.rare, EnumChatFormatting.AQUA, false, null); //Debug Loading diff --git a/src/Java/gtPlusPlus/core/util/minecraft/ItemUtils.java b/src/Java/gtPlusPlus/core/util/minecraft/ItemUtils.java index afa28cecee..ffde242f7d 100644 --- a/src/Java/gtPlusPlus/core/util/minecraft/ItemUtils.java +++ b/src/Java/gtPlusPlus/core/util/minecraft/ItemUtils.java @@ -343,11 +343,9 @@ public class ItemUtils { } } Logger.WARNING(oredictName+" was not valid."); - setCachedValue(oredictName, null); return null; } catch (final Throwable t){ - setCachedValue(oredictName, null); return null; } } |