Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Arcaratus 2015-06-12 15:12:22 -04:00
commit 4f9acb223f
124 changed files with 4228 additions and 288 deletions

View file

@ -11,9 +11,6 @@ import java.util.List;
import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream;
import WayofTime.alchemicalWizardry.api.bindingRegistry.UnbindingRegistry;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.HoldingPacketHandler;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.ScrollHelper;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
@ -48,6 +45,7 @@ import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentRegistry;
import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentStack;
import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipeRegistry;
import WayofTime.alchemicalWizardry.api.bindingRegistry.BindingRegistry;
import WayofTime.alchemicalWizardry.api.bindingRegistry.UnbindingRegistry;
import WayofTime.alchemicalWizardry.api.compress.CompressionRegistry;
import WayofTime.alchemicalWizardry.api.harvest.HarvestRegistry;
import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe;
@ -114,10 +112,12 @@ import WayofTime.alchemicalWizardry.common.harvest.BloodMagicHarvestHandler;
import WayofTime.alchemicalWizardry.common.harvest.CactusReedHarvestHandler;
import WayofTime.alchemicalWizardry.common.harvest.GourdHarvestHandler;
import WayofTime.alchemicalWizardry.common.harvest.PamHarvestCompatRegistry;
import WayofTime.alchemicalWizardry.common.items.ItemIncense;
import WayofTime.alchemicalWizardry.common.items.ItemMailOrderCatalogue;
import WayofTime.alchemicalWizardry.common.items.ItemRitualDiviner;
import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmour;
import WayofTime.alchemicalWizardry.common.items.forestry.ItemBloodFrame;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.SigilOfHolding;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.HoldingPacketHandler;
import WayofTime.alchemicalWizardry.common.items.thaumcraft.ItemSanguineArmour;
import WayofTime.alchemicalWizardry.common.omega.OmegaParadigmEarth;
import WayofTime.alchemicalWizardry.common.omega.OmegaParadigmFire;
@ -144,6 +144,7 @@ import WayofTime.alchemicalWizardry.common.potion.PotionSoulHarden;
import WayofTime.alchemicalWizardry.common.renderer.AlchemyCircleRenderer;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectAnimalGrowth;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectAutoAlchemy;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectBinding;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectBiomeChanger;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectContainment;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectCrafting;
@ -169,7 +170,6 @@ import WayofTime.alchemicalWizardry.common.rituals.RitualEffectLifeConduit;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectMagnetic;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectOmegaStalling;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectOmegaTest;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectBinding;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectSpawnWard;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectSphereCreator;
import WayofTime.alchemicalWizardry.common.rituals.RitualEffectSummonMeteor;
@ -295,7 +295,7 @@ import cpw.mods.fml.common.network.NetworkRegistry;
import cpw.mods.fml.common.registry.EntityRegistry;
import cpw.mods.fml.common.registry.GameRegistry;
@Mod(modid = "AWWayofTime", name = "AlchemicalWizardry", version = "v1.3.2", guiFactory = "WayofTime.alchemicalWizardry.client.gui.ConfigGuiFactory")
@Mod(modid = "AWWayofTime", name = "AlchemicalWizardry", version = "v1.3.3", guiFactory = "WayofTime.alchemicalWizardry.client.gui.ConfigGuiFactory")
public class AlchemicalWizardry
{
@ -386,11 +386,38 @@ public class AlchemicalWizardry
public static boolean ritualDisabledPhantomHands;
public static boolean ritualDisabledSphereIsland;
public static boolean potionDisableRegen;
public static boolean potionDisableNightVision;
public static boolean potionDisableFireResistance;
public static boolean potionDisableWaterBreathing;
public static boolean potionDisableMoveSpeed;
public static boolean potionDisableInstantHealth;
public static boolean potionDisablePoison;
public static boolean potionDisableBlindness;
public static boolean potionDisableWeakness;
public static boolean potionDisableStrength;
public static boolean potionDisableJumpBoost;
public static boolean potionDisableSlowness;
public static boolean potionDisableMining;
public static boolean potionDisableDrowning;
public static boolean potionDisableInvisibility;
public static boolean potionDisableResistance;
public static boolean potionDisableSaturation;
public static boolean potionDisableHealthBoost;
public static boolean potionDisableAbsorption;
public static boolean potionDisableBoost;
public static boolean potionDisableFlight;
public static boolean potionDisableReciprocation;
public static boolean potionDisablePlanarBinding;
public static boolean potionDisableSoulFray;
public static boolean potionDisableSoulHarden;
public static boolean potionDisableDeafness;
public static boolean isThaumcraftLoaded;
public static boolean isForestryLoaded;
public static boolean isBotaniaLoaded;
public static boolean isFMPLoaded;
public static boolean isPneumaticCraftLoaded;
public static boolean wimpySettings;
public static boolean respawnWithDebuff;
@ -733,7 +760,6 @@ public class AlchemicalWizardry
GameRegistry.addRecipe(new ShapedBloodOrbRecipe(new ItemStack(ModItems.itemBloodLightSigil), "btb", "sss", "bob", 'o', magicianBloodOrbStack, 'b', glowstoneBlockStack, 't', new ItemStack(Blocks.torch), 's', imbuedSlateStack));
GameRegistry.addRecipe(new ItemStack(ModItems.itemKeyOfDiablo), " gw", "gdg", "wg ", 'w', weakBloodShardStack, 'g', goldIngotStack, 'd', diamondStack);
GameRegistry.addRecipe(new ItemStack(ModItems.itemBloodPack), "gbg","flf","gsg",'s', blankSlateStack,'g', glassStack,'f',new ItemStack(Items.flint,1,craftingConstant),'b', emptyBucketStack, 'l', new ItemStack(Items.leather_chestplate));
GameRegistry.addShapelessRecipe(new ItemStack(ModItems.itemMailCatalogue), new ItemStack(Items.book), new ItemStack(Items.dye, 1, 0), new ItemStack(Items.feather), glassStack, glassStack);
customPotionDrowning = (new PotionDrowning(customPotionDrowningID, true, 0)).setIconIndex(0, 0).setPotionName("Drowning");
customPotionBoost = (new PotionBoost(customPotionBoostID, false, 0)).setIconIndex(0, 0).setPotionName("Boost");
customPotionProjProt = (new PotionProjectileProtect(customPotionProjProtID, false, 0)).setIconIndex(0, 0).setPotionName("Whirlwind");
@ -830,7 +856,6 @@ public class AlchemicalWizardry
blacklistAccelerators();
MinecraftForge.EVENT_BUS.register(new ModLivingDropsEvent());
MinecraftForge.EVENT_BUS.register(new ScrollHelper());
proxy.InitRendering();
NetworkRegistry.INSTANCE.registerGuiHandler(this, new GuiHandler());
@ -1121,6 +1146,9 @@ public class AlchemicalWizardry
AlchemyRecipeRegistry.registerRecipe(new ItemStack(Items.ghast_tear, 2), 100, new ItemStack[]{ghastTearStack, concentratedCatalystStack, weakBloodShardStack, new ItemStack(Blocks.soul_sand), new ItemStack(Blocks.soul_sand)}, 5);
AlchemyRecipeRegistry.registerRecipe(new ItemStack(Items.coal, 5), 1, new ItemStack[]{new ItemStack(Items.coal, 1, 1), new ItemStack(Items.coal, 1, 1), new ItemStack(Items.coal, 1, 1), new ItemStack(Items.coal, 1, 1), new ItemStack(Items.coal, 1, 1)}, 1);
AlchemyRecipeRegistry.registerRecipe(new ItemStack(Items.clay_ball, 4), 5, new ItemStack[]{new ItemStack(Blocks.sand), waterBucketStack}, 2);
ItemIncense.registerIncenseRecipes();
GameRegistry.addRecipe(new ItemStack(ModBlocks.blockCrucible), "i i", "sis", " S ", 's', new ItemStack(Blocks.stone_slab), 'i', ironIngotStack, 'S', stoneStack);
}
@EventHandler
@ -1196,6 +1224,10 @@ public class AlchemicalWizardry
long finalTime = System.nanoTime();
AlchemicalWizardry.logger.info("Recipe Holder initialized: took " + (finalTime - initialTime)/1000000f + "ms.");
ModItems.itemMailCatalogue = new ItemMailOrderCatalogue().setUnlocalizedName("itemMailCatalogue");
GameRegistry.registerItem(ModItems.itemMailCatalogue, "itemMailCatalogue");
GameRegistry.addShapelessRecipe(new ItemStack(ModItems.itemMailCatalogue), new ItemStack(Items.book), new ItemStack(Items.dye, 1, 0), new ItemStack(Items.feather), new ItemStack(Blocks.glass, 1, OreDictionary.WILDCARD_VALUE), new ItemStack(Blocks.glass, 1, OreDictionary.WILDCARD_VALUE));
registerBMBook();
}
@ -1235,8 +1267,10 @@ public class AlchemicalWizardry
}
isBotaniaLoaded = Loader.isModLoaded("Botania");
isPneumaticCraftLoaded = Loader.isModLoaded("PneumaticCraft");
isFMPLoaded = Loader.isModLoaded("ForgeMultipart");
BloodMagicConfiguration.loadBlacklist();
BloodMagicConfiguration.blacklistRituals();
@ -1329,34 +1363,86 @@ public class AlchemicalWizardry
}
}
//TODO
public static void initAlchemyPotionRecipes()
{
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.ghast_tear), Potion.regeneration.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.golden_carrot), Potion.nightVision.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.magma_cream), Potion.fireResistance.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.water_bucket), Potion.waterBreathing.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.sugar), Potion.moveSpeed.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.speckled_melon), Potion.heal.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.spider_eye), Potion.poison.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.dye, 1, 0), Potion.blindness.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.fermented_spider_eye), Potion.weakness.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.blaze_powder), Potion.damageBoost.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.aether), Potion.jump.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.clay_ball), Potion.moveSlowdown.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.redstone), Potion.digSpeed.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.potionitem, 1, 0), AlchemicalWizardry.customPotionDrowning.id, 450);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.glass_bottle), Potion.invisibility.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.diamond), Potion.resistance.id, 2 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.poisonous_potato), Potion.field_76443_y.id, 2); //saturation
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.demonBloodShard), Potion.field_76434_w.id, 4 * 60 * 20); //health boost
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.weakBloodShard), Potion.field_76444_x.id, 4 * 60 * 20); //Absorption
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.terrae), AlchemicalWizardry.customPotionBoost.id, 1 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.feather), AlchemicalWizardry.customPotionFlight.id, 1 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.arrow), AlchemicalWizardry.customPotionReciprocation.id, 1 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.ender_pearl), AlchemicalWizardry.customPotionPlanarBinding.id, 1 * 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Blocks.soul_sand), AlchemicalWizardry.customPotionSoulFray.id, 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.baseItems, 1, 16), AlchemicalWizardry.customPotionSoulHarden.id, 60 * 20);
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.slime_ball), AlchemicalWizardry.customPotionDeaf.id, 60 * 20);
if(!AlchemicalWizardry.potionDisableRegen)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.ghast_tear), Potion.regeneration.id, 450);
if(!AlchemicalWizardry.potionDisableNightVision)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.golden_carrot), Potion.nightVision.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableFireResistance)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.magma_cream), Potion.fireResistance.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableWaterBreathing)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.water_bucket), Potion.waterBreathing.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableMoveSpeed)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.sugar), Potion.moveSpeed.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableInstantHealth)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.speckled_melon), Potion.heal.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisablePoison)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.spider_eye), Potion.poison.id, 450);
if(!AlchemicalWizardry.potionDisableBlindness)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.dye, 1, 0), Potion.blindness.id, 450);
if(!AlchemicalWizardry.potionDisableWeakness)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.fermented_spider_eye), Potion.weakness.id, 450);
if(!AlchemicalWizardry.potionDisableStrength)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.blaze_powder), Potion.damageBoost.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableJumpBoost)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.aether), Potion.jump.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableSlowness)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.clay_ball), Potion.moveSlowdown.id, 450);
if(!AlchemicalWizardry.potionDisableMining)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.redstone), Potion.digSpeed.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableDrowning)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.potionitem, 1, 0), AlchemicalWizardry.customPotionDrowning.id, 450);
if(!AlchemicalWizardry.potionDisableInvisibility)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.glass_bottle), Potion.invisibility.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableResistance)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.diamond), Potion.resistance.id, 2 * 60 * 20);
if(!AlchemicalWizardry.potionDisableSaturation)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.poisonous_potato), Potion.field_76443_y.id, 2); //saturation
if(!AlchemicalWizardry.potionDisableHealthBoost)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.demonBloodShard), Potion.field_76434_w.id, 4 * 60 * 20); //health boost
if(!AlchemicalWizardry.potionDisableAbsorption)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.weakBloodShard), Potion.field_76444_x.id, 4 * 60 * 20); //Absorption
if(!AlchemicalWizardry.potionDisableBoost)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.terrae), AlchemicalWizardry.customPotionBoost.id, 1 * 60 * 20);
if(!AlchemicalWizardry.potionDisableFlight)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.feather), AlchemicalWizardry.customPotionFlight.id, 1 * 60 * 20);
if(!AlchemicalWizardry.potionDisableReciprocation)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.arrow), AlchemicalWizardry.customPotionReciprocation.id, 1 * 60 * 20);
if(!AlchemicalWizardry.potionDisablePlanarBinding)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.ender_pearl), AlchemicalWizardry.customPotionPlanarBinding.id, 1 * 60 * 20);
if(!AlchemicalWizardry.potionDisableSoulFray)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Blocks.soul_sand), AlchemicalWizardry.customPotionSoulFray.id, 60 * 20);
if(!AlchemicalWizardry.potionDisableSoulHarden)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(ModItems.baseItems, 1, 16), AlchemicalWizardry.customPotionSoulHarden.id, 60 * 20);
if(!AlchemicalWizardry.potionDisableDeafness)
AlchemicalPotionCreationHandler.addPotion(new ItemStack(Items.slime_ball), AlchemicalWizardry.customPotionDeaf.id, 60 * 20);
}
public static void initAltarRecipes()
@ -1436,7 +1522,7 @@ public class AlchemicalWizardry
Rituals.registerRitual("AW035PhantomHands", 1, 10000, new RitualEffectItemRouting(), "Orchestra of the Phantom Hands");
Rituals.registerRitual("AW036SphereIsland", 2, 10000, new RitualEffectSphereCreator(), "Birth of the Bastion");
Rituals.registerRitual("AW036SphereIsland", 2, 10000, new RitualEffectSphereCreator(), "Blood of the New Moon");
//Rituals.registerRitual(1,100,new RitualEffectApiaryOverclock(),"Apiary Overclock"));
}

View file

@ -145,6 +145,33 @@ public class BloodMagicConfiguration
AlchemicalWizardry.ritualDisabledCrafting = config.get("Ritual Blacklist", "Rhythm of the Beating Anvil", false).getBoolean(false);
AlchemicalWizardry.ritualDisabledPhantomHands = config.get("Ritual Blacklist", "Orchestra of the Phantom Hands", false).getBoolean(false);
AlchemicalWizardry.ritualDisabledSphereIsland = config.get("Ritual Blacklist", "Birth of the Bastion", false).getBoolean(false);
AlchemicalWizardry.potionDisableRegen = config.get("Alchemy Potion Blacklist", "Regeneration", false).getBoolean(false);
AlchemicalWizardry.potionDisableNightVision = config.get("Alchemy Potion Blacklist", "Night Vision", false).getBoolean(false);
AlchemicalWizardry.potionDisableFireResistance = config.get("Alchemy Potion Blacklist", "Fire Resistance", false).getBoolean(false);
AlchemicalWizardry.potionDisableWaterBreathing = config.get("Alchemy Potion Blacklist", "Water Breathing", false).getBoolean(false);
AlchemicalWizardry.potionDisableMoveSpeed = config.get("Alchemy Potion Blacklist", "Move Speed", false).getBoolean(false);
AlchemicalWizardry.potionDisableInstantHealth = config.get("Alchemy Potion Blacklist", "Instant Health", false).getBoolean(false);
AlchemicalWizardry.potionDisablePoison = config.get("Alchemy Potion Blacklist", "Poison", false).getBoolean(false);
AlchemicalWizardry.potionDisableBlindness = config.get("Alchemy Potion Blacklist", "Blindness", false).getBoolean(false);
AlchemicalWizardry.potionDisableWeakness = config.get("Alchemy Potion Blacklist", "Weakness", false).getBoolean(false);
AlchemicalWizardry.potionDisableStrength = config.get("Alchemy Potion Blacklist", "Strength", false).getBoolean(false);
AlchemicalWizardry.potionDisableJumpBoost = config.get("Alchemy Potion Blacklist", "Jump Boost", false).getBoolean(false);
AlchemicalWizardry.potionDisableSlowness = config.get("Alchemy Potion Blacklist", "Slowness", false).getBoolean(false);
AlchemicalWizardry.potionDisableMining = config.get("Alchemy Potion Blacklist", "Mining Speed", false).getBoolean(false);
AlchemicalWizardry.potionDisableDrowning = config.get("Alchemy Potion Blacklist", "Drowning", false).getBoolean(false);
AlchemicalWizardry.potionDisableInvisibility = config.get("Alchemy Potion Blacklist", "Invisibility", false).getBoolean(false);
AlchemicalWizardry.potionDisableResistance = config.get("Alchemy Potion Blacklist", "Resistance", false).getBoolean(false);
AlchemicalWizardry.potionDisableSaturation = config.get("Alchemy Potion Blacklist", "Saturation", false).getBoolean(false);
AlchemicalWizardry.potionDisableHealthBoost = config.get("Alchemy Potion Blacklist", "Health Boost", false).getBoolean(false);
AlchemicalWizardry.potionDisableAbsorption = config.get("Alchemy Potion Blacklist", "Absorption", false).getBoolean(false);
AlchemicalWizardry.potionDisableBoost = config.get("Alchemy Potion Blacklist", "Boost", false).getBoolean(false);
AlchemicalWizardry.potionDisableFlight = config.get("Alchemy Potion Blacklist", "Flight", false).getBoolean(false);
AlchemicalWizardry.potionDisableReciprocation = config.get("Alchemy Potion Blacklist", "Reciprocation", false).getBoolean(false);
AlchemicalWizardry.potionDisablePlanarBinding = config.get("Alchemy Potion Blacklist", "Planar Binding", false).getBoolean(false);
AlchemicalWizardry.potionDisableSoulFray = config.get("Alchemy Potion Blacklist", "Soul Fray", false).getBoolean(false);
AlchemicalWizardry.potionDisableSoulHarden = config.get("Alchemy Potion Blacklist", "Soul Harden", false).getBoolean(false);
AlchemicalWizardry.potionDisableDeafness = config.get("Alchemy Potion Blacklist", "Deafness", false).getBoolean(false);
teleposerBlacklist = config.get("Teleposer Blacklist", "Blacklist", blacklist, "Stops specified blocks from being teleposed. Put entries on new lines. Valid syntax is: \nmodid:blockname:meta").getStringList();

View file

@ -37,7 +37,6 @@ import WayofTime.alchemicalWizardry.common.items.ItemComplexSpellCrystal;
import WayofTime.alchemicalWizardry.common.items.ItemComponents;
import WayofTime.alchemicalWizardry.common.items.ItemDiabloKey;
import WayofTime.alchemicalWizardry.common.items.ItemIncense;
import WayofTime.alchemicalWizardry.common.items.ItemMailOrderCatalogue;
import WayofTime.alchemicalWizardry.common.items.ItemRitualDiviner;
import WayofTime.alchemicalWizardry.common.items.LavaCrystal;
import WayofTime.alchemicalWizardry.common.items.LifeBucket;
@ -73,26 +72,26 @@ import WayofTime.alchemicalWizardry.common.items.potion.WeakFillingAgent;
import WayofTime.alchemicalWizardry.common.items.routing.InputRoutingFocus;
import WayofTime.alchemicalWizardry.common.items.routing.OutputRoutingFocus;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilAir;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilDivination;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilBloodLight;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilDivination;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilFluid;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilHarvest;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilPackRat;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilSeer;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfEnderSeverance;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfSupression;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfTheAssassin;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilLava;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfElementalAffinity;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfEnderSeverance;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfGrowth;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfHaste;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.SigilOfHolding;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfMagnetism;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfSupression;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfTheAssassin;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfTheBridge;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfTheFastMiner;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfWind;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilPackRat;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilSeer;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilVoid;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilWater;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.SigilOfHolding;
import cpw.mods.fml.common.registry.GameRegistry;
/**
@ -206,7 +205,6 @@ public class ModItems
public static Item itemTankSegmenter;
public static Item itemDestinationClearer;
public static Item itemBloodMagicBook;
public static Item itemHarvestSigil;
public static Item itemCompressionSigil;
@ -340,7 +338,6 @@ public class ModItems
itemAttunedCrystal = new ItemAttunedCrystal().setUnlocalizedName("itemAttunedCrystal");
itemTankSegmenter = new ItemTankSegmenter().setUnlocalizedName("itemTankSegmenter");
itemDestinationClearer = new ItemDestinationClearer().setUnlocalizedName("destinationClearer");
itemBloodMagicBook = new ItemBMBook().setUnlocalizedName("bmBook");
dawnScribeTool = new DawnScribeTool().setUnlocalizedName("dawnScribeTool");
@ -371,9 +368,7 @@ public class ModItems
inputRoutingFocus = new InputRoutingFocus().setUnlocalizedName("inputRoutingFocus");
outputRoutingFocus = new OutputRoutingFocus().setUnlocalizedName("outputRoutingFocus");
itemMailCatalogue = new ItemMailOrderCatalogue().setUnlocalizedName("itemMailCatalogue");
itemIncense = new ItemIncense().setUnlocalizedName("bloodMagicIncenseItem");
}
@ -473,8 +468,6 @@ public class ModItems
GameRegistry.registerItem(ModItems.itemAttunedCrystal, "itemAttunedCrystal");
GameRegistry.registerItem(ModItems.itemTankSegmenter, "itemTankSegmenter");
GameRegistry.registerItem(ModItems.itemDestinationClearer, "itemDestinationClearer");
GameRegistry.registerItem(ModItems.itemBloodMagicBook, "itemBloodMagicBook");
GameRegistry.registerItem(ModItems.baseItems, "bloodMagicBaseItems");
GameRegistry.registerItem(ModItems.baseAlchemyItems, "bloodMagicBaseAlchemyItems");
@ -509,7 +502,6 @@ public class ModItems
GameRegistry.registerItem(ModItems.inputRoutingFocus, "inputRoutingFocus");
GameRegistry.registerItem(ModItems.outputRoutingFocus, "outputRoutingFocus");
GameRegistry.registerItem(ModItems.itemMailCatalogue, "itemMailCatalogue");
GameRegistry.registerItem(ModItems.itemIncense, "bloodMagicIncenseItem");
}
}

View file

@ -0,0 +1,135 @@
package WayofTime.alchemicalWizardry.api.guide;
import java.util.ArrayList;
import java.util.List;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.IRecipe;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.StatCollector;
import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe;
import WayofTime.alchemicalWizardry.api.items.ShapelessBloodOrbRecipe;
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
import amerifrance.guideapi.ModInformation;
import amerifrance.guideapi.api.abstraction.CategoryAbstract;
import amerifrance.guideapi.api.abstraction.EntryAbstract;
import amerifrance.guideapi.api.abstraction.IRecipeRenderer;
import amerifrance.guideapi.api.base.Book;
import amerifrance.guideapi.api.util.GuiHelper;
import amerifrance.guideapi.gui.GuiBase;
import cpw.mods.fml.relauncher.ReflectionHelper;
public class OrbRecipeRenderer implements IRecipeRenderer
{
public IRecipe recipe;
public OrbRecipeRenderer(IRecipe recipe)
{
this.recipe = recipe;
}
@Override
public void draw(Book book, CategoryAbstract category, EntryAbstract entry,
int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase,
FontRenderer fontRenderer) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation(ModInformation.GUITEXLOC + "recipe_elements.png"));
guiBase.drawTexturedModalRect(guiLeft + 42, guiTop + 53, 0, 0, 105, 65);
guiBase.drawCenteredString(fontRenderer, StatCollector.translateToLocal("text.recipe.shapedOrb"), guiLeft + guiBase.xSize / 2, guiTop + 12, 0);
if(recipe instanceof ShapelessBloodOrbRecipe)
{
ShapelessBloodOrbRecipe shapelessBloodOrbRecipe = (ShapelessBloodOrbRecipe) recipe;
List<Object> list = shapelessBloodOrbRecipe.getInput();
int width = 3;
int height = 3;
for (int y = 0; y < height; y++) {
for (int x = 0; x < width; x++) {
if(list.size() - 1 < y * width + x)
{
continue;
}
int stackX = (x + 1) * 18 + (guiLeft + guiBase.xSize / 7);
int stackY = (y + 1) * 18 + (guiTop + guiBase.ySize / 5);
Object component = list.get(y * width + x);
if (component != null) {
if (component instanceof ItemStack) {
GuiHelper.drawItemStack((ItemStack) component, stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip((ItemStack) component, stackX, stackY);
}
} else if (component instanceof Integer) {
GuiHelper.drawItemStack(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
}
} else {
if (((ArrayList<ItemStack>) component).isEmpty()) return;
GuiHelper.drawItemStack(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
}
}
}
}
}
int outputX = (5 * 18) + (guiLeft + guiBase.xSize / 7);
int outputY = (2 * 18) + (guiTop + guiBase.xSize / 5);
GuiHelper.drawItemStack(shapelessBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
guiBase.renderToolTip(shapelessBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
}
}else
{
ShapedBloodOrbRecipe shapedBloodOrbRecipe = (ShapedBloodOrbRecipe) recipe;
int width = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 4);
int height = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 5);
for (int y = 0; y < height; y++) {
for (int x = 0; x < width; x++) {
int stackX = (x + 1) * 18 + (guiLeft + guiBase.xSize / 7);
int stackY = (y + 1) * 18 + (guiTop + guiBase.ySize / 5);
Object component = shapedBloodOrbRecipe.getInput()[y * width + x];
if (component != null) {
if (component instanceof ItemStack) {
GuiHelper.drawItemStack((ItemStack) component, stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip((ItemStack) component, stackX, stackY);
}
} else if (component instanceof Integer) {
GuiHelper.drawItemStack(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
}
} else {
if (((ArrayList<ItemStack>) component).isEmpty()) return;
GuiHelper.drawItemStack(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
}
}
}
}
}
int outputX = (5 * 18) + (guiLeft + guiBase.xSize / 7);
int outputY = (2 * 18) + (guiTop + guiBase.xSize / 5);
GuiHelper.drawItemStack(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
guiBase.renderToolTip(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
}
}
}
@Override
public void drawExtras(Book book, CategoryAbstract category,
EntryAbstract entry, int guiLeft, int guiTop, int mouseX,
int mouseY, GuiBase guiBase, FontRenderer fontRenderer) {
// TODO Auto-generated method stub
}
}

View file

@ -0,0 +1,145 @@
package WayofTime.alchemicalWizardry.api.guide;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.client.renderer.RenderHelper;
import net.minecraft.client.renderer.entity.RenderItem;
import net.minecraft.item.ItemStack;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import amerifrance.guideapi.api.abstraction.CategoryAbstract;
import amerifrance.guideapi.api.abstraction.EntryAbstract;
import amerifrance.guideapi.api.base.Book;
import amerifrance.guideapi.api.base.PageBase;
import amerifrance.guideapi.gui.GuiBase;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class PageMultiBlock extends PageBase
{
ItemStack[][][] structure;
boolean canTick = false;
int tick = 0;
int showLayer = -1;
float scaleFactor = 1;
boolean renderMouseOver = true;
public PageMultiBlock(ItemStack[][][] structure)
{
this.structure = structure;
initPage(structure);
}
int blockCount=0;
int[] countPerLevel;
int structureHeight = 0;
int structureLength = 0;
int structureWidth = 0;
public void initPage(ItemStack[][][] structure)
{
structureHeight = structure.length;
structureWidth=0;
structureLength=0;
countPerLevel = new int[structureHeight];
blockCount=0;
for(int h=0; h<structure.length; h++)
{
if(structure[h].length-1>structureLength)
structureLength = structure[h].length-1;
int perLvl=0;
for(int l=0; l<structure[h].length; l++)
{
if(structure[h][l].length-1>structureWidth)
structureWidth = structure[h][l].length-1;
for(ItemStack ss : structure[h][l])
if(ss!=null)
perLvl++;
}
countPerLevel[h] = perLvl;
blockCount += perLvl;
}
tick= (showLayer==-1?blockCount:countPerLevel[showLayer])*40;
int yOff = (structureHeight-1)*12+structureWidth*5+structureLength*5+16;
// pageButtons.add(new GuiButtonManualNavigation(gui, 100, x+4,y+yOff/2-5, 10,10, 4));
// pageButtons.add(new GuiButtonManualNavigation(gui, 101, x+4,y+yOff/2-8-16, 10,16, 3));
// pageButtons.add(new GuiButtonManualNavigation(gui, 102, x+4,y+yOff/2+8, 10,16, 2));
}
@Override
@SideOnly(Side.CLIENT)
public void draw(Book book, CategoryAbstract category, EntryAbstract entry, int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRenderer)
{
// if(multiblock.getStructureManual()!=null)
Minecraft mc = Minecraft.getMinecraft();
int x = guiLeft + 32;
int y = guiTop + 30;
{
if(canTick)
tick++;
int prevLayers = 0;
if(showLayer!=-1)
for(int ll=0; ll<showLayer; ll++)
prevLayers+=countPerLevel[ll];
int limiter = prevLayers+ (tick/40)% ((showLayer==-1?blockCount:countPerLevel[showLayer])+4);
int xHalf = (structureWidth*5 - structureLength*5);
int yOffPartial = (structureHeight-1)*12+structureWidth*5+structureLength*5;
int yOffTotal = yOffPartial+16;
GL11.glDisable(GL11.GL_DEPTH_TEST);
GL11.glPushMatrix();
GL11.glTranslatef((1-scaleFactor)*(guiLeft + 64), (1-scaleFactor)*(guiTop+60), 0);
GL11.glScalef(scaleFactor, scaleFactor, scaleFactor);
GL11.glEnable(GL12.GL_RESCALE_NORMAL);
RenderHelper.enableGUIStandardItemLighting();
RenderItem.getInstance().renderWithColor=true;
int i=0;
ItemStack highlighted = null;
for(int h=0; h<structure.length; h++)
if(showLayer==-1 || h<=showLayer)
{
ItemStack[][] level = structure[h];
for(int l=level.length-1; l>=0; l--)
{
ItemStack[] row = level[l];
for(int w=row.length-1; w>=0; w--)
{
int xx = 60 +xHalf -10*w +10*l -7;
int yy = yOffPartial - 5*w - 5*l -12*h;
GL11.glTranslated(0, 0, 1);
if(row[w]!=null && i<=limiter)
{
i++;
RenderItem.getInstance().renderItemIntoGUI(mc.fontRenderer, mc.renderEngine, row[w], x+xx, y+yy);
if(mouseX>=x+xx&&mouseX<x+xx+16 && mouseY>=y+yy&&mouseY<y+yy+16)
highlighted = row[w];
}
}
}
}
GL11.glTranslated(0, 0, -i);
RenderHelper.disableStandardItemLighting();
GL11.glDisable(GL12.GL_RESCALE_NORMAL);
GL11.glPopMatrix();
GL11.glEnable(GL11.GL_BLEND);
GL11.glEnable(GL11.GL_DEPTH_TEST);
mc.fontRenderer.setUnicodeFlag(false);
if(highlighted!=null && renderMouseOver)
guiBase.renderToolTip(highlighted, mouseX, mouseY);
RenderHelper.disableStandardItemLighting();
// mc.fontRenderer.setUnicodeFlag(true);
// if(localizedText!=null&&!localizedText.isEmpty())
// manual.fontRenderer.drawSplitString(localizedText, x,y+yOffTotal, 120, manual.getTextColour());
}
}
}

View file

@ -1,78 +0,0 @@
package WayofTime.alchemicalWizardry.api.guide;
import java.util.ArrayList;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.IRecipe;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.StatCollector;
import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe;
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
import amerifrance.guideapi.ModInformation;
import amerifrance.guideapi.api.abstraction.CategoryAbstract;
import amerifrance.guideapi.api.abstraction.EntryAbstract;
import amerifrance.guideapi.api.base.Book;
import amerifrance.guideapi.api.util.GuiHelper;
import amerifrance.guideapi.gui.GuiBase;
import amerifrance.guideapi.pages.PageIRecipe;
import cpw.mods.fml.relauncher.ReflectionHelper;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class PageOrbRecipe extends PageIRecipe {
/**
* @param recipe - Recipe to draw
*/
public PageOrbRecipe(IRecipe recipe)
{
super(recipe);
}
@Override
@SideOnly(Side.CLIENT)
public void draw(Book book, CategoryAbstract category, EntryAbstract entry, int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRenderer) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation(ModInformation.GUITEXLOC + "recipe_elements.png"));
guiBase.drawTexturedModalRect(guiLeft + 42, guiTop + 53, 0, 0, 105, 65);
guiBase.drawCenteredString(fontRenderer, StatCollector.translateToLocal("text.recipe.shapedOrb"), guiLeft + guiBase.xSize / 2, guiTop + 12, 0);
ShapedBloodOrbRecipe shapedBloodOrbRecipe = (ShapedBloodOrbRecipe) recipe;
int width = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 4);
int height = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 5);
for (int y = 0; y < height; y++) {
for (int x = 0; x < width; x++) {
int stackX = (x + 1) * 20 + (guiLeft + guiBase.xSize / 7);
int stackY = (y + 1) * 20 + (guiTop + guiBase.ySize / 5);
Object component = shapedBloodOrbRecipe.getInput()[y * width + x];
if (component != null) {
if (component instanceof ItemStack) {
GuiHelper.drawItemStack((ItemStack) component, stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip((ItemStack) component, stackX, stackY);
}
} else if (component instanceof Integer) {
GuiHelper.drawItemStack(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(APISpellHelper.getOrbForLevel((Integer) component), stackX, stackY);
}
} else {
if (((ArrayList<ItemStack>) component).isEmpty()) return;
GuiHelper.drawItemStack(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
guiBase.renderToolTip(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
}
}
}
}
}
int outputX = (5 * 20) + (guiLeft + guiBase.xSize / 7);
int outputY = (2 * 20) + (guiTop + guiBase.xSize / 5);
GuiHelper.drawItemStack(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
guiBase.renderToolTip(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
}
}
}

View file

@ -0,0 +1,96 @@
package WayofTime.alchemicalWizardry.api.guide;
import java.util.List;
import net.minecraft.item.ItemStack;
import WayofTime.alchemicalWizardry.ModBlocks;
import WayofTime.alchemicalWizardry.api.rituals.RitualComponent;
import WayofTime.alchemicalWizardry.api.rituals.Rituals;
public class PageRitualMultiBlock extends PageMultiBlock
{
private static ItemStack blankStone;
private static ItemStack waterStone;
private static ItemStack fireStone;
private static ItemStack earthStone;
private static ItemStack airStone;
private static ItemStack duskStone;
private static ItemStack dawnStone;
static
{
blankStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.BLANK);
waterStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.WATER);
fireStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.FIRE);
earthStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.EARTH);
airStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.AIR);
duskStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.DUSK);
dawnStone = new ItemStack(ModBlocks.ritualStone, 1, RitualComponent.DAWN);
}
private PageRitualMultiBlock(ItemStack[][][] structure)
{
super(structure);
}
public static PageRitualMultiBlock getPageForRitual(String ritualID)
{
return getPageForRitual(Rituals.getRitualList(ritualID));
}
public static PageRitualMultiBlock getPageForRitual(List<RitualComponent> ritualComponents)
{
int minX = 0;
int minY = 0;
int minZ = 0;
int maxX = 0;
int maxY = 0;
int maxZ = 0;
for(RitualComponent comp : ritualComponents)
{
minX = Math.min(comp.getX(), minX);
minY = Math.min(comp.getY(), minY);
minZ = Math.min(comp.getZ(), minZ);
maxX = Math.max(comp.getX(), maxX);
maxY = Math.max(comp.getY(), maxY);
maxZ = Math.max(comp.getZ(), maxZ);
}
System.out.println("Min: (" + minX + ", " + minY + ", " + minZ + "), Max: (" + maxX + ", " + maxY + ", " + maxZ + ")");
ItemStack[][][] tempStructure = new ItemStack[maxY-minY+1][maxX-minX+1][maxZ-minZ+1]; //First value is vertical, second is down to the left, third is down to the right
for(RitualComponent comp : ritualComponents)
{
tempStructure[comp.getY() - minY][comp.getX() - minX][comp.getZ() - minZ] = getStackForRitualStone(comp.getStoneType());
}
tempStructure[-minY][-minX][-minZ] = new ItemStack(ModBlocks.blockMasterStone);
return new PageRitualMultiBlock(tempStructure);
}
private static ItemStack getStackForRitualStone(int type)
{
switch(type)
{
case RitualComponent.BLANK:
return blankStone;
case RitualComponent.WATER:
return waterStone;
case RitualComponent.FIRE:
return fireStone;
case RitualComponent.EARTH:
return earthStone;
case RitualComponent.AIR:
return airStone;
case RitualComponent.DUSK:
return duskStone;
case RitualComponent.DAWN:
return dawnStone;
}
return blankStone;
}
}

View file

@ -30,9 +30,11 @@ public class PlayerSacrificeHandler
return false;
}
amount = amount + Math.max(increment, max - amount);
amount = amount + Math.min(increment, max - amount);
setPlayerIncense(player, amount);
// System.out.println("Amount of incense: " + amount + ", Increment: " + increment);
return true;
}

View file

@ -1,14 +1,13 @@
package WayofTime.alchemicalWizardry.client;
import WayofTime.alchemicalWizardry.client.renderer.RitualDivinerRender;
import net.minecraft.item.ItemBlock;
import net.minecraft.world.World;
import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraftforge.common.MinecraftForge;
import WayofTime.alchemicalWizardry.ModBlocks;
import WayofTime.alchemicalWizardry.api.spell.EntitySpellProjectile;
import WayofTime.alchemicalWizardry.client.renderer.RitualDivinerRender;
import WayofTime.alchemicalWizardry.common.CommonProxy;
import WayofTime.alchemicalWizardry.common.book.BUEntries;
import WayofTime.alchemicalWizardry.common.demonVillage.demonHoard.demon.EntityMinorDemonGrunt;
import WayofTime.alchemicalWizardry.common.demonVillage.demonHoard.demon.EntityMinorDemonGruntEarth;
import WayofTime.alchemicalWizardry.common.demonVillage.demonHoard.demon.EntityMinorDemonGruntFire;
@ -37,6 +36,7 @@ import WayofTime.alchemicalWizardry.common.entity.projectile.EnergyBlastProjecti
import WayofTime.alchemicalWizardry.common.entity.projectile.EntityEnergyBazookaMainProjectile;
import WayofTime.alchemicalWizardry.common.entity.projectile.EntityMeteor;
import WayofTime.alchemicalWizardry.common.entity.projectile.EntityParticleBeam;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.ScrollHelper;
import WayofTime.alchemicalWizardry.common.renderer.block.RenderAlchemicCalcinator;
import WayofTime.alchemicalWizardry.common.renderer.block.RenderConduit;
import WayofTime.alchemicalWizardry.common.renderer.block.RenderCrystalBelljar;
@ -110,7 +110,7 @@ public class ClientProxy extends CommonProxy
@Override
public void registerPostSideObjects()
{
BUEntries entries = new BUEntries();
// BUEntries entries = new BUEntries();
// entries.postInit();
}
@ -193,5 +193,6 @@ public class ClientProxy extends CommonProxy
FMLCommonHandler.instance().bus().register(ob);
MinecraftForge.EVENT_BUS.register(ob);
KeyBindings.init();
MinecraftForge.EVENT_BUS.register(new ScrollHelper());
}
}

View file

@ -47,6 +47,11 @@ public class NEIBloodOrbShapedHandler extends ShapedRecipeHandler {
PositionedStack stack = new PositionedStack(orbs, 25 + x * 18, 6 + y * 18, false);
stack.setMaxSize(1);
ingredients.add(stack);
}else if(o instanceof List)
{
PositionedStack stack = new PositionedStack((List)o, 25 + x * 18, 6 + y * 18, false);
stack.setMaxSize(1);
ingredients.add(stack);
}
}
}

View file

@ -44,6 +44,11 @@ public class NEIBloodOrbShapelessHandler extends ShapelessRecipeHandler {
PositionedStack stack = new PositionedStack(orbs, 25 + stackorder[ingred][0] * 18, 6 + stackorder[ingred][1] * 18);
stack.setMaxSize(1);
ingredients.add(stack);
}else if(o instanceof List)
{
PositionedStack stack = new PositionedStack((List)o, 25 + stackorder[ingred][0] * 18, 6 + stackorder[ingred][1] * 18);
stack.setMaxSize(1);
ingredients.add(stack);
}
}
}

View file

@ -2,17 +2,34 @@ package WayofTime.alchemicalWizardry.common.block;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.block.BlockContainer;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.inventory.IInventory;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.sacrifice.IIncense;
import WayofTime.alchemicalWizardry.common.tileEntity.TECrucible;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockCrucible extends BlockContainer
{
@SideOnly(Side.CLIENT)
private static IIcon topIcon;
@SideOnly(Side.CLIENT)
private static IIcon sideIcon;
@SideOnly(Side.CLIENT)
private static IIcon bottomIcon;
public BlockCrucible()
{
super(Material.anvil);
@ -20,18 +37,70 @@ public class BlockCrucible extends BlockContainer
this.setResistance(1.5f);
this.setCreativeTab(AlchemicalWizardry.tabBloodMagic);
this.setBlockName("blockCrucible");
this.setBlockBounds(0.3125F, 0.0F, 0.3125F, 0.6875F, 0.625F, 0.6875F);
}
@Override
public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int x, int y, int z)
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int idk, float what, float these, float are)
{
return null;
TECrucible tileEntity = (TECrucible) world.getTileEntity(x, y, z);
if (tileEntity == null || player.isSneaking())
{
return false;
}
ItemStack playerItem = player.getCurrentEquippedItem();
if (tileEntity.getStackInSlot(0) == null && playerItem != null && playerItem.getItem() instanceof IIncense)
{
ItemStack newItem = playerItem.copy();
newItem.stackSize = 1;
--playerItem.stackSize;
tileEntity.setInventorySlotContents(0, newItem);
// } else if (tileEntity.getStackInSlot(0) != null && playerItem == null) //Disabled currently
// {
// player.inventory.addItemStackToInventory(tileEntity.getStackInSlot(0));
// tileEntity.setInventorySlotContents(0, null);
}
world.markBlockForUpdate(x, y, z);
return true;
}
@Override
@SideOnly(Side.CLIENT)
public void registerBlockIcons(IIconRegister iconRegister)
{
this.topIcon = iconRegister.registerIcon("AlchemicalWizardry:Crucible_Top");
this.sideIcon = iconRegister.registerIcon("AlchemicalWizardry:Crucible_Side");
this.bottomIcon = iconRegister.registerIcon("AlchemicalWizardry:Crucible_Bottom");
}
@Override
@SideOnly(Side.CLIENT)
public IIcon getIcon(int side, int meta)
{
switch (side)
{
case 0:
return bottomIcon;
case 1:
return topIcon;
default:
return sideIcon;
}
}
// @Override
// public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int x, int y, int z)
// {
// return null;
// }
@Override
public void setBlockBoundsBasedOnState(IBlockAccess world, int x, int y, int z)
{
this.setBlockBounds(0.4F, 0.0F, 0.4F, 0.6F, 0.6F, 0.6F);
this.setBlockBounds(0.3125F, 0.0F, 0.3125F, 0.6875F, 0.625F, 0.6875F);
}
@Override
@ -61,4 +130,68 @@ public class BlockCrucible extends BlockContainer
tile.spawnClientParticle(world, x, y, z, rand);
}
}
@Override
public void breakBlock(World world, int x, int y, int z, Block par5, int par6)
{
dropItems(world, x, y, z);
super.breakBlock(world, x, y, z, par5, par6);
}
@Override
public boolean hasComparatorInputOverride()
{
return true;
}
@Override
public int getComparatorInputOverride(World world, int x, int y, int z, int meta)
{
TileEntity tile = world.getTileEntity(x, y, z);
if (tile instanceof TECrucible)
{
return ((TECrucible) tile).getRSPowerOutput();
}
return 15;
}
private void dropItems(World world, int x, int y, int z)
{
Random rand = new Random();
TileEntity tileEntity = world.getTileEntity(x, y, z);
if (!(tileEntity instanceof IInventory))
{
return;
}
IInventory inventory = (IInventory) tileEntity;
for (int i = 0; i < inventory.getSizeInventory(); i++)
{
ItemStack item = inventory.getStackInSlot(i);
if (item != null && item.stackSize > 0)
{
float rx = rand.nextFloat() * 0.8F + 0.1F;
float ry = rand.nextFloat() * 0.8F + 0.1F;
float rz = rand.nextFloat() * 0.8F + 0.1F;
EntityItem entityItem = new EntityItem(world,
x + rx, y + ry, z + rz,
new ItemStack(item.getItem(), item.stackSize, item.getItemDamage()));
if (item.hasTagCompound())
{
entityItem.getEntityItem().setTagCompound((NBTTagCompound) item.getTagCompound().copy());
}
float factor = 0.05F;
entityItem.motionX = rand.nextGaussian() * factor;
entityItem.motionY = rand.nextGaussian() * factor + 0.2F;
entityItem.motionZ = rand.nextGaussian() * factor;
world.spawnEntityInWorld(entityItem);
item.stackSize = 0;
}
}
}
}

View file

@ -344,7 +344,7 @@ public class BUEntries
this.registerCategory(BUEntries.categoryTest, EntryRegistry.test, BookParser.parseTextFile("/assets/alchemicalwizardryBooks/books/book.txt"));
// this.registerCategory(BUEntries.categoryTest, EntryRegistry.test, BookParser.parseTextFile("/assets/alchemicalwizardryBooks/books/book.txt"));
}
public void registerCategory(Category cat, HashMap<String, Entry> entryMap, List<Entry> entries)

View file

@ -5,18 +5,21 @@ import java.util.ArrayList;
import java.util.List;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.IRecipe;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.StatCollector;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.ModBlocks;
import WayofTime.alchemicalWizardry.ModItems;
import WayofTime.alchemicalWizardry.api.guide.OrbRecipeRenderer;
import WayofTime.alchemicalWizardry.api.guide.PageAltarRecipe;
import WayofTime.alchemicalWizardry.api.guide.PageOrbRecipe;
import WayofTime.alchemicalWizardry.common.guide.RecipeHolder;
import amerifrance.guideapi.api.GuideRegistry;
import amerifrance.guideapi.api.abstraction.CategoryAbstract;
import amerifrance.guideapi.api.abstraction.EntryAbstract;
import amerifrance.guideapi.api.abstraction.IPage;
import amerifrance.guideapi.api.base.Book;
import amerifrance.guideapi.api.util.BookBuilder;
import amerifrance.guideapi.api.util.PageHelper;
import amerifrance.guideapi.categories.CategoryItemStack;
import amerifrance.guideapi.entries.EntryUniText;
@ -31,10 +34,24 @@ public class BloodMagicGuide
public static void registerGuide()
{
registerArchitectBook();
bloodMagicGuide = new Book(categories, "guide.BloodMagic.book.title", "guide.BloodMagic.welcomeMessage", "guide.BloodMagic.book.name", new Color(190, 10, 0));
registerRitualBook();
registerDemonBook();
registerSpellBook();
registerAlchemyBook();
BookBuilder bmBookBuilder = new BookBuilder();
bmBookBuilder.setCategories(categories).setUnlocBookTitle("guide.BloodMagic.book.title").setUnlocWelcomeMessage("guide.BloodMagic.welcomeMessage").setUnlocDisplayName("guide.BloodMagic.book.name").setBookColor(new Color(190, 10, 0));
// bloodMagicGuide = new Book(categories, "guide.BloodMagic.book.title", "guide.BloodMagic.welcomeMessage", "guide.BloodMagic.book.name", new Color(190, 10, 0));
bloodMagicGuide = bmBookBuilder.build();
GuideRegistry.registerBook(bloodMagicGuide);
}
public static PageIRecipe getOrbPageForRecipe(IRecipe recipe)
{
return new PageIRecipe(recipe, new OrbRecipeRenderer(recipe));
}
public static void registerArchitectBook()
{
List<EntryAbstract> entries = new ArrayList();
@ -61,18 +78,18 @@ public class BloodMagicGuide
entries.add(new EntryUniText(blankSlatePages, "guide.BloodMagic.entryName.architect.blankSlate"));
ArrayList<IPage> divinationSigilPages = new ArrayList();
divinationSigilPages.add(new PageOrbRecipe(RecipeHolder.divinationSigilRecipe));
divinationSigilPages.add(getOrbPageForRecipe(RecipeHolder.divinationSigilRecipe));
divinationSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.divination")));
entries.add(new EntryUniText(divinationSigilPages, "guide.BloodMagic.entryName.architect.divination"));
ArrayList<IPage> waterSigilPages = new ArrayList();
waterSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.waterSigil.1")));
waterSigilPages.add(new PageOrbRecipe(RecipeHolder.waterSigilRecipe));
waterSigilPages.add(getOrbPageForRecipe(RecipeHolder.waterSigilRecipe));
waterSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.waterSigil.2")));
entries.add(new EntryUniText(waterSigilPages, "guide.BloodMagic.entryName.architect.waterSigil"));
ArrayList<IPage> lavaCrystalPages = new ArrayList();
lavaCrystalPages.add(new PageOrbRecipe(RecipeHolder.lavaCrystalRecipe));
lavaCrystalPages.add(getOrbPageForRecipe(RecipeHolder.lavaCrystalRecipe));
lavaCrystalPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.lavaCrystal")));
entries.add(new EntryUniText(lavaCrystalPages, "guide.BloodMagic.entryName.architect.lavaCrystal"));
@ -86,7 +103,7 @@ public class BloodMagicGuide
entries.add(new EntryUniText(lavaSigilPages, "guide.BloodMagic.entryName.architect.lavaSigil"));
ArrayList<IPage> blankRunePages = new ArrayList();
blankRunePages.add(new PageOrbRecipe(RecipeHolder.blankRuneRecipe));
blankRunePages.add(getOrbPageForRecipe(RecipeHolder.blankRuneRecipe));
blankRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.blankRunes.1")));
blankRunePages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/altars/T2.png"), true));
blankRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.blankRunes.2")));
@ -103,17 +120,17 @@ public class BloodMagicGuide
entries.add(new EntryUniText(apprenticeOrbPages, "guide.BloodMagic.entryName.architect.apprenticeOrb"));
ArrayList<IPage> voidSigilPages = new ArrayList();
voidSigilPages.add(new PageOrbRecipe(RecipeHolder.voidSigilRecipe));
voidSigilPages.add(getOrbPageForRecipe(RecipeHolder.voidSigilRecipe));
voidSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.voidSigil")));
entries.add(new EntryUniText(voidSigilPages, "guide.BloodMagic.entryName.architect.voidSigil"));
ArrayList<IPage> airSigilPages = new ArrayList();
airSigilPages.add(new PageOrbRecipe(RecipeHolder.airSigilRecipe));
airSigilPages.add(getOrbPageForRecipe(RecipeHolder.airSigilRecipe));
airSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.airSigil")));
entries.add(new EntryUniText(airSigilPages, "guide.BloodMagic.entryName.architect.airSigil"));
ArrayList<IPage> sightSigilPages = new ArrayList();
sightSigilPages.add(new PageOrbRecipe(RecipeHolder.sightSigilRecipe));
sightSigilPages.add(getOrbPageForRecipe(RecipeHolder.sightSigilRecipe));
sightSigilPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.sightSigil")));
entries.add(new EntryUniText(sightSigilPages, "guide.BloodMagic.entryName.architect.sightSigil"));
@ -122,7 +139,7 @@ public class BloodMagicGuide
entries.add(new EntryUniText(advancedAltarPages, "guide.BloodMagic.entryName.architect.advancedAltar"));
ArrayList<IPage> fastMinerPages = new ArrayList();
fastMinerPages.add(new PageOrbRecipe(RecipeHolder.fastMinerRecipe));
fastMinerPages.add(getOrbPageForRecipe(RecipeHolder.fastMinerRecipe));
fastMinerPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.fastMiner")));
entries.add(new EntryUniText(fastMinerPages, "guide.BloodMagic.entryName.architect.fastMiner"));
@ -131,7 +148,7 @@ public class BloodMagicGuide
entries.add(new EntryUniText(soulFrayPages, "guide.BloodMagic.entryName.architect.soulFray"));
ArrayList<IPage> greenGrovePages = new ArrayList();
greenGrovePages.add(new PageOrbRecipe(RecipeHolder.greenGroveRecipe));
greenGrovePages.add(getOrbPageForRecipe(RecipeHolder.greenGroveRecipe));
greenGrovePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.greenGrove")));
entries.add(new EntryUniText(greenGrovePages, "guide.BloodMagic.entryName.architect.greenGrove"));
@ -141,9 +158,9 @@ public class BloodMagicGuide
entries.add(new EntryUniText(daggerPages, "guide.BloodMagic.entryName.architect.dagger"));
ArrayList<IPage> sacrificePages = new ArrayList();
sacrificePages.add(new PageIRecipe(RecipeHolder.selfSacrificeRuneRecipe));
sacrificePages.add(getOrbPageForRecipe(RecipeHolder.selfSacrificeRuneRecipe));
sacrificePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.sacrifice.1")));
sacrificePages.add(new PageIRecipe(RecipeHolder.sacrificeRuneRecipe));
sacrificePages.add(getOrbPageForRecipe(RecipeHolder.sacrificeRuneRecipe));
sacrificePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.sacrifice.2")));
entries.add(new EntryUniText(sacrificePages, "guide.BloodMagic.entryName.architect.sacrifice"));
@ -167,40 +184,40 @@ public class BloodMagicGuide
entries.add(new EntryUniText(magicianOrbPages, "guide.BloodMagic.entryName.architect.magicianOrb"));
ArrayList<IPage> newRunePages = new ArrayList();
newRunePages.add(new PageOrbRecipe(RecipeHolder.capacityRuneRecipe));
newRunePages.add(getOrbPageForRecipe(RecipeHolder.capacityRuneRecipe));
newRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.newRune.1")));
newRunePages.add(new PageOrbRecipe(RecipeHolder.dislocationRuneRecipe));
newRunePages.add(getOrbPageForRecipe(RecipeHolder.dislocationRuneRecipe));
newRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.newRune.2")));
entries.add(new EntryUniText(newRunePages, "guide.BloodMagic.entryName.architect.newRune"));
ArrayList<IPage> magnetismPages = new ArrayList();
magnetismPages.add(new PageOrbRecipe(RecipeHolder.magnetismSigilRecipe));
magnetismPages.add(getOrbPageForRecipe(RecipeHolder.magnetismSigilRecipe));
magnetismPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.magnetism")));
entries.add(new EntryUniText(magnetismPages, "guide.BloodMagic.entryName.architect.magnetism"));
ArrayList<IPage> phantomBridgePages = new ArrayList();
phantomBridgePages.add(new PageOrbRecipe(RecipeHolder.phantomBridgeRecipe));
phantomBridgePages.add(getOrbPageForRecipe(RecipeHolder.phantomBridgeRecipe));
phantomBridgePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.phantomBridge")));
entries.add(new EntryUniText(phantomBridgePages, "guide.BloodMagic.entryName.architect.phantomBridge"));
ArrayList<IPage> holdingPages = new ArrayList();
holdingPages.add(new PageOrbRecipe(RecipeHolder.holdingSigilRecipe));
holdingPages.add(getOrbPageForRecipe(RecipeHolder.holdingSigilRecipe));
holdingPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.holding")));
entries.add(new EntryUniText(holdingPages, "guide.BloodMagic.entryName.architect.holding"));
ArrayList<IPage> elementalAffinityPages = new ArrayList();
elementalAffinityPages.add(new PageOrbRecipe(RecipeHolder.affinitySigilRecipe));
elementalAffinityPages.add(getOrbPageForRecipe(RecipeHolder.affinitySigilRecipe));
elementalAffinityPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.elementalAffinity")));
entries.add(new EntryUniText(elementalAffinityPages, "guide.BloodMagic.entryName.architect.elementalAffinity"));
ArrayList<IPage> ritualStonesPages = new ArrayList();
ritualStonesPages.add(new PageOrbRecipe(RecipeHolder.ritualStoneRecipe));
ritualStonesPages.add(new PageOrbRecipe(RecipeHolder.masterStoneRecipe));
ritualStonesPages.add(getOrbPageForRecipe(RecipeHolder.ritualStoneRecipe));
ritualStonesPages.add(getOrbPageForRecipe(RecipeHolder.masterStoneRecipe));
ritualStonesPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.ritualStones")));
entries.add(new EntryUniText(ritualStonesPages, "guide.BloodMagic.entryName.architect.ritualStones"));
ArrayList<IPage> bloodLampPages = new ArrayList();
bloodLampPages.add(new PageOrbRecipe(RecipeHolder.bloodLampRecipe));
bloodLampPages.add(getOrbPageForRecipe(RecipeHolder.bloodLampRecipe));
bloodLampPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.bloodLamp")));
entries.add(new EntryUniText(bloodLampPages, "guide.BloodMagic.entryName.architect.bloodLamp"));
@ -208,7 +225,7 @@ public class BloodMagicGuide
boundArmourPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.boundArmour.1")));
boundArmourPages.add(new PageIRecipe(RecipeHolder.emptySocketRecipe));
boundArmourPages.add(new PageAltarRecipe(RecipeHolder.filledSocketRecipe));
boundArmourPages.add(new PageOrbRecipe(RecipeHolder.soulForgeRecipe));
boundArmourPages.add(getOrbPageForRecipe(RecipeHolder.soulForgeRecipe));
boundArmourPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.boundArmour.2")));
entries.add(new EntryUniText(boundArmourPages, "guide.BloodMagic.entryName.architect.boundArmour"));
@ -247,17 +264,17 @@ public class BloodMagicGuide
entries.add(new EntryUniText(masterOrbPages, "guide.BloodMagic.entryName.architect.masterOrb"));
ArrayList<IPage> whirlwindPages = new ArrayList();
whirlwindPages.add(new PageOrbRecipe(RecipeHolder.whirlwindSigilRecipe));
whirlwindPages.add(getOrbPageForRecipe(RecipeHolder.whirlwindSigilRecipe));
whirlwindPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.whirlwind")));
entries.add(new EntryUniText(whirlwindPages, "guide.BloodMagic.entryName.architect.whirlwind"));
ArrayList<IPage> compressionPages = new ArrayList();
compressionPages.add(new PageOrbRecipe(RecipeHolder.compressionSigilRecipe));
compressionPages.add(getOrbPageForRecipe(RecipeHolder.compressionSigilRecipe));
compressionPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.compression")));
entries.add(new EntryUniText(compressionPages, "guide.BloodMagic.entryName.architect.compression"));
ArrayList<IPage> severancePages = new ArrayList();
severancePages.add(new PageOrbRecipe(RecipeHolder.enderSeveranceSigilRecipe));
severancePages.add(getOrbPageForRecipe(RecipeHolder.enderSeveranceSigilRecipe));
severancePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.severance")));
entries.add(new EntryUniText(severancePages, "guide.BloodMagic.entryName.architect.severance"));
@ -268,17 +285,17 @@ public class BloodMagicGuide
entries.add(new EntryUniText(teleposerPages, "guide.BloodMagic.entryName.architect.teleposer"));
ArrayList<IPage> suppressionPages = new ArrayList();
suppressionPages.add(new PageOrbRecipe(RecipeHolder.suppressionSigilRecipe));
suppressionPages.add(getOrbPageForRecipe(RecipeHolder.suppressionSigilRecipe));
suppressionPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.suppression")));
entries.add(new EntryUniText(suppressionPages, "guide.BloodMagic.entryName.architect.suppression"));
ArrayList<IPage> superiorCapacityPages = new ArrayList();
superiorCapacityPages.add(new PageOrbRecipe(RecipeHolder.superiorCapacityRecipe));
superiorCapacityPages.add(getOrbPageForRecipe(RecipeHolder.superiorCapacityRecipe));
superiorCapacityPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.superiorCapacity")));
entries.add(new EntryUniText(superiorCapacityPages, "guide.BloodMagic.entryName.architect.superiorCapacity"));
ArrayList<IPage> orbRunePages = new ArrayList();
orbRunePages.add(new PageOrbRecipe(RecipeHolder.orbRuneRecipe));
orbRunePages.add(getOrbPageForRecipe(RecipeHolder.orbRuneRecipe));
orbRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.orbRune")));
entries.add(new EntryUniText(orbRunePages, "guide.BloodMagic.entryName.architect.orbRune"));
@ -306,17 +323,17 @@ public class BloodMagicGuide
entries.add(new EntryUniText(demonicOrbPages, "guide.BloodMagic.entryName.architect.demonicOrb"));
ArrayList<IPage> energyBazookaPages = new ArrayList();
demonicOrbPages.add(new PageOrbRecipe(RecipeHolder.energyBazookaRecipe));
demonicOrbPages.add(getOrbPageForRecipe(RecipeHolder.energyBazookaRecipe));
energyBazookaPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.energyBazooka")));
entries.add(new EntryUniText(energyBazookaPages, "guide.BloodMagic.entryName.architect.energyBazooka"));
ArrayList<IPage> accelerationRunePages = new ArrayList();
demonicOrbPages.add(new PageOrbRecipe(RecipeHolder.accelerationRuneRecipe));
demonicOrbPages.add(getOrbPageForRecipe(RecipeHolder.accelerationRuneRecipe));
accelerationRunePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.accelerationRune")));
entries.add(new EntryUniText(accelerationRunePages, "guide.BloodMagic.entryName.architect.accelerationRune"));
ArrayList<IPage> harvestPages = new ArrayList();
demonicOrbPages.add(new PageOrbRecipe(RecipeHolder.harvestSigilRecipe));
demonicOrbPages.add(getOrbPageForRecipe(RecipeHolder.harvestSigilRecipe));
harvestPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.architect.harvest")));
entries.add(new EntryUniText(harvestPages, "guide.BloodMagic.entryName.architect.harvest"));
@ -337,4 +354,483 @@ public class BloodMagicGuide
categories.add(new CategoryItemStack(entries, "guide.BloodMagic.category.architect", new ItemStack(ModItems.divinationSigil)));
}
public static void registerRitualBook()
{
List<EntryAbstract> entries = new ArrayList();
// ArrayList<IPage> testPages = new ArrayList();
// testPages.add(PageRitualMultiBlock.getPageForRitual("AW031Convocation"));
// entries.add(new EntryUniText(testPages, "Test page"));
ArrayList<IPage> introPages = new ArrayList();
introPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.intro")));
entries.add(new EntryUniText(introPages, "guide.BloodMagic.entryName.rituals.intro"));
ArrayList<IPage> weakRitualPages = new ArrayList();
weakRitualPages.add(getOrbPageForRecipe(RecipeHolder.weakRitualStoneRecipe));
weakRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.weakRitual")));
entries.add(new EntryUniText(weakRitualPages, "guide.BloodMagic.entryName.rituals.weakRitual"));
ArrayList<IPage> ritualsPages = new ArrayList();
ritualsPages.add(getOrbPageForRecipe(RecipeHolder.ritualStoneRecipe));
ritualsPages.add(getOrbPageForRecipe(RecipeHolder.masterStoneRecipe));
ritualsPages.add(new PageAltarRecipe(RecipeHolder.waterScribeTool));
ritualsPages.add(new PageAltarRecipe(RecipeHolder.fireScribeTool));
ritualsPages.add(new PageAltarRecipe(RecipeHolder.earthScribeTool));
ritualsPages.add(new PageAltarRecipe(RecipeHolder.airScribeTool));
ritualsPages.add(new PageIRecipe(RecipeHolder.ritualDiviner1Recipe));
ritualsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.rituals")));
ritualsPages.add(new PageAltarRecipe(RecipeHolder.weakActivationRecipe));
entries.add(new EntryUniText(ritualsPages, "guide.BloodMagic.entryName.rituals.rituals"));
ArrayList<IPage> waterRitualPages = new ArrayList();
waterRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Water.png"), true));
waterRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.waterRitual")));
entries.add(new EntryUniText(waterRitualPages, "guide.BloodMagic.entryName.rituals.waterRitual"));
ArrayList<IPage> lavaRitualPages = new ArrayList();
lavaRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Lava.png"), true));
lavaRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.lavaRitual")));
entries.add(new EntryUniText(lavaRitualPages, "guide.BloodMagic.entryName.rituals.lavaRitual"));
ArrayList<IPage> groveRitualPages = new ArrayList();
groveRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/GreenGrove.png"), true));
groveRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.groveRitual")));
entries.add(new EntryUniText(groveRitualPages, "guide.BloodMagic.entryName.rituals.groveRitual"));
ArrayList<IPage> interdictionRitualPages = new ArrayList();
interdictionRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Interdiction.png"), true));
interdictionRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.interdictionRitual")));
entries.add(new EntryUniText(interdictionRitualPages, "guide.BloodMagic.entryName.rituals.interdictionRitual"));
ArrayList<IPage> containmentRitualPages = new ArrayList();
containmentRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Containment.png"), true));
containmentRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.containmentRitual")));
entries.add(new EntryUniText(containmentRitualPages, "guide.BloodMagic.entryName.rituals.containmentRitual"));
ArrayList<IPage> bindingRitualPages = new ArrayList();
bindingRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Binding.png"), true));
bindingRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.bindingRitual")));
entries.add(new EntryUniText(bindingRitualPages, "guide.BloodMagic.entryName.rituals.bindingRitual"));
ArrayList<IPage> beastModePages = new ArrayList();
beastModePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.beastMode")));
entries.add(new EntryUniText(beastModePages, "guide.BloodMagic.entryName.rituals.beastMode"));
ArrayList<IPage> unbindingRitualPages = new ArrayList();
unbindingRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Unbinding.png"), true));
unbindingRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.unbindingRitual")));
entries.add(new EntryUniText(unbindingRitualPages, "guide.BloodMagic.entryName.rituals.unbindingRitual"));
ArrayList<IPage> jumpRitualPages = new ArrayList();
jumpRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Jump.png"), true));
jumpRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.jumpRitual")));
entries.add(new EntryUniText(jumpRitualPages, "guide.BloodMagic.entryName.rituals.jumpRitual"));
ArrayList<IPage> duskInkPages = new ArrayList();
duskInkPages.add(new PageAltarRecipe(RecipeHolder.duskRecipe));
duskInkPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.duskInk")));
entries.add(new EntryUniText(duskInkPages, "guide.BloodMagic.entryName.rituals.duskInk"));
ArrayList<IPage> magnetismRitualPages = new ArrayList();
magnetismRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Magnetism.png"), true));
magnetismRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.magnetismRitual")));
entries.add(new EntryUniText(magnetismRitualPages, "guide.BloodMagic.entryName.rituals.magnetismRitual"));
ArrayList<IPage> crusherRitualPages = new ArrayList();
crusherRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Crusher.png"), true));
crusherRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.crusherRitual")));
entries.add(new EntryUniText(crusherRitualPages, "guide.BloodMagic.entryName.rituals.crusherRitual"));
ArrayList<IPage> speedRitualPages = new ArrayList();
speedRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Speed.png"), true));
speedRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.speedRitual")));
entries.add(new EntryUniText(speedRitualPages, "guide.BloodMagic.entryName.rituals.speedRitual"));
ArrayList<IPage> shepherdRitualPages = new ArrayList();
shepherdRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/AnimalGrowth.png"), true));
shepherdRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.shepherdRitual")));
entries.add(new EntryUniText(shepherdRitualPages, "guide.BloodMagic.entryName.rituals.shepherdRitual"));
ArrayList<IPage> darkMagicPages = new ArrayList();
darkMagicPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.darkMagic")));
entries.add(new EntryUniText(darkMagicPages, "guide.BloodMagic.entryName.rituals.darkMagic"));
ArrayList<IPage> knifeAndSufferingRitualPages = new ArrayList();
knifeAndSufferingRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/WellOfSuffering.png"), true));
knifeAndSufferingRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.knifeAndSufferingRitual.1")));
knifeAndSufferingRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/FeatheredKnife.png"), true));
knifeAndSufferingRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.knifeAndSufferingRitual.2")));
entries.add(new EntryUniText(knifeAndSufferingRitualPages, "guide.BloodMagic.entryName.rituals.knifeAndSufferingRitual"));
ArrayList<IPage> regenerationRitualPages = new ArrayList();
regenerationRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Regeneration.png"), true));
regenerationRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.regenerationRitual")));
entries.add(new EntryUniText(regenerationRitualPages, "guide.BloodMagic.entryName.rituals.regenerationRitual"));
ArrayList<IPage> harvestFestivalPages = new ArrayList();
harvestFestivalPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.harvestFestival")));
entries.add(new EntryUniText(harvestFestivalPages, "guide.BloodMagic.entryName.rituals.harvestFestival"));
ArrayList<IPage> thenThereWereFivePages = new ArrayList();
thenThereWereFivePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.thenThereWereFive")));
entries.add(new EntryUniText(thenThereWereFivePages, "guide.BloodMagic.entryName.rituals.thenThereWereFive"));
ArrayList<IPage> alchemyRitualPages = new ArrayList();
alchemyRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Alchemy.png"), true));
alchemyRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.alchemyRitual")));
entries.add(new EntryUniText(alchemyRitualPages, "guide.BloodMagic.entryName.rituals.alchemyRitual"));
ArrayList<IPage> domeRitualPages = new ArrayList();
domeRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Dome.png"), true));
domeRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.domeRitual")));
entries.add(new EntryUniText(domeRitualPages, "guide.BloodMagic.entryName.rituals.domeRitual"));
ArrayList<IPage> awakenedCrystalPages = new ArrayList();
awakenedCrystalPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.awakenedCrystal")));
entries.add(new EntryUniText(awakenedCrystalPages, "guide.BloodMagic.entryName.rituals.awakenedCrystal"));
ArrayList<IPage> featheredEarthRitualPages = new ArrayList();
featheredEarthRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/FeatheredEarth.png"), true));
featheredEarthRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.featheredEarthRitual")));
entries.add(new EntryUniText(featheredEarthRitualPages, "guide.BloodMagic.entryName.rituals.featheredEarthRitual"));
ArrayList<IPage> gaiaRitualPages = new ArrayList();
gaiaRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Gaia.png"), true));
gaiaRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.gaiaRitual")));
entries.add(new EntryUniText(gaiaRitualPages, "guide.BloodMagic.entryName.rituals.gaiaRitual"));
ArrayList<IPage> condorRitualPages = new ArrayList();
condorRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Flight.png"), true));
condorRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.condorRitual")));
entries.add(new EntryUniText(condorRitualPages, "guide.BloodMagic.entryName.rituals.condorRitual"));
ArrayList<IPage> meteorRitualPages = new ArrayList();
meteorRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Meteor.png"), true));
meteorRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.meteorRitual")));
entries.add(new EntryUniText(meteorRitualPages, "guide.BloodMagic.entryName.rituals.meteorRitual"));
ArrayList<IPage> expulsionRitualPages = new ArrayList();
expulsionRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Expulsion.png"), true));
expulsionRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.expulsionRitual")));
entries.add(new EntryUniText(expulsionRitualPages, "guide.BloodMagic.entryName.rituals.expulsionRitual"));
ArrayList<IPage> costOfProgressPages = new ArrayList();
costOfProgressPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.costOfProgress.1")));
costOfProgressPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.costOfProgress.2")));
entries.add(new EntryUniText(costOfProgressPages, "guide.BloodMagic.entryName.rituals.costOfProgress"));
ArrayList<IPage> zephyrRitualPages = new ArrayList();
zephyrRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Zephyr.png"), true));
zephyrRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.zephyrRitual")));
entries.add(new EntryUniText(zephyrRitualPages, "guide.BloodMagic.entryName.rituals.zephyrRitual"));
ArrayList<IPage> harvestRitualPages = new ArrayList();
harvestRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Harvest.png"), true));
harvestRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.harvestRitual")));
entries.add(new EntryUniText(harvestRitualPages, "guide.BloodMagic.entryName.rituals.harvestRitual"));
ArrayList<IPage> eternalSoulRitualPages = new ArrayList();
eternalSoulRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/EternalSoul.png"), true));
eternalSoulRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.eternalSoulRitual")));
entries.add(new EntryUniText(eternalSoulRitualPages, "guide.BloodMagic.entryName.rituals.eternalSoulRitual"));
ArrayList<IPage> ellipsoidRitualPages = new ArrayList();
ellipsoidRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Ellipsoid.png"), true));
ellipsoidRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.ellipsoidRitual")));
entries.add(new EntryUniText(ellipsoidRitualPages, "guide.BloodMagic.entryName.rituals.ellipsoidRitual"));
ArrayList<IPage> evaporationRitualPages = new ArrayList();
evaporationRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Evaporation.png"), true));
evaporationRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.evaporationRitual")));
entries.add(new EntryUniText(evaporationRitualPages, "guide.BloodMagic.entryName.rituals.evaporationRitual"));
ArrayList<IPage> sacrosanctityRitualPages = new ArrayList();
sacrosanctityRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Sacrosanctity.png"), true));
sacrosanctityRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.sacrosanctityRitual")));
entries.add(new EntryUniText(sacrosanctityRitualPages, "guide.BloodMagic.entryName.rituals.sacrosanctityRitual"));
ArrayList<IPage> evilRitualPages = new ArrayList();
evilRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/VeilOfEvil.png"), true));
evilRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.evilRitual")));
entries.add(new EntryUniText(evilRitualPages, "guide.BloodMagic.entryName.rituals.evilRitual"));
ArrayList<IPage> stomachRitualPages = new ArrayList();
stomachRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Stomach.png"), true));
stomachRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.stomachRitual")));
entries.add(new EntryUniText(stomachRitualPages, "guide.BloodMagic.entryName.rituals.stomachRitual"));
ArrayList<IPage> reagentEffectsRitualPages = new ArrayList();
for(int i=1; i<=24; i++)
{
reagentEffectsRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.reagentEffects." + i)));
}
entries.add(new EntryUniText(reagentEffectsRitualPages, "guide.BloodMagic.entryName.rituals.reagentEffects"));
ArrayList<IPage> conclaveOfMagesPages = new ArrayList();
conclaveOfMagesPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.conclaveOfMages")));
entries.add(new EntryUniText(conclaveOfMagesPages, "guide.BloodMagic.entryName.rituals.conclaveOfMages"));
ArrayList<IPage> forbiddenParadisePages = new ArrayList();
forbiddenParadisePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.forbiddenParadise")));
entries.add(new EntryUniText(forbiddenParadisePages, "guide.BloodMagic.entryName.rituals.forbiddenParadise"));
ArrayList<IPage> convocationRitualPages = new ArrayList();
convocationRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/Convocation.png"), true));
convocationRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.convocationRitual")));
entries.add(new EntryUniText(convocationRitualPages, "guide.BloodMagic.entryName.rituals.convocationRitual"));
ArrayList<IPage> longHaulPages = new ArrayList();
longHaulPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.longHaul")));
entries.add(new EntryUniText(longHaulPages, "guide.BloodMagic.entryName.rituals.longHaul"));
ArrayList<IPage> phantomHandsRitualPages = new ArrayList();
phantomHandsRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/PhantomHands.png"), true));
phantomHandsRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.phantomHandsRitual")));
entries.add(new EntryUniText(phantomHandsRitualPages, "guide.BloodMagic.entryName.rituals.phantomHandsRitual"));
ArrayList<IPage> anvilRitualPages = new ArrayList();
anvilRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/BeatingAnvil.png"), true));
anvilRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.anvilRitual")));
entries.add(new EntryUniText(anvilRitualPages, "guide.BloodMagic.entryName.rituals.anvilRitual"));
ArrayList<IPage> dawnInkPages = new ArrayList();
dawnInkPages.add(new PageAltarRecipe(RecipeHolder.dawnRecipe));
dawnInkPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.dawnInk")));
entries.add(new EntryUniText(dawnInkPages, "guide.BloodMagic.entryName.rituals.dawnInk"));
ArrayList<IPage> symmetryRitualPages = new ArrayList();
symmetryRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/SymmetryOmega.png"), true));
symmetryRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.symmetryRitual")));
entries.add(new EntryUniText(symmetryRitualPages, "guide.BloodMagic.entryName.rituals.symmetryRitual"));
ArrayList<IPage> stallingRitualPages = new ArrayList();
stallingRitualPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/rituals/StallingOmega.png"), true));
stallingRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.stallingRitual")));
entries.add(new EntryUniText(stallingRitualPages, "guide.BloodMagic.entryName.rituals.stallingRitual"));
ArrayList<IPage> newMoonRitualPages = new ArrayList();
newMoonRitualPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.rituals.newMoonRitual")));
entries.add(new EntryUniText(newMoonRitualPages, "guide.BloodMagic.entryName.rituals.newMoonRitual"));
categories.add(new CategoryItemStack(entries, "guide.BloodMagic.category.rituals", new ItemStack(ModBlocks.blockMasterStone)));
}
public static void registerDemonBook()
{
List<EntryAbstract> entries = new ArrayList();
ArrayList<IPage> ashesPages = new ArrayList();
ashesPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.ashes")));
entries.add(new EntryUniText(ashesPages, "guide.BloodMagic.entryName.demons.ashes"));
ArrayList<IPage> tamedDemonPages = new ArrayList();
tamedDemonPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.tamedDemon")));
entries.add(new EntryUniText(tamedDemonPages, "guide.BloodMagic.entryName.demons.tamedDemon"));
ArrayList<IPage> futurePages = new ArrayList();
futurePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.future")));
entries.add(new EntryUniText(futurePages, "guide.BloodMagic.entryName.demons.future"));
ArrayList<IPage> knightPages = new ArrayList();
knightPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.knight")));
entries.add(new EntryUniText(knightPages, "guide.BloodMagic.entryName.demons.knight"));
ArrayList<IPage> demonShardPages = new ArrayList();
demonShardPages.addAll(PageHelper.pagesForLongText((StatCollector.translateToLocal("aw.entries.demons.demonShard")), new ItemStack(ModItems.demonBloodShard)));
entries.add(new EntryUniText(demonShardPages, "guide.BloodMagic.entryName.demons.demonShard"));
ArrayList<IPage> demonSummoningPages = new ArrayList();
demonSummoningPages.add(new PageIRecipe(RecipeHolder.arcanePedestalRecipe));
demonSummoningPages.add(new PageIRecipe(RecipeHolder.arcanePlinthRecipe));
demonSummoningPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/demons/Ring1.png"), true));
demonSummoningPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/demons/Ring2.png"), true));
demonSummoningPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.demonSummoning")));
entries.add(new EntryUniText(demonSummoningPages, "guide.BloodMagic.entryName.demons.demonSummoning"));
ArrayList<IPage> keysGatePages = new ArrayList();
for(int i=1; i<=10; i++)
{
keysGatePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.keysGate." + i)));
}
entries.add(new EntryUniText(keysGatePages, "guide.BloodMagic.entryName.demons.keysGate"));
ArrayList<IPage> futurePlansPages = new ArrayList();
futurePlansPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.futurePlans")));
entries.add(new EntryUniText(futurePlansPages, "guide.BloodMagic.entryName.demons.futurePlans"));
ArrayList<IPage> demonInvasionPages = new ArrayList();
demonInvasionPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.demonInvasion")));
entries.add(new EntryUniText(demonInvasionPages, "guide.BloodMagic.entryName.demons.demonInvasion"));
ArrayList<IPage> observationsPages = new ArrayList();
observationsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.demons.observations")));
entries.add(new EntryUniText(observationsPages, "guide.BloodMagic.entryName.demons.observations"));
categories.add(new CategoryItemStack(entries, "guide.BloodMagic.category.demons", new ItemStack(ModItems.demonBloodShard)));
}
public static void registerSpellBook()
{
List<EntryAbstract> entries = new ArrayList();
ArrayList<IPage> demonGirlPages = new ArrayList();
demonGirlPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.demonGirl")));
entries.add(new EntryUniText(demonGirlPages, "guide.BloodMagic.entryName.spells.demonGirl"));
ArrayList<IPage> spellTablePages = new ArrayList();
spellTablePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.spellTable.1")));
spellTablePages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/SimpleSpellTable.png"), true));
spellTablePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.spellTable.2")));
entries.add(new EntryUniText(spellTablePages, "guide.BloodMagic.entryName.spells.spellTable"));
ArrayList<IPage> simpleEffectsPages = new ArrayList();
for(int i=1; i<=11; i++)
{
simpleEffectsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.simpleEffects." + i)));
}
entries.add(new EntryUniText(simpleEffectsPages, "guide.BloodMagic.entryName.spells.simpleEffects"));
ArrayList<IPage> tableAndSkullsPages = new ArrayList();
tableAndSkullsPages.add(new PageAltarRecipe(RecipeHolder.blankSpellRecipe));
tableAndSkullsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.tableAndSkulls.1")));
tableAndSkullsPages.add(getOrbPageForRecipe(RecipeHolder.spellTableRecipe));
tableAndSkullsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.tableAndSkulls.2")));
entries.add(new EntryUniText(tableAndSkullsPages, "guide.BloodMagic.entryName.spells.tableAndSkulls"));
ArrayList<IPage> timePassesPages = new ArrayList();
timePassesPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.timePasses")));
entries.add(new EntryUniText(timePassesPages, "guide.BloodMagic.entryName.spells.timePasses"));
ArrayList<IPage> complexSpellBasicsPages = new ArrayList();
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics.1")));
complexSpellBasicsPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/Paradigm.png"), true));
for(int i=2; i<=6; i++)
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics." + i)));
complexSpellBasicsPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/Effect.png"), true));
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics.7")));
complexSpellBasicsPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/Modifier.png"), true));
for(int i=8; i<=12; i++)
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics." + i)));
complexSpellBasicsPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/Enhancement.png"), true));
for(int i=13; i<=16; i++)
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics." + i)));
complexSpellBasicsPages.add(new PageUnlocImage("", new ResourceLocation("alchemicalwizardry:textures/misc/screenshots/spells/Conduit.png"), true));
complexSpellBasicsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellBasics.17")));
entries.add(new EntryUniText(complexSpellBasicsPages, "guide.BloodMagic.entryName.spells.complexSpellBasics"));
ArrayList<IPage> complexSpellEffectsPages = new ArrayList();
for(int i=1; i<=17; i++)
complexSpellEffectsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.complexSpellEffects." + i)));
entries.add(new EntryUniText(complexSpellEffectsPages, "guide.BloodMagic.entryName.spells.complexSpellEffects"));
ArrayList<IPage> offTopicPages = new ArrayList();
offTopicPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.offTopic")));
entries.add(new EntryUniText(offTopicPages, "guide.BloodMagic.entryName.spells.offTopic"));
ArrayList<IPage> demonicPowerPages = new ArrayList();
demonicPowerPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.spells.demonicPower")));
entries.add(new EntryUniText(demonicPowerPages, "guide.BloodMagic.entryName.spells.demonicPower"));
categories.add(new CategoryItemStack(entries, "guide.BloodMagic.category.spells", new ItemStack(ModItems.itemComplexSpellCrystal)));
}
public static void registerAlchemyBook()
{
List<EntryAbstract> entries = new ArrayList();
ArrayList<IPage> fatedMeetingPages = new ArrayList();
fatedMeetingPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.fatedMeeting")));
entries.add(new EntryUniText(fatedMeetingPages, "guide.BloodMagic.entryName.alchemy.fatedMeeting"));
ArrayList<IPage> firstStepsPages = new ArrayList();
firstStepsPages.add(getOrbPageForRecipe(RecipeHolder.alchemySetRecipe));
firstStepsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.firstSteps")));
entries.add(new EntryUniText(firstStepsPages, "guide.BloodMagic.entryName.alchemy.firstSteps"));
ArrayList<IPage> chemistrySetPages = new ArrayList();
for(int i=1; i<=10; i++)
chemistrySetPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.chemistrySet." + i)));
entries.add(new EntryUniText(chemistrySetPages, "guide.BloodMagic.entryName.alchemy.chemistrySet"));
ArrayList<IPage> incensePages = new ArrayList();
incensePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.incense.1")));
incensePages.add(new PageIRecipe(RecipeHolder.crucibleRecipe));
incensePages.add(new PageIRecipe(RecipeHolder.woodAshRecipe));
incensePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.incense.2")));
incensePages.add(getOrbPageForRecipe(RecipeHolder.byrrusRecipe));
incensePages.add(getOrbPageForRecipe(RecipeHolder.livensRecipe));
incensePages.add(getOrbPageForRecipe(RecipeHolder.virRecipe));
incensePages.add(getOrbPageForRecipe(RecipeHolder.purpuraRecipe));
incensePages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.incense.3")));
entries.add(new EntryUniText(incensePages, "guide.BloodMagic.entryName.alchemy.incense"));
ArrayList<IPage> potionsPages = new ArrayList();
potionsPages.add(new PageAltarRecipe(RecipeHolder.flaskRecipe));
potionsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.potions")));
entries.add(new EntryUniText(potionsPages, "guide.BloodMagic.entryName.alchemy.potions"));
ArrayList<IPage> reagentRevolutionPages = new ArrayList();
for(int i=1; i<=8; i++)
reagentRevolutionPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentRevolution." + i)));
entries.add(new EntryUniText(reagentRevolutionPages, "guide.BloodMagic.entryName.alchemy.reagentRevolution"));
ArrayList<IPage> newPotionsPages = new ArrayList();
newPotionsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.newPotions")));
entries.add(new EntryUniText(newPotionsPages, "guide.BloodMagic.entryName.alchemy.newPotions"));
ArrayList<IPage> soulSandPages = new ArrayList();
soulSandPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.soulSand")));
entries.add(new EntryUniText(soulSandPages, "guide.BloodMagic.entryName.alchemy.soulSand"));
ArrayList<IPage> timeGoesByPages = new ArrayList();
timeGoesByPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.timeGoesBy")));
entries.add(new EntryUniText(timeGoesByPages, "guide.BloodMagic.entryName.alchemy.timeGoesBy"));
ArrayList<IPage> catalystsPages = new ArrayList();
catalystsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.catalysts")));
entries.add(new EntryUniText(catalystsPages, "guide.BloodMagic.entryName.alchemy.catalysts"));
ArrayList<IPage> activationCrystalPages = new ArrayList();
activationCrystalPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.activationCrystal")));
entries.add(new EntryUniText(activationCrystalPages, "guide.BloodMagic.entryName.alchemy.activationCrystal"));
ArrayList<IPage> reagentSystemPages = new ArrayList();
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.1")));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.calcinatorRecipe));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.2")));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.belljarRecipe));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.relayRecipe));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.3")));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.4")));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.5")));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.routerRecipe));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.segmenterRecipe));
reagentSystemPages.add(new PageIRecipe(RecipeHolder.cleanserRecipe));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.6")));
reagentSystemPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.reagentSystem.7")));
entries.add(new EntryUniText(reagentSystemPages, "guide.BloodMagic.entryName.alchemy.reagentSystem"));
ArrayList<IPage> magusSecretPages = new ArrayList();
magusSecretPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.magusSecret")));
entries.add(new EntryUniText(magusSecretPages, "guide.BloodMagic.entryName.alchemy.magusSecret"));
ArrayList<IPage> simpleCreationsPages = new ArrayList();
simpleCreationsPages.addAll(PageHelper.pagesForLongText(StatCollector.translateToLocal("aw.entries.alchemy.simpleCreations")));
entries.add(new EntryUniText(simpleCreationsPages, "guide.BloodMagic.entryName.alchemy.simpleCreations"));
categories.add(new CategoryItemStack(entries, "guide.BloodMagic.category.alchemy", new ItemStack(ModItems.alchemyFlask)));
}
}

View file

@ -1,11 +1,15 @@
package WayofTime.alchemicalWizardry.common.entity.mob;
import WayofTime.alchemicalWizardry.ModItems;
import pneumaticCraft.api.PneumaticRegistry;
import cpw.mods.fml.common.Optional;
import net.minecraft.entity.Entity;
import net.minecraft.entity.effect.EntityLightningBolt;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.book.BloodMagicGuide;
import amerifrance.guideapi.api.GuideRegistry;
public class MailOrderEntityItem extends EntityItem
{
@ -47,12 +51,26 @@ public class MailOrderEntityItem extends EntityItem
if(!worldObj.isRemote && this.ticksExisted > 100 && !this.isDead)
{
worldObj.addWeatherEffect(new EntityLightningBolt(worldObj, this.posX, this.posY, this.posZ));
EntityItem entity = new BookEntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(ModItems.itemBloodMagicBook));
entity.lifespan = 6000;
entity.delayBeforeCanPickup = 20;
entity.motionY = 1;
worldObj.spawnEntityInWorld(entity);
if(AlchemicalWizardry.isPneumaticCraftLoaded)
{
this.deliverItemViaDrone(this.posX, this.posY, this.posZ);
}else
{
EntityItem entity = new BookEntityItem(worldObj, this.posX, this.posY, this.posZ, GuideRegistry.getItemStackForBook(BloodMagicGuide.bloodMagicGuide));
entity.lifespan = 6000;
entity.delayBeforeCanPickup = 20;
entity.motionY = 1;
worldObj.spawnEntityInWorld(entity);
}
this.setDead();
}
}
@Optional.Method(modid = "PneumaticCraft")
public void deliverItemViaDrone(double x, double y, double z)
{
PneumaticRegistry.getInstance().deliverItemsAmazonStyle(worldObj, (int)x, (int)y, (int)z, GuideRegistry.getItemStackForBook(BloodMagicGuide.bloodMagicGuide));
}
}

View file

@ -36,6 +36,7 @@ public class RecipeHolder
public static IRecipe phantomBridgeRecipe;
public static IRecipe holdingSigilRecipe;
public static IRecipe affinitySigilRecipe;
public static IRecipe weakRitualStoneRecipe;
public static IRecipe ritualStoneRecipe;
public static IRecipe masterStoneRecipe;
public static IRecipe bloodLampRecipe;
@ -58,7 +59,24 @@ public class RecipeHolder
public static IRecipe accelerationRuneRecipe;
public static IRecipe harvestSigilRecipe;
public static IRecipe crystalCluserRecipe;
public static IRecipe arcanePlinthRecipe;
public static IRecipe arcanePedestalRecipe;
public static IRecipe spellTableRecipe;
public static IRecipe alchemySetRecipe;
public static IRecipe crucibleRecipe;
public static IRecipe woodAshRecipe;
public static IRecipe byrrusRecipe;
public static IRecipe livensRecipe;
public static IRecipe virRecipe;
public static IRecipe purpuraRecipe;
public static IRecipe routerRecipe;
public static IRecipe segmenterRecipe;
public static IRecipe cleanserRecipe;
public static IRecipe calcinatorRecipe;
public static IRecipe belljarRecipe;
public static IRecipe relayRecipe;
public static AltarRecipe weakBloodOrbRecipe;
public static AltarRecipe apprenticeBloodOrbRecipe;
@ -76,6 +94,14 @@ public class RecipeHolder
public static AltarRecipe weakActivationRecipe;
public static AltarRecipe filledSocketRecipe;
public static AltarRecipe teleposerFocusRecipe1;
public static AltarRecipe blankSpellRecipe;
public static AltarRecipe waterScribeTool;
public static AltarRecipe fireScribeTool;
public static AltarRecipe earthScribeTool;
public static AltarRecipe airScribeTool;
public static AltarRecipe duskRecipe;
public static AltarRecipe dawnRecipe;
public static AltarRecipe flaskRecipe;
public static void init()
{
@ -125,6 +151,26 @@ public class RecipeHolder
accelerationRuneRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.bloodRune, 1, 5));
harvestSigilRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemHarvestSigil));
crystalCluserRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockCrystal));
weakRitualStoneRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.imperfectRitualStone));
arcanePlinthRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockPlinth));
arcanePedestalRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockPedestal));
spellTableRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockHomHeart));
alchemySetRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockWritingTable));
crucibleRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockCrucible));
woodAshRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemIncense, 1, 0));
byrrusRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemIncense, 1, 1));
livensRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemIncense, 1, 2));
virRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemIncense, 1, 3));
purpuraRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemIncense, 1, 4));
routerRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemAttunedCrystal));
segmenterRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemTankSegmenter));
cleanserRecipe = getRecipeForItemStack(new ItemStack(ModItems.itemDestinationClearer));
calcinatorRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockAlchemicCalcinator));
belljarRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockCrystalBelljar));
relayRecipe = getRecipeForItemStack(new ItemStack(ModBlocks.blockReagentConduit));
weakBloodOrbRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.weakBloodOrb));
apprenticeBloodOrbRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.apprenticeBloodOrb));
@ -142,6 +188,14 @@ public class RecipeHolder
weakActivationRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.activationCrystal, 1, 0));
filledSocketRecipe = getAltarRecipeForItemStack(new ItemStack(ModBlocks.bloodSocket));
teleposerFocusRecipe1 = getAltarRecipeForItemStack(new ItemStack(ModItems.telepositionFocus));
blankSpellRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.blankSpell));
waterScribeTool = getAltarRecipeForItemStack(new ItemStack(ModItems.waterScribeTool));
fireScribeTool = getAltarRecipeForItemStack(new ItemStack(ModItems.fireScribeTool));
earthScribeTool = getAltarRecipeForItemStack(new ItemStack(ModItems.earthScribeTool));
airScribeTool = getAltarRecipeForItemStack(new ItemStack(ModItems.airScribeTool));
duskRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.duskScribeTool));
dawnRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.dawnScribeTool));
flaskRecipe = getAltarRecipeForItemStack(new ItemStack(ModItems.alchemyFlask));
}
private static IRecipe getRecipeForItemStack(ItemStack stack)

View file

@ -5,19 +5,25 @@ import java.util.List;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.util.StatCollector;
import net.minecraftforge.oredict.OreDictionary;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.ModItems;
import WayofTime.alchemicalWizardry.api.items.ShapelessBloodOrbRecipe;
import WayofTime.alchemicalWizardry.api.sacrifice.IIncense;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class ItemIncense extends Item implements IIncense
{
private static final String[] ITEM_NAMES = new String[]{"Woodash", "Cloves"};
private static final String[] ITEM_NAMES = new String[]{"Woodash", "Byrrus", "Livens", "Viridis", "Purpura"};
@SideOnly(Side.CLIENT)
private IIcon[] icons;
@ -40,9 +46,17 @@ public class ItemIncense extends Item implements IIncense
{
icons = new IIcon[ITEM_NAMES.length];
IIcon baseIcon = iconRegister.registerIcon("AlchemicalWizardry:" + "baseIncenseItem");
for (int i = 0; i < ITEM_NAMES.length; ++i)
{
icons[i] = iconRegister.registerIcon("AlchemicalWizardry:" + "baseIncenseItem" + ITEM_NAMES[i]);
if(this.doesIncenseHaveUniqueTexture(i))
{
icons[i] = iconRegister.registerIcon("AlchemicalWizardry:" + "baseIncenseItem" + ITEM_NAMES[i]);
}else
{
icons[i] = baseIcon;
}
}
}
@ -76,67 +90,131 @@ public class ItemIncense extends Item implements IIncense
list.add(new ItemStack(id, 1, meta));
}
}
@Override
@SideOnly(Side.CLIENT)
public int getColorFromItemStack(ItemStack stack, int pass)
{
if(!this.doesIncenseHaveUniqueTexture(stack.getItemDamage()))
{
EnumIncense inc = EnumIncense.getEnumForIndex(stack.getItemDamage());
return (int)((255*inc.redColour * 256 * 256 + 255*inc.greenColour * 256 + 255*inc.blueColour));
}
return 256 * (256 * 255 + 255) + 255;
}
@Override
public int getMinLevel(ItemStack stack)
{
switch(stack.getItemDamage())
{
case 0:
return 0;
case 1:
return 200;
}
return 0;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).minValue;
}
@Override
public int getMaxLevel(ItemStack stack)
{
switch(stack.getItemDamage())
{
case 0:
return 200;
case 1:
return 500;
}
return 100;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).maxValue;
}
@Override
public int getIncenseDuration(ItemStack stack)
{
return 200;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).incenseDuration;
}
@Override
public float getTickRate(ItemStack stack)
{
switch(stack.getItemDamage())
{
case 0:
return 1.0f;
case 1:
return 0.5f;
}
return 1.0f;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).tickRate;
}
@Override
public float getRedColour(ItemStack stack)
{
return 1.0f;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).redColour;
}
@Override
public float getGreenColour(ItemStack stack)
{
return 0;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).greenColour;
}
@Override
public float getBlueColour(ItemStack stack)
{
return 0;
return EnumIncense.getEnumForIndex(stack.getItemDamage()).blueColour;
}
public boolean doesIncenseHaveUniqueTexture(int meta)
{
return false;
}
public static void registerIncenseRecipes()
{
int WILDCARD = OreDictionary.WILDCARD_VALUE;
ItemStack woodStack = new ItemStack(Blocks.log, 1, WILDCARD);
ItemStack charcoalStack = new ItemStack(Items.coal, 1, 1);
ItemStack leavesStack = new ItemStack(Blocks.leaves, 1, WILDCARD);
ItemStack goldNuggetStack = new ItemStack(Items.gold_nugget, 1, WILDCARD);
ItemStack stringStack = new ItemStack(Items.string, 1, WILDCARD);
ItemStack glowstoneStack = new ItemStack(Items.glowstone_dust, 1, WILDCARD);
ItemStack soulSandStack = new ItemStack(Blocks.soul_sand);
ItemStack gunpowderStack = new ItemStack(Items.gunpowder);
ItemStack fermentedEyeStack = new ItemStack(Items.fermented_spider_eye);
ItemStack quartzStack = new ItemStack(Items.quartz, 1, WILDCARD);
ItemStack blazePowderStack = new ItemStack(Items.blaze_powder);
ItemStack netherwartStack = new ItemStack(Items.nether_wart);
ItemStack fracturedBoneStack = new ItemStack(ModItems.baseAlchemyItems, 1, 5);
ItemStack woodashStack = new ItemStack(ModItems.itemIncense, 1, 0);
GameRegistry.addRecipe(woodashStack, "WWW", "WCW", "WWW", 'W', woodStack, 'C', charcoalStack); //WOODASH
GameRegistry.addRecipe(new ShapelessBloodOrbRecipe(new ItemStack(ModItems.itemIncense, 1, 1), woodashStack, "dyeRed", "dyeRed", new ItemStack(Items.redstone), leavesStack, leavesStack, new ItemStack(ModItems.apprenticeBloodOrb)));
GameRegistry.addRecipe(new ShapelessBloodOrbRecipe(new ItemStack(ModItems.itemIncense, 1, 2), woodashStack, "dyeBlue", "dyeBlue", goldNuggetStack, goldNuggetStack, glowstoneStack, stringStack, stringStack, new ItemStack(ModItems.magicianBloodOrb)));
GameRegistry.addRecipe(new ShapelessBloodOrbRecipe(new ItemStack(ModItems.itemIncense, 1, 3), woodashStack, "dyeGreen", "dyeGreen", soulSandStack, gunpowderStack, fermentedEyeStack, new ItemStack(ModItems.masterBloodOrb)));
GameRegistry.addRecipe(new ShapelessBloodOrbRecipe(new ItemStack(ModItems.itemIncense, 1, 4), woodashStack, "dyePurple", "dyePurple", quartzStack, netherwartStack, blazePowderStack, fracturedBoneStack, goldNuggetStack, new ItemStack(ModItems.archmageBloodOrb)));
}
public enum EnumIncense
{
WOODASH(0, 200, 1.0f, 1000, 0.937f, 0.898f, 0.820f),
RED(200, 600, 1.5f, 1000, 1.0f, 0, 0),
BLUE(600, 1200, 3.0f, 1000, 0, 0, 1.0f),
GREEN(1200, 2000, 4.0f, 1000, 0, 1.0f, 0),
PURPLE(2000, 3000, 5.0f, 1000, 1.0f, 0, 1.0f);
public final int minValue;
public final int maxValue;
public final float tickRate;
public final int incenseDuration;
public final float redColour;
public final float greenColour;
public final float blueColour;
private EnumIncense(int minValue, int maxValue, float tickRate, int dur, float red, float green, float blue)
{
this.minValue = minValue;
this.maxValue = maxValue;
this.tickRate = tickRate;
this.incenseDuration = dur;
this.redColour = red;
this.greenColour = green;
this.blueColour = blue;
}
public static EnumIncense getEnumForIndex(int index)
{
if(index > EnumIncense.values().length || index < 0)
{
return WOODASH;
}else
{
return EnumIncense.values()[index];
}
}
}
}

View file

@ -1,15 +1,10 @@
package WayofTime.alchemicalWizardry.common.items.sigil.holding;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.ModItems;
import WayofTime.alchemicalWizardry.api.items.interfaces.IHolding;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import java.util.List;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
@ -17,10 +12,10 @@ import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.util.Constants;
import java.util.ArrayList;
import java.util.List;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class SigilOfHolding extends EnergyItems
{

View file

@ -48,7 +48,7 @@ public class RitualEffectEllipsoid extends RitualEffect
int ySize = item2 == null ? 0 : item2.stackSize;
int zSize = item3 == null ? 0 : item3.stackSize;
int cost = (int) Math.pow((xSize + 1) * (ySize + 1) * (zSize + 1), 0.333);
int cost = 5;
if (currentEssence < cost)
{

View file

@ -65,6 +65,10 @@ public class RitualEffectExpulsion extends RitualEffect
for (EntityPlayer entityplayer : playerList)
{
if(entityplayer.capabilities.isCreativeMode)
{
continue;
}
String playerString = SpellHelper.getUsername(entityplayer);
if (!playerString.equals(owner))
{

View file

@ -4,6 +4,8 @@ import java.util.ArrayList;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.block.BlockOre;
import net.minecraft.block.BlockRedstoneOre;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.world.World;
@ -22,6 +24,24 @@ public class RitualEffectMagnetic extends RitualEffect
private static final int terraeDrain = 10;
private static final int orbisTerraeDrain = 10;
public static boolean isBlockOre(Block block, int meta)
{
if (block == null)
return false;
if (block instanceof BlockOre || block instanceof BlockRedstoneOre)
return true;
ItemStack itemStack = new ItemStack(block, 1, meta);
for (int id : OreDictionary.getOreIDs(itemStack))
{
String oreName = OreDictionary.getOreName(id);
if (oreName.contains("ore"))
return true;
}
return false;
}
@Override
public void performEffect(IMasterRitualStone ritualStone)
{
@ -67,6 +87,7 @@ public class RitualEffectMagnetic extends RitualEffect
yRep = y + j;
zRep = z + k;
replace = true;
break;
}
}
}
@ -96,43 +117,30 @@ public class RitualEffectMagnetic extends RitualEffect
Block block = world.getBlock(x + i, j, z + k);
int meta = world.getBlockMetadata(x + i, j, z + k);
if (block == null)
if (isBlockOre(block, meta))
{
continue;
}
//Allow swapping code. This means the searched block is an ore.
BlockTeleposer.swapBlocks(this, world, world, x + i, j, z + k, xRep, yRep, zRep);
SoulNetworkHandler.syphonFromNetwork(owner, this.getCostPerRefresh());
ItemStack itemStack = new ItemStack(block, 1, meta);
int id = OreDictionary.getOreID(itemStack);
if (id != -1)
{
String oreName = OreDictionary.getOreName(id);
if (oreName.contains("ore"))
if (hasPotentia)
{
//Allow swapping code. This means the searched block is an ore.
BlockTeleposer.swapBlocks(this, world, world, x + i, j, z + k, xRep, yRep, zRep);
SoulNetworkHandler.syphonFromNetwork(owner, this.getCostPerRefresh());
if (hasPotentia)
{
this.canDrainReagent(ritualStone, ReagentRegistry.potentiaReagent, potentiaDrain, true);
}
if (hasTerrae)
{
this.canDrainReagent(ritualStone, ReagentRegistry.terraeReagent, terraeDrain, true);
}
if (hasOrbisTerrae)
{
this.canDrainReagent(ritualStone, ReagentRegistry.orbisTerraeReagent, orbisTerraeDrain, true);
}
this.setLastPosition(ritualStone.getCustomRitualTag(), new Int3(i, j, k));
return;
this.canDrainReagent(ritualStone, ReagentRegistry.potentiaReagent, potentiaDrain, true);
}
if (hasTerrae)
{
this.canDrainReagent(ritualStone, ReagentRegistry.terraeReagent, terraeDrain, true);
}
if (hasOrbisTerrae)
{
this.canDrainReagent(ritualStone, ReagentRegistry.orbisTerraeReagent, orbisTerraeDrain, true);
}
this.setLastPosition(ritualStone.getCustomRitualTag(), new Int3(i, j, k));
return;
}
k++;
}

View file

@ -3,19 +3,24 @@ package WayofTime.alchemicalWizardry.common.tileEntity;
import java.util.List;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.network.NetworkManager;
import net.minecraft.network.Packet;
import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.util.Constants;
import WayofTime.alchemicalWizardry.api.sacrifice.IIncense;
import WayofTime.alchemicalWizardry.api.sacrifice.PlayerSacrificeHandler;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
public class TECrucible extends TEInventory
{
private int radius = 5;
public float rColour;
public float gColour;
public float bColour;
@ -45,6 +50,8 @@ public class TECrucible extends TEInventory
if(worldObj.isRemote)
return;
boolean stateChanged = false;
if(ticksRemaining <= 0)
{
ItemStack stack = this.getStackInSlot(0);
@ -67,16 +74,17 @@ public class TECrucible extends TEInventory
{
this.setInventorySlotContents(0, null);
}
stateChanged = true;
}
}
if(ticksRemaining > 0)
{
List<EntityPlayer> playerList = SpellHelper.getPlayersInRange(worldObj, xCoord + 0.5, yCoord + 0.5, zCoord + 0.5, 3, 3);
List<EntityPlayer> playerList = SpellHelper.getPlayersInRange(worldObj, xCoord + 0.5, yCoord + 0.5, zCoord + 0.5, radius, radius);
if(playerList != null && !playerList.isEmpty())
{
boolean stateChanged = false;
boolean allAreGood = true;
for(EntityPlayer player : playerList)
@ -100,16 +108,14 @@ public class TECrucible extends TEInventory
stateChanged = true;
}
if(stateChanged)
{
worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
}
}else
{
if(state != 0)
{
state = 0;
worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
updateNeighbors();
}
}
}else
@ -118,8 +124,32 @@ public class TECrucible extends TEInventory
{
state = 0;
worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
updateNeighbors();
}
}
if(stateChanged)
{
worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
updateNeighbors();
}
}
private void updateNeighbors()
{
Block block = worldObj.getBlock(xCoord + 1, yCoord, zCoord);
block.onNeighborBlockChange(worldObj, xCoord + 1, yCoord, zCoord, block);
block = worldObj.getBlock(xCoord - 1, yCoord, zCoord);
block.onNeighborBlockChange(worldObj, xCoord - 1, yCoord, zCoord, block);
block = worldObj.getBlock(xCoord, yCoord + 1, zCoord);
block.onNeighborBlockChange(worldObj, xCoord, yCoord + 1, zCoord, block);
block = worldObj.getBlock(xCoord, yCoord - 1, zCoord);
block.onNeighborBlockChange(worldObj, xCoord, yCoord - 1, zCoord, block);
block = worldObj.getBlock(xCoord, yCoord, zCoord + 1);
block.onNeighborBlockChange(worldObj, xCoord, yCoord, zCoord + 1, block);
block = worldObj.getBlock(xCoord, yCoord, zCoord - 1);
block.onNeighborBlockChange(worldObj, xCoord, yCoord, zCoord - 1, block);
}
public void spawnClientParticle(World world, int x, int y, int z, Random rand)
@ -127,15 +157,16 @@ public class TECrucible extends TEInventory
switch(state)
{
case 0:
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.5D, z + 0.5D + rand.nextGaussian() / 8, 0.15, 0.15, 0.15);
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.7D, z + 0.5D + rand.nextGaussian() / 8, 0.15, 0.15, 0.15);
break;
case 1:
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.5D, z + 0.5D + rand.nextGaussian() / 8, 0.9, 0.9, 0.9);
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.7D, z + 0.5D + rand.nextGaussian() / 8, 1.0, 1.0, 1.0);
break;
case 2:
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.5D, z + 0.5D + rand.nextGaussian() / 8, rColour, gColour, bColour);
world.spawnParticle("reddust", x + 0.5D + rand.nextGaussian() / 8, y + 0.7D, z + 0.5D + rand.nextGaussian() / 8, rColour, gColour, bColour);
world.spawnParticle("flame", x + 0.5D + rand.nextGaussian() / 32, y + 0.7D, z + 0.5D + rand.nextGaussian() / 32, 0, 0.02, 0);
break;
case 3:
@ -152,6 +183,7 @@ public class TECrucible extends TEInventory
tag.setInteger("ticksRemaining", ticksRemaining);
tag.setInteger("minValue", minValue);
tag.setInteger("maxValue", maxValue);
tag.setFloat("increment", this.incrementValue);
this.writeClientNBT(tag);
}
@ -164,6 +196,7 @@ public class TECrucible extends TEInventory
ticksRemaining = tag.getInteger("ticksRemaining");
minValue = tag.getInteger("minValue");
maxValue = tag.getInteger("maxValue");
incrementValue = tag.getFloat("increment");
this.readClientNBT(tag);
}
@ -174,6 +207,20 @@ public class TECrucible extends TEInventory
tag.setFloat("gColour", gColour);
tag.setFloat("bColour", bColour);
tag.setInteger("state", state);
NBTTagList invList = new NBTTagList();
for (int i = 0; i < inv.length; i++)
{
if (inv[i] != null)
{
NBTTagCompound stackTag = new NBTTagCompound();
stackTag.setByte("Slot", (byte) i);
inv[i].writeToNBT(stackTag);
invList.appendTag(stackTag);
}
}
tag.setTag("Inventory", invList);
}
public void readClientNBT(NBTTagCompound tag)
@ -182,6 +229,17 @@ public class TECrucible extends TEInventory
gColour = tag.getFloat("gColour");
bColour = tag.getFloat("bColour");
state = tag.getInteger("state");
NBTTagList invList = tag.getTagList("Inventory",
Constants.NBT.TAG_COMPOUND);
for (int i = 0; i < invList.tagCount(); i++)
{
NBTTagCompound stackTag = invList.getCompoundTagAt(i);
int slot = stackTag.getByte("Slot");
if (slot >= 0 && slot < inv.length)
inv[slot] = ItemStack.loadItemStackFromNBT(stackTag);
}
}
@ -211,4 +269,9 @@ public class TECrucible extends TEInventory
{
return stack != null ? stack.getItem() instanceof IIncense : false;
}
public int getRSPowerOutput()
{
return (state == 1 || state == 0) ? 0 : 15;
}
}