2013-05-28 06:29:29 +02:00
|
|
|
package ic2.api.info;
|
|
|
|
|
2013-08-22 17:36:31 +02:00
|
|
|
import net.minecraft.util.DamageSource;
|
|
|
|
|
2013-11-21 22:50:40 +01:00
|
|
|
import cpw.mods.fml.common.Loader;
|
|
|
|
import cpw.mods.fml.common.LoaderState;
|
|
|
|
|
2013-05-28 06:29:29 +02:00
|
|
|
public class Info {
|
|
|
|
public static IEnergyValueProvider itemEnergy;
|
|
|
|
public static IFuelValueProvider itemFuel;
|
2013-08-22 17:36:31 +02:00
|
|
|
public static Object ic2ModInstance;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Damage Sources used by IC2.
|
|
|
|
* Getting assigned in preload.
|
|
|
|
*/
|
|
|
|
public static DamageSource DMG_ELECTRIC, DMG_NUKE_EXPLOSION, DMG_RADIATION;
|
2013-11-21 22:50:40 +01:00
|
|
|
|
|
|
|
public static boolean isIc2Available() {
|
|
|
|
if (ic2Available != null) return ic2Available;
|
|
|
|
|
|
|
|
boolean loaded = Loader.isModLoaded("IC2");
|
|
|
|
|
|
|
|
if (Loader.instance().hasReachedState(LoaderState.CONSTRUCTING)) {
|
|
|
|
ic2Available = loaded;
|
|
|
|
}
|
|
|
|
|
|
|
|
return loaded;
|
|
|
|
}
|
|
|
|
|
|
|
|
private static Boolean ic2Available = null;
|
2013-08-22 17:36:31 +02:00
|
|
|
}
|