mirror of
https://github.com/GTNewHorizons/MagicBees.git
synced 2026-11-19 11:59:19 +00:00
Moving some helper block & item grabbing to postInit; GameRegistry seems more reliable there. Should close #58 #64
This commit is contained in:
1 parent
7a028787c5
commit
707266cad7
5 files changed
+16
-17
No files matched your search
@@ -319,7 +319,7 @@ public class BeeProductHelper {
|
||||
RSA_FLUXED.addProduct(ForestryHelper.itemHoneycomb, 10);
|
||||
|
||||
if (RedstoneArsenalHelper.isActive()) {
|
||||
RSA_FLUXED.addSpecialty(Config.rsaFluxNugget, 9);
|
||||
RSA_FLUXED.addSpecialty(RedstoneArsenalHelper.fluxNugget, 9);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -190,9 +190,6 @@ public class Config
|
||||
//----- Ars Magica Items -----------------------------------
|
||||
public static Item amItemResource;
|
||||
public static Item amEssence;
|
||||
//----Redstone Arsenal Items---
|
||||
public static ItemStack rsaFluxBlock;
|
||||
public static ItemStack rsaFluxNugget;
|
||||
//---ThermalExpansion Items ---
|
||||
public static ItemStack teEnderiumBlock;
|
||||
public static ItemStack teElectrumBlock;
|
||||
|
||||
@@ -59,9 +59,6 @@ public class MagicBees
|
||||
public void init(FMLInitializationEvent event)
|
||||
{
|
||||
ModHelper.init();
|
||||
|
||||
BeeManager.ititializeBees();
|
||||
|
||||
LogHelper.info("Init completed");
|
||||
}
|
||||
|
||||
@@ -69,6 +66,8 @@ public class MagicBees
|
||||
public void postInit(FMLPostInitializationEvent event)
|
||||
{
|
||||
ModHelper.postInit();
|
||||
|
||||
BeeManager.ititializeBees();
|
||||
|
||||
this.guiHandler = new GUIHandler();
|
||||
NetworkRegistry.INSTANCE.registerGuiHandler(this, this.guiHandler);
|
||||
|
||||
@@ -48,14 +48,13 @@ public class ArsMagicaHelper {
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
}
|
||||
|
||||
public static void postInit() {
|
||||
if (isActive()) {
|
||||
getBlocks();
|
||||
getItems();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static void postInit() {
|
||||
}
|
||||
|
||||
private static void getBlocks() {
|
||||
|
||||
@@ -2,6 +2,7 @@ package magicbees.main.utils.compat;
|
||||
|
||||
import magicbees.main.Config;
|
||||
import magicbees.main.utils.ItemInterface;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
|
||||
public class RedstoneArsenalHelper {
|
||||
@@ -12,6 +13,9 @@ public class RedstoneArsenalHelper {
|
||||
public enum NuggetType {
|
||||
ELECTRUMFLUX, ;
|
||||
}
|
||||
|
||||
public static ItemStack fluxBlock;
|
||||
public static ItemStack fluxNugget;
|
||||
|
||||
public static final String Name = "RedstoneArsenal";
|
||||
private static boolean isRedstoneArsenalPresent = false;
|
||||
@@ -27,21 +31,21 @@ public class RedstoneArsenalHelper {
|
||||
}
|
||||
|
||||
public static void init() {
|
||||
// if (isActive()) { }
|
||||
}
|
||||
|
||||
public static void postInit() {
|
||||
if (isActive()) {
|
||||
getBlocks();
|
||||
getItems();
|
||||
}
|
||||
}
|
||||
|
||||
public static void postInit() {
|
||||
// if (isActive()) { }
|
||||
}
|
||||
|
||||
private static void getBlocks() {
|
||||
Config.rsaFluxBlock = ItemInterface.getItemStack("RedstoneArsenal", "blockElectrumFlux", 1);
|
||||
fluxBlock = ItemInterface.getItemStack(Name, "blockElectrumFlux");
|
||||
}
|
||||
|
||||
private static void getItems() {
|
||||
Config.rsaFluxNugget = ItemInterface.getItemStack("RedstoneArsenal", "nuggetElectrumFlux", 1);
|
||||
fluxNugget = ItemInterface.getItemStack(Name, "nuggetElectrumFlux");
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user