Hope this works

This commit is contained in:
Arcaratus 2015-07-29 09:27:45 -04:00
commit 45e8c57ac9
45 changed files with 1135 additions and 1113 deletions

View file

@ -9,6 +9,8 @@ import java.util.Map.Entry;
import net.minecraft.entity.EntityList; import net.minecraft.entity.EntityList;
import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.EntityLivingBase;
import net.minecraftforge.common.config.Configuration; import net.minecraftforge.common.config.Configuration;
import net.minecraftforge.fml.common.FMLCommonHandler;
import net.minecraftforge.fml.relauncher.Side;
import WayofTime.alchemicalWizardry.api.rituals.Rituals; import WayofTime.alchemicalWizardry.api.rituals.Rituals;
import WayofTime.alchemicalWizardry.client.renderer.ColourThreshold; import WayofTime.alchemicalWizardry.client.renderer.ColourThreshold;
import WayofTime.alchemicalWizardry.client.renderer.RenderHelper; import WayofTime.alchemicalWizardry.client.renderer.RenderHelper;
@ -16,8 +18,6 @@ import WayofTime.alchemicalWizardry.common.demonVillage.DemonVillagePath;
import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.TEDemonPortal; import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.TEDemonPortal;
import WayofTime.alchemicalWizardry.common.items.armour.BoundArmour; import WayofTime.alchemicalWizardry.common.items.armour.BoundArmour;
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorParadigm; import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorParadigm;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.relauncher.Side;
/** /**
* Created with IntelliJ IDEA. * Created with IntelliJ IDEA.

View file

@ -1,11 +1,53 @@
package WayofTime.alchemicalWizardry; package WayofTime.alchemicalWizardry;
import WayofTime.alchemicalWizardry.common.items.*;
import net.minecraft.creativetab.CreativeTabs; import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.init.Items; import net.minecraft.init.Items;
import net.minecraft.item.Item; import net.minecraft.item.Item;
import net.minecraftforge.fml.common.registry.GameRegistry;
import WayofTime.alchemicalWizardry.api.items.ItemSpellMultiTool; import WayofTime.alchemicalWizardry.api.items.ItemSpellMultiTool;
import WayofTime.alchemicalWizardry.api.spell.SpellParadigmTool; import WayofTime.alchemicalWizardry.api.spell.SpellParadigmTool;
import WayofTime.alchemicalWizardry.common.items.AWBaseItems;
import WayofTime.alchemicalWizardry.common.items.ActivationCrystal;
import WayofTime.alchemicalWizardry.common.items.AirScribeTool;
import WayofTime.alchemicalWizardry.common.items.ApprenticeBloodOrb;
import WayofTime.alchemicalWizardry.common.items.ArchmageBloodOrb;
import WayofTime.alchemicalWizardry.common.items.ArmourInhibitor;
import WayofTime.alchemicalWizardry.common.items.BlankSpell;
import WayofTime.alchemicalWizardry.common.items.BloodShard;
import WayofTime.alchemicalWizardry.common.items.BoundAxe;
import WayofTime.alchemicalWizardry.common.items.BoundPickaxe;
import WayofTime.alchemicalWizardry.common.items.BoundShovel;
import WayofTime.alchemicalWizardry.common.items.CheatyItem;
import WayofTime.alchemicalWizardry.common.items.CreativeDagger;
import WayofTime.alchemicalWizardry.common.items.DaggerOfSacrifice;
import WayofTime.alchemicalWizardry.common.items.DawnScribeTool;
import WayofTime.alchemicalWizardry.common.items.DemonPlacer;
import WayofTime.alchemicalWizardry.common.items.DemonicTelepositionFocus;
import WayofTime.alchemicalWizardry.common.items.DuskScribeTool;
import WayofTime.alchemicalWizardry.common.items.EarthScribeTool;
import WayofTime.alchemicalWizardry.common.items.EnergyBattery;
import WayofTime.alchemicalWizardry.common.items.EnergyBazooka;
import WayofTime.alchemicalWizardry.common.items.EnergyBlast;
import WayofTime.alchemicalWizardry.common.items.EnergySword;
import WayofTime.alchemicalWizardry.common.items.EnhancedTelepositionFocus;
import WayofTime.alchemicalWizardry.common.items.FireScribeTool;
import WayofTime.alchemicalWizardry.common.items.ItemAlchemyBase;
import WayofTime.alchemicalWizardry.common.items.ItemBloodLetterPack;
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.ItemRitualDismantler;
import WayofTime.alchemicalWizardry.common.items.ItemRitualDiviner;
import WayofTime.alchemicalWizardry.common.items.LavaCrystal;
import WayofTime.alchemicalWizardry.common.items.LifeBucket;
import WayofTime.alchemicalWizardry.common.items.MagicianBloodOrb;
import WayofTime.alchemicalWizardry.common.items.MasterBloodOrb;
import WayofTime.alchemicalWizardry.common.items.ReinforcedTelepositionFocus;
import WayofTime.alchemicalWizardry.common.items.SacrificialDagger;
import WayofTime.alchemicalWizardry.common.items.TelepositionFocus;
import WayofTime.alchemicalWizardry.common.items.TranscendentBloodOrb;
import WayofTime.alchemicalWizardry.common.items.WaterScribeTool;
import WayofTime.alchemicalWizardry.common.items.armour.BoundArmour; import WayofTime.alchemicalWizardry.common.items.armour.BoundArmour;
import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmourEarth; import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmourEarth;
import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmourFire; import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmourFire;
@ -51,7 +93,6 @@ import WayofTime.alchemicalWizardry.common.items.sigil.SigilSeer;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilVoid; import WayofTime.alchemicalWizardry.common.items.sigil.SigilVoid;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilWater; import WayofTime.alchemicalWizardry.common.items.sigil.SigilWater;
import WayofTime.alchemicalWizardry.common.items.sigil.holding.SigilOfHolding; import WayofTime.alchemicalWizardry.common.items.sigil.holding.SigilOfHolding;
import cpw.mods.fml.common.registry.GameRegistry;
/** /**
* Created with IntelliJ IDEA. * Created with IntelliJ IDEA.

View file

@ -1,13 +1,13 @@
package WayofTime.alchemicalWizardry.api; package WayofTime.alchemicalWizardry.api;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class RoutingFocusPosAndFacing public class RoutingFocusPosAndFacing
{ {
public Int3 location; public Int3 location;
public ForgeDirection facing; public EnumFacing facing;
public RoutingFocusPosAndFacing(Int3 location, ForgeDirection facing) public RoutingFocusPosAndFacing(Int3 location, EnumFacing facing)
{ {
this.location = location; this.location = location;
this.facing = facing; this.facing = facing;

View file

@ -2,7 +2,7 @@ package WayofTime.alchemicalWizardry.api.event;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import cpw.mods.fml.common.eventhandler.Cancelable; import net.minecraftforge.fml.common.eventhandler.Cancelable;
@Cancelable @Cancelable
public class ItemDrainNetworkEvent extends PlayerDrainNetworkEvent public class ItemDrainNetworkEvent extends PlayerDrainNetworkEvent

View file

@ -2,7 +2,7 @@ package WayofTime.alchemicalWizardry.api.event;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import cpw.mods.fml.common.eventhandler.Cancelable; import net.minecraftforge.fml.common.eventhandler.Cancelable;
@Cancelable @Cancelable
public class PlayerAddToNetworkEvent extends AddToNetworkEvent public class PlayerAddToNetworkEvent extends AddToNetworkEvent

View file

@ -1,7 +1,7 @@
package WayofTime.alchemicalWizardry.api.event; package WayofTime.alchemicalWizardry.api.event;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import cpw.mods.fml.common.eventhandler.Cancelable; import net.minecraftforge.fml.common.eventhandler.Cancelable;
@Cancelable @Cancelable
public class PlayerDrainNetworkEvent extends SoulNetworkEvent public class PlayerDrainNetworkEvent extends SoulNetworkEvent

View file

@ -1,8 +1,8 @@
package WayofTime.alchemicalWizardry.api.event; package WayofTime.alchemicalWizardry.api.event;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import cpw.mods.fml.common.eventhandler.Cancelable; import net.minecraftforge.fml.common.eventhandler.Cancelable;
import cpw.mods.fml.common.eventhandler.Event; import net.minecraftforge.fml.common.eventhandler.Event;
@Cancelable @Cancelable
public class SacrificeKnifeUsedEvent extends Event public class SacrificeKnifeUsedEvent extends Event

View file

@ -9,7 +9,6 @@ import java.util.Set;
import net.minecraft.block.Block; import net.minecraft.block.Block;
import net.minecraft.block.material.Material; import net.minecraft.block.material.Material;
import net.minecraft.block.state.IBlockState; import net.minecraft.block.state.IBlockState;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.SharedMonsterAttributes; import net.minecraft.entity.SharedMonsterAttributes;
@ -25,7 +24,6 @@ import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.common.DimensionManager; import net.minecraftforge.common.DimensionManager;
import net.minecraftforge.common.util.Constants; import net.minecraftforge.common.util.Constants;
import net.minecraftforge.common.util.ForgeDirection;
import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler; import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper; import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
import WayofTime.alchemicalWizardry.api.spell.SpellEffect; import WayofTime.alchemicalWizardry.api.spell.SpellEffect;

View file

@ -19,10 +19,10 @@ import net.minecraft.util.MathHelper;
import net.minecraft.util.MovingObjectPosition; import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.Vec3; import net.minecraft.util.Vec3;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.registry.GameRegistry;
import WayofTime.alchemicalWizardry.ModItems; import WayofTime.alchemicalWizardry.ModItems;
import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent; import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent;
import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentRegistry; import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentRegistry;
import cpw.mods.fml.common.registry.GameRegistry;
public class APISpellHelper public class APISpellHelper
{ {

View file

@ -22,8 +22,8 @@ import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.Vec3; import net.minecraft.util.Vec3;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.common.util.Constants; import net.minecraftforge.common.util.Constants;
import cpw.mods.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly; import net.minecraftforge.fml.relauncher.SideOnly;
public class EntitySpellProjectile extends Entity implements IProjectile public class EntitySpellProjectile extends Entity implements IProjectile
{ {

View file

@ -1,10 +1,13 @@
package WayofTime.alchemicalWizardry.client; package WayofTime.alchemicalWizardry.client;
import WayofTime.alchemicalWizardry.common.thread.GAPIChecker;
import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemBlock;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fml.client.FMLClientHandler;
import net.minecraftforge.fml.client.registry.ClientRegistry;
import net.minecraftforge.fml.client.registry.RenderingRegistry;
import net.minecraftforge.fml.common.FMLCommonHandler;
import WayofTime.alchemicalWizardry.ModBlocks; import WayofTime.alchemicalWizardry.ModBlocks;
import WayofTime.alchemicalWizardry.api.spell.EntitySpellProjectile; import WayofTime.alchemicalWizardry.api.spell.EntitySpellProjectile;
import WayofTime.alchemicalWizardry.client.renderer.RitualDivinerRender; import WayofTime.alchemicalWizardry.client.renderer.RitualDivinerRender;
@ -85,6 +88,7 @@ import WayofTime.alchemicalWizardry.common.renderer.model.ModelWingedFireDemon;
import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderEnergyBazookaMainProjectile; import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderEnergyBazookaMainProjectile;
import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderEnergyBlastProjectile; import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderEnergyBlastProjectile;
import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderMeteor; import WayofTime.alchemicalWizardry.common.renderer.projectile.RenderMeteor;
import WayofTime.alchemicalWizardry.common.thread.GAPIChecker;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAlchemicCalcinator; import WayofTime.alchemicalWizardry.common.tileEntity.TEAlchemicCalcinator;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar; import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar;
import WayofTime.alchemicalWizardry.common.tileEntity.TEBellJar; import WayofTime.alchemicalWizardry.common.tileEntity.TEBellJar;
@ -98,10 +102,6 @@ import WayofTime.alchemicalWizardry.common.tileEntity.TESpellEnhancementBlock;
import WayofTime.alchemicalWizardry.common.tileEntity.TESpellModifierBlock; import WayofTime.alchemicalWizardry.common.tileEntity.TESpellModifierBlock;
import WayofTime.alchemicalWizardry.common.tileEntity.TESpellParadigmBlock; import WayofTime.alchemicalWizardry.common.tileEntity.TESpellParadigmBlock;
import WayofTime.alchemicalWizardry.common.tileEntity.TEWritingTable; import WayofTime.alchemicalWizardry.common.tileEntity.TEWritingTable;
import cpw.mods.fml.client.FMLClientHandler;
import cpw.mods.fml.client.registry.ClientRegistry;
import cpw.mods.fml.client.registry.RenderingRegistry;
import cpw.mods.fml.common.FMLCommonHandler;
public class ClientProxy extends CommonProxy public class ClientProxy extends CommonProxy
{ {

View file

@ -1,10 +1,10 @@
package WayofTime.alchemicalWizardry.client.gui; package WayofTime.alchemicalWizardry.client.gui;
import cpw.mods.fml.client.IModGuiFactory; import java.util.Set;
import net.minecraft.client.Minecraft; import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.GuiScreen; import net.minecraft.client.gui.GuiScreen;
import net.minecraftforge.fml.client.IModGuiFactory;
import java.util.Set;
public class ConfigGuiFactory implements IModGuiFactory { public class ConfigGuiFactory implements IModGuiFactory {

View file

@ -42,7 +42,6 @@ import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.PlayerEvent.PlayerRespawnEvent; import net.minecraftforge.fml.common.gameevent.PlayerEvent.PlayerRespawnEvent;
import net.minecraftforge.fml.common.registry.GameRegistry; import net.minecraftforge.fml.common.registry.GameRegistry;
import net.minecraftforge.oredict.OreDictionary; import net.minecraftforge.oredict.OreDictionary;
import vazkii.botania.api.internal.IManaBurst;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.BloodMagicConfiguration; import WayofTime.alchemicalWizardry.BloodMagicConfiguration;
import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent; import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent;
@ -817,11 +816,11 @@ public class AlchemicalWizardryEventHooks
@Optional.Method(modid = "Botania") @Optional.Method(modid = "Botania")
private boolean isManaBurst(Entity entity) private boolean isManaBurst(Entity entity)
{ {
if(entity instanceof IManaBurst) { // if(entity instanceof IManaBurst) {
ItemStack lens = ((IManaBurst)entity).getSourceLens(); // ItemStack lens = ((IManaBurst)entity).getSourceLens();
return !(lens.getItemDamage()!=8 && lens.getItemDamage()!=11); // return !(lens.getItemDamage()!=8 && lens.getItemDamage()!=11);
} // }
else // else
return false; return false;
} }
} }

View file

@ -1,8 +1,8 @@
package WayofTime.alchemicalWizardry.common; package WayofTime.alchemicalWizardry.common;
import cpw.mods.fml.common.network.NetworkRegistry; import net.minecraftforge.fml.common.network.NetworkRegistry;
import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper; import net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper;
import cpw.mods.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.Side;
public class ClientToServerPacketHandler public class ClientToServerPacketHandler
{ {

View file

@ -1,6 +1,8 @@
package WayofTime.alchemicalWizardry.common; package WayofTime.alchemicalWizardry.common;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.registry.EntityRegistry;
import net.minecraftforge.fml.common.registry.GameRegistry;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.spell.EntitySpellProjectile; import WayofTime.alchemicalWizardry.api.spell.EntitySpellProjectile;
import WayofTime.alchemicalWizardry.common.entity.mob.BookEntityItem; import WayofTime.alchemicalWizardry.common.entity.mob.BookEntityItem;
@ -22,8 +24,6 @@ import WayofTime.alchemicalWizardry.common.entity.projectile.WaterProjectile;
import WayofTime.alchemicalWizardry.common.entity.projectile.WindGustProjectile; import WayofTime.alchemicalWizardry.common.entity.projectile.WindGustProjectile;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar; import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar;
import WayofTime.alchemicalWizardry.common.tileEntity.TEMasterStone; import WayofTime.alchemicalWizardry.common.tileEntity.TEMasterStone;
import cpw.mods.fml.common.registry.EntityRegistry;
import cpw.mods.fml.common.registry.GameRegistry;
public class CommonProxy public class CommonProxy
{ {

View file

@ -3,10 +3,10 @@ package WayofTime.alchemicalWizardry.common;
import io.netty.buffer.ByteBuf; import io.netty.buffer.ByteBuf;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmour; import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmour;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
public class MessageKeyPressed implements IMessage, IMessageHandler<MessageKeyPressed, IMessage> public class MessageKeyPressed implements IMessage, IMessageHandler<MessageKeyPressed, IMessage>
{ {

View file

@ -1,11 +1,11 @@
package WayofTime.alchemicalWizardry.common; package WayofTime.alchemicalWizardry.common;
import WayofTime.alchemicalWizardry.ModItems;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import net.minecraft.entity.passive.EntityAnimal; import net.minecraft.entity.passive.EntityAnimal;
import net.minecraft.potion.Potion; import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect; import net.minecraft.potion.PotionEffect;
import net.minecraftforge.event.entity.living.LivingDropsEvent; import net.minecraftforge.event.entity.living.LivingDropsEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import WayofTime.alchemicalWizardry.ModItems;
public class ModLivingDropsEvent public class ModLivingDropsEvent
{ {

View file

@ -19,6 +19,13 @@ import net.minecraft.util.BlockPos;
import net.minecraft.util.EnumFacing; import net.minecraft.util.EnumFacing;
import net.minecraft.util.EnumParticleTypes; import net.minecraft.util.EnumParticleTypes;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.FMLCommonHandler;
import net.minecraftforge.fml.common.network.FMLEmbeddedChannel;
import net.minecraftforge.fml.common.network.FMLIndexedMessageToMessageCodec;
import net.minecraftforge.fml.common.network.FMLOutboundHandler;
import net.minecraftforge.fml.common.network.NetworkRegistry;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.ColourAndCoords; import WayofTime.alchemicalWizardry.api.ColourAndCoords;
import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent; import WayofTime.alchemicalWizardry.api.alchemy.energy.Reagent;
@ -33,13 +40,6 @@ import WayofTime.alchemicalWizardry.common.tileEntity.TEReagentConduit;
import WayofTime.alchemicalWizardry.common.tileEntity.TESocket; import WayofTime.alchemicalWizardry.common.tileEntity.TESocket;
import WayofTime.alchemicalWizardry.common.tileEntity.TETeleposer; import WayofTime.alchemicalWizardry.common.tileEntity.TETeleposer;
import WayofTime.alchemicalWizardry.common.tileEntity.TEWritingTable; import WayofTime.alchemicalWizardry.common.tileEntity.TEWritingTable;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.common.network.FMLEmbeddedChannel;
import cpw.mods.fml.common.network.FMLIndexedMessageToMessageCodec;
import cpw.mods.fml.common.network.FMLOutboundHandler;
import cpw.mods.fml.common.network.NetworkRegistry;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public enum NewPacketHandler public enum NewPacketHandler
{ {

View file

@ -1,10 +1,10 @@
package WayofTime.alchemicalWizardry.common.achievements; package WayofTime.alchemicalWizardry.common.achievements;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.common.gameevent.PlayerEvent;
import net.minecraft.item.Item; import net.minecraft.item.Item;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraft.stats.Achievement; import net.minecraft.stats.Achievement;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.PlayerEvent;
public class AchievementTrigger public class AchievementTrigger
{ {

View file

@ -3,8 +3,8 @@ package WayofTime.alchemicalWizardry.common.achievements;
import net.minecraft.stats.Achievement; import net.minecraft.stats.Achievement;
import net.minecraft.util.StatCollector; import net.minecraft.util.StatCollector;
import net.minecraftforge.common.AchievementPage; import net.minecraftforge.common.AchievementPage;
import net.minecraftforge.fml.common.FMLCommonHandler;
import WayofTime.alchemicalWizardry.ModItems; import WayofTime.alchemicalWizardry.ModItems;
import cpw.mods.fml.common.FMLCommonHandler;
public class ModAchievements public class ModAchievements
{ {

View file

@ -17,13 +17,13 @@ import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.BlockPos; import net.minecraft.util.BlockPos;
import net.minecraft.util.EnumFacing; import net.minecraft.util.EnumFacing;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.registry.GameRegistry;
import net.minecraftforge.fml.common.registry.GameRegistry.UniqueIdentifier;
import WayofTime.alchemicalWizardry.api.Int3; import WayofTime.alchemicalWizardry.api.Int3;
import WayofTime.alchemicalWizardry.common.demonVillage.loot.DemonVillageLootRegistry; import WayofTime.alchemicalWizardry.common.demonVillage.loot.DemonVillageLootRegistry;
import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.IBlockPortalNode; import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.IBlockPortalNode;
import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.ITilePortalNode; import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.ITilePortalNode;
import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.TEDemonPortal; import WayofTime.alchemicalWizardry.common.demonVillage.tileEntity.TEDemonPortal;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.common.registry.GameRegistry.UniqueIdentifier;
public class BlockSet public class BlockSet
{ {

View file

@ -20,10 +20,10 @@ import net.minecraft.util.BlockPos;
import net.minecraft.util.DamageSource; import net.minecraft.util.DamageSource;
import net.minecraft.util.MathHelper; import net.minecraft.util.MathHelper;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.ModItems; import WayofTime.alchemicalWizardry.ModItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class EntityElemental extends EntityDemon public class EntityElemental extends EntityDemon
{ {

View file

@ -5,8 +5,8 @@ import net.minecraft.entity.effect.EntityLightningBolt;
import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.item.EntityItem;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.Optional;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import cpw.mods.fml.common.Optional;
public class MailOrderEntityItem extends EntityItem public class MailOrderEntityItem extends EntityItem
{ {

View file

@ -17,10 +17,10 @@ import net.minecraft.util.MathHelper;
import net.minecraft.util.MovingObjectPosition; import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.Vec3; import net.minecraft.util.Vec3;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.fml.common.registry.IThrowableEntity;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper; import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
import cpw.mods.fml.common.registry.IThrowableEntity;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
//Shamelessly ripped off from x3n0ph0b3 //Shamelessly ripped off from x3n0ph0b3
public class EnergyBlastProjectile extends Entity implements IProjectile, IThrowableEntity public class EnergyBlastProjectile extends Entity implements IProjectile, IThrowableEntity

View file

@ -1,145 +1,145 @@
package WayofTime.alchemicalWizardry.common.items.forestry; //package WayofTime.alchemicalWizardry.common.items.forestry;
//
import java.util.List; //import java.util.List;
//
import net.minecraft.client.renderer.texture.IIconRegister; //import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer; //import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import net.minecraft.util.StatCollector; //import net.minecraft.util.StatCollector;
import net.minecraft.world.World; //import net.minecraft.world.World;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; //import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.items.EnergyItems; //import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side; //import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly; //import cpw.mods.fml.relauncher.SideOnly;
import forestry.api.apiculture.IBee; //import forestry.api.apiculture.IBee;
import forestry.api.apiculture.IBeeGenome; //import forestry.api.apiculture.IBeeGenome;
import forestry.api.apiculture.IBeeHousing; //import forestry.api.apiculture.IBeeHousing;
import forestry.api.apiculture.IHiveFrame; //import forestry.api.apiculture.IHiveFrame;
//
public class ItemBloodFrame extends EnergyItems implements IHiveFrame //public class ItemBloodFrame extends EnergyItems implements IHiveFrame
{ //{
public ItemBloodFrame() // public ItemBloodFrame()
{ // {
super(); // super();
this.maxStackSize = 1; // this.maxStackSize = 1;
this.setMaxDamage(10); // this.setMaxDamage(10);
setEnergyUsed(1000); // setEnergyUsed(1000);
setCreativeTab(AlchemicalWizardry.tabBloodMagic); // setCreativeTab(AlchemicalWizardry.tabBloodMagic);
} // }
//
@Override // @Override
public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) // public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4)
{ // {
par3List.add(StatCollector.translateToLocal("tooltip.bloodframe.desc")); // par3List.add(StatCollector.translateToLocal("tooltip.bloodframe.desc"));
//
if (!(par1ItemStack.getTagCompound() == null)) // if (!(par1ItemStack.getTagCompound() == null))
{ // {
par3List.add(StatCollector.translateToLocal("tooltip.owner.currentowner") + " " + par1ItemStack.getTagCompound().getString("ownerName")); // par3List.add(StatCollector.translateToLocal("tooltip.owner.currentowner") + " " + par1ItemStack.getTagCompound().getString("ownerName"));
} // }
} // }
//
@Override // @Override
@SideOnly(Side.CLIENT) // @SideOnly(Side.CLIENT)
public void registerIcons(IIconRegister iconRegister) // public void registerIcons(IIconRegister iconRegister)
{ // {
this.itemIcon = iconRegister.registerIcon("AlchemicalWizardry:BloodFrame"); // this.itemIcon = iconRegister.registerIcon("AlchemicalWizardry:BloodFrame");
} // }
//
@Override // @Override
public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) // public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer)
{ // {
if (EnergyItems.checkAndSetItemOwner(par1ItemStack, par3EntityPlayer)) // if (EnergyItems.checkAndSetItemOwner(par1ItemStack, par3EntityPlayer))
{ // {
if (par1ItemStack.getItemDamage() > 0) // if (par1ItemStack.getItemDamage() > 0)
{ // {
if(EnergyItems.syphonBatteries(par1ItemStack, par3EntityPlayer, getEnergyUsed())) // if(EnergyItems.syphonBatteries(par1ItemStack, par3EntityPlayer, getEnergyUsed()))
{ // {
par1ItemStack.setItemDamage(par1ItemStack.getItemDamage() - 1); // par1ItemStack.setItemDamage(par1ItemStack.getItemDamage() - 1);
} // }
} // }
} // }
return par1ItemStack; // return par1ItemStack;
} // }
//
@Override public float getTerritoryModifier(IBeeGenome genome, float currentModifier) // @Override public float getTerritoryModifier(IBeeGenome genome, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 1; // return 1;
} // }
//
@Override public float getMutationModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier) // @Override public float getMutationModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 1; // return 1;
} // }
//
@Override public float getLifespanModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier) // @Override public float getLifespanModifier(IBeeGenome genome, IBeeGenome mate, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 0.0001f; // return 0.0001f;
} // }
//
@Override public float getProductionModifier(IBeeGenome genome, float currentModifier) // @Override public float getProductionModifier(IBeeGenome genome, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 0; // return 0;
} // }
//
@Override public float getFloweringModifier(IBeeGenome genome, float currentModifier) // @Override public float getFloweringModifier(IBeeGenome genome, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 1; // return 1;
} // }
//
@Override public float getGeneticDecay(IBeeGenome genome, float currentModifier) // @Override public float getGeneticDecay(IBeeGenome genome, float currentModifier)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return 1; // return 1;
} // }
//
@Override public boolean isSealed() // @Override public boolean isSealed()
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return false; // return false;
} // }
//
@Override public boolean isSelfLighted() // @Override public boolean isSelfLighted()
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return false; // return false;
} // }
//
@Override public boolean isSunlightSimulated() // @Override public boolean isSunlightSimulated()
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return false; // return false;
} // }
//
@Override public boolean isHellish() // @Override public boolean isHellish()
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
return false; // return false;
} // }
//
@Override public ItemStack frameUsed(IBeeHousing housing, ItemStack frame, IBee queen, int wear) // @Override public ItemStack frameUsed(IBeeHousing housing, ItemStack frame, IBee queen, int wear)
{ // {
// TODO Auto-generated method stub // // TODO Auto-generated method stub
if(EnergyItems.canSyphonInContainer(frame, getEnergyUsed()*wear)) // if(EnergyItems.canSyphonInContainer(frame, getEnergyUsed()*wear))
{ // {
EnergyItems.syphonWhileInContainer(frame, getEnergyUsed()*wear); // EnergyItems.syphonWhileInContainer(frame, getEnergyUsed()*wear);
return frame; // return frame;
}else // }else
{ // {
frame.setItemDamage(frame.getItemDamage() + wear); // frame.setItemDamage(frame.getItemDamage() + wear);
if(frame.getItemDamage()>=frame.getMaxDamage()) // if(frame.getItemDamage()>=frame.getMaxDamage())
{ // {
return null; // return null;
} // }
return frame; // return frame;
} // }
//
} // }
//
//
//
} //}

View file

@ -8,7 +8,7 @@ import net.minecraft.entity.item.EntityItem;
import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL11;
@ -122,7 +122,7 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
return scaleFactor; return scaleFactor;
} }
private void translateGhostItemByOrientation(ItemStack ghostItemStack, double x, double y, double z, ForgeDirection forgeDirection) private void translateGhostItemByOrientation(ItemStack ghostItemStack, double x, double y, double z, EnumFacing forgeDirection)
{ {
if (ghostItemStack != null) if (ghostItemStack != null)
{ {
@ -166,11 +166,6 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
return; return;
} }
case UNKNOWN:
{
return;
}
default: default:
{ {
return; return;
@ -216,11 +211,6 @@ public class TEAltarRenderer extends TileEntitySpecialRenderer
return; return;
} }
case UNKNOWN:
{
return;
}
default: default:
{ {
return; return;

View file

@ -6,14 +6,12 @@ import net.minecraft.client.renderer.WorldRenderer;
import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureAtlasSprite;
import net.minecraft.client.renderer.texture.TextureMap; import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.util.ResourceLocation; import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.model.AdvancedModelLoader; import net.minecraftforge.fml.client.FMLClientHandler;
import net.minecraftforge.client.model.IModelCustom;
import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL11;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar; import WayofTime.alchemicalWizardry.common.tileEntity.TEAltar;
import cpw.mods.fml.client.FMLClientHandler;
public class ModelBloodAltar extends ModelBase public class ModelBloodAltar extends ModelBase
{ {

View file

@ -9,7 +9,7 @@ package WayofTime.alchemicalWizardry.common.renderer.model;
import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer; import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class ModelConduit extends ModelBase public class ModelConduit extends ModelBase
{ {
@ -147,7 +147,7 @@ public class ModelConduit extends ModelBase
setRotation(spacer8, 0F, 0F, 0F); setRotation(spacer8, 0F, 0F, 0F);
} }
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, ForgeDirection input, ForgeDirection output) public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, EnumFacing input, EnumFacing output)
{ {
super.render(entity, f, f1, f2, f3, f4, f5); super.render(entity, f, f1, f2, f3, f4, f5);
setRotationAngles(f, f1, f2, f3, f4, f5, entity); setRotationAngles(f, f1, f2, f3, f4, f5, entity);

View file

@ -3,7 +3,7 @@ package WayofTime.alchemicalWizardry.common.renderer.model;
import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer; import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class ModelSpellEffectBlock extends ModelBase public class ModelSpellEffectBlock extends ModelBase
{ {
@ -184,7 +184,7 @@ public class ModelSpellEffectBlock extends ModelBase
setRotation(outputSpacer4, 0F, 0F, 0F); setRotation(outputSpacer4, 0F, 0F, 0F);
} }
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, ForgeDirection input, ForgeDirection output) public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, EnumFacing input, EnumFacing output)
{ {
super.render(entity, f, f1, f2, f3, f4, f5); super.render(entity, f, f1, f2, f3, f4, f5);
setRotationAngles(f, f1, f2, f3, f4, f5, entity); setRotationAngles(f, f1, f2, f3, f4, f5, entity);

View file

@ -3,7 +3,7 @@ package WayofTime.alchemicalWizardry.common.renderer.model;
import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer; import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class ModelSpellEnhancementBlock extends ModelBase public class ModelSpellEnhancementBlock extends ModelBase
@ -185,7 +185,7 @@ public class ModelSpellEnhancementBlock extends ModelBase
setRotation(outputSecond, 0F, 0F, 0F); setRotation(outputSecond, 0F, 0F, 0F);
} }
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, ForgeDirection input, ForgeDirection output) public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, EnumFacing input, EnumFacing output)
{ {
super.render(entity, f, f1, f2, f3, f4, f5); super.render(entity, f, f1, f2, f3, f4, f5);
setRotationAngles(f, f1, f2, f3, f4, f5, entity); setRotationAngles(f, f1, f2, f3, f4, f5, entity);

View file

@ -3,7 +3,7 @@ package WayofTime.alchemicalWizardry.common.renderer.model;
import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer; import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class ModelSpellModifierBlock extends ModelBase public class ModelSpellModifierBlock extends ModelBase
{ {
@ -149,7 +149,7 @@ public class ModelSpellModifierBlock extends ModelBase
setRotation(output4, 0F, 0F, 0F); setRotation(output4, 0F, 0F, 0F);
} }
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, ForgeDirection input, ForgeDirection output) public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, EnumFacing input, EnumFacing output)
{ {
super.render(entity, f, f1, f2, f3, f4, f5); super.render(entity, f, f1, f2, f3, f4, f5);
setRotationAngles(f, f1, f2, f3, f4, f5, entity); setRotationAngles(f, f1, f2, f3, f4, f5, entity);

View file

@ -10,7 +10,7 @@ package WayofTime.alchemicalWizardry.common.renderer.model;
import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelRenderer; import net.minecraft.client.model.ModelRenderer;
import net.minecraft.entity.Entity; import net.minecraft.entity.Entity;
import net.minecraftforge.common.util.ForgeDirection; import net.minecraft.util.EnumFacing;
public class ModelSpellParadigmBlock extends ModelBase public class ModelSpellParadigmBlock extends ModelBase
{ {
@ -100,7 +100,7 @@ public class ModelSpellParadigmBlock extends ModelBase
setRotation(Shape5, 0F, 0F, 0F); setRotation(Shape5, 0F, 0F, 0F);
} }
public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, ForgeDirection input, ForgeDirection output) public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5, EnumFacing input, EnumFacing output)
{ {
super.render(entity, f, f1, f2, f3, f4, f5); super.render(entity, f, f1, f2, f3, f4, f5);
setRotationAngles(f, f1, f2, f3, f4, f5, entity); setRotationAngles(f, f1, f2, f3, f4, f5, entity);

View file

@ -1,19 +1,19 @@
package WayofTime.alchemicalWizardry.common.rituals; package WayofTime.alchemicalWizardry.common.rituals;
import WayofTime.alchemicalWizardry.api.rituals.IMasterRitualStone; import java.util.ArrayList;
import WayofTime.alchemicalWizardry.api.rituals.RitualComponent; import java.util.List;
import WayofTime.alchemicalWizardry.api.rituals.RitualEffect;
import WayofTime.alchemicalWizardry.api.soulNetwork.LifeEssenceNetwork;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.potion.Potion; import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect; import net.minecraft.potion.PotionEffect;
import net.minecraft.server.MinecraftServer; import net.minecraft.server.MinecraftServer;
import net.minecraft.util.BlockPos; import net.minecraft.util.BlockPos;
import net.minecraft.world.World; import net.minecraft.world.World;
import WayofTime.alchemicalWizardry.api.rituals.IMasterRitualStone;
import java.util.ArrayList; import WayofTime.alchemicalWizardry.api.rituals.RitualComponent;
import java.util.List; import WayofTime.alchemicalWizardry.api.rituals.RitualEffect;
import WayofTime.alchemicalWizardry.api.soulNetwork.LifeEssenceNetwork;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
public class RitualEffectApiaryOverclock extends RitualEffect public class RitualEffectApiaryOverclock extends RitualEffect
{ {

View file

@ -2,8 +2,8 @@ package WayofTime.alchemicalWizardry.common.routing;
import net.minecraft.item.Item; import net.minecraft.item.Item;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraftforge.fml.common.registry.GameData;
import WayofTime.alchemicalWizardry.api.RoutingFocusLogic; import WayofTime.alchemicalWizardry.api.RoutingFocusLogic;
import cpw.mods.fml.common.registry.GameData;
public class RoutingFocusLogicModItems extends RoutingFocusLogic public class RoutingFocusLogicModItems extends RoutingFocusLogic
{ {

View file

@ -43,6 +43,7 @@ import net.minecraft.world.World;
import net.minecraft.world.WorldServer; import net.minecraft.world.WorldServer;
import net.minecraftforge.common.util.FakePlayer; import net.minecraftforge.common.util.FakePlayer;
import net.minecraftforge.fluids.IFluidBlock; import net.minecraftforge.fluids.IFluidBlock;
import net.minecraftforge.fml.common.FMLCommonHandler;
import net.minecraftforge.oredict.OreDictionary; import net.minecraftforge.oredict.OreDictionary;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles; import WayofTime.alchemicalWizardry.api.alchemy.energy.IAlchemyGoggles;
@ -52,7 +53,6 @@ import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
import WayofTime.alchemicalWizardry.api.spell.APISpellHelper; import WayofTime.alchemicalWizardry.api.spell.APISpellHelper;
import WayofTime.alchemicalWizardry.common.NewPacketHandler; import WayofTime.alchemicalWizardry.common.NewPacketHandler;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilDivination; import WayofTime.alchemicalWizardry.common.items.sigil.SigilDivination;
import cpw.mods.fml.common.FMLCommonHandler;
public class SpellHelper extends APISpellHelper public class SpellHelper extends APISpellHelper
{ {

View file

@ -19,6 +19,7 @@ import net.minecraftforge.fml.common.FMLCommonHandler;
import net.minecraftforge.fml.common.Loader; import net.minecraftforge.fml.common.Loader;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.gameevent.TickEvent; import net.minecraftforge.fml.common.gameevent.TickEvent;
import net.minecraftforge.fml.relauncher.FMLInjectionData;
public class GAPIChecker public class GAPIChecker
{ {
@ -34,7 +35,7 @@ public class GAPIChecker
public void init() public void init()
{ {
FMLCommonHandler.instance().bus().register(this); FMLCommonHandler.instance().bus().register(this);
File mcDir = (File)cpw.mods.fml.relauncher.FMLInjectionData.data()[6]; File mcDir = (File)FMLInjectionData.data()[6];
this.modsDir = new File(mcDir, "mods"); this.modsDir = new File(mcDir, "mods");

View file

@ -19,6 +19,8 @@ import net.minecraft.util.BlockPos;
import net.minecraft.util.EnumFacing; import net.minecraft.util.EnumFacing;
import net.minecraft.world.World; import net.minecraft.world.World;
import net.minecraftforge.common.util.Constants; import net.minecraftforge.common.util.Constants;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import WayofTime.alchemicalWizardry.api.ColourAndCoords; import WayofTime.alchemicalWizardry.api.ColourAndCoords;
import WayofTime.alchemicalWizardry.api.Int3; import WayofTime.alchemicalWizardry.api.Int3;
import WayofTime.alchemicalWizardry.api.alchemy.energy.IReagentHandler; import WayofTime.alchemicalWizardry.api.alchemy.energy.IReagentHandler;
@ -29,8 +31,6 @@ import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentStack;
import WayofTime.alchemicalWizardry.api.alchemy.energy.TileSegmentedReagentHandler; import WayofTime.alchemicalWizardry.api.alchemy.energy.TileSegmentedReagentHandler;
import WayofTime.alchemicalWizardry.common.entity.projectile.EntityParticleBeam; import WayofTime.alchemicalWizardry.common.entity.projectile.EntityParticleBeam;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper; import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class TEReagentConduit extends TileSegmentedReagentHandler implements IUpdatePlayerListBox public class TEReagentConduit extends TileSegmentedReagentHandler implements IUpdatePlayerListBox
{ {

View file

@ -1,131 +1,126 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack;
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStacks; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStacks;
import minetweaker.IUndoableAction; //import net.minecraft.item.ItemStack;
import minetweaker.MineTweakerAPI; //import WayofTime.alchemicalWizardry.api.alchemy.AlchemyRecipe;
import minetweaker.api.item.IItemStack; //import WayofTime.alchemicalWizardry.api.alchemy.AlchemyRecipeRegistry;
import net.minecraft.item.ItemStack; //
import stanhebben.zenscript.annotations.ZenClass; ///**
import stanhebben.zenscript.annotations.ZenMethod; // * MineTweaker3 Alchemy Recipe Handler by joshie *
import WayofTime.alchemicalWizardry.api.alchemy.AlchemyRecipe; // */
import WayofTime.alchemicalWizardry.api.alchemy.AlchemyRecipeRegistry; //@ZenClass("mods.bloodmagic.Alchemy")
//public class Alchemy
/** //{
* MineTweaker3 Alchemy Recipe Handler by joshie * // @ZenMethod
*/ // public static void addRecipe(IItemStack output, IItemStack[] input, int tier, int lp) {
@ZenClass("mods.bloodmagic.Alchemy") // MineTweakerAPI.apply(new Add(new AlchemyRecipe(toStack(output), (int) (((double) lp) / 100), toStacks(input), tier)));
public class Alchemy // }
{ //
@ZenMethod // private static class Add implements IUndoableAction
public static void addRecipe(IItemStack output, IItemStack[] input, int tier, int lp) { // {
MineTweakerAPI.apply(new Add(new AlchemyRecipe(toStack(output), (int) (((double) lp) / 100), toStacks(input), tier))); // private final AlchemyRecipe recipe;
} //
// public Add(AlchemyRecipe recipe)
private static class Add implements IUndoableAction // {
{ // this.recipe = recipe;
private final AlchemyRecipe recipe; // }
//
public Add(AlchemyRecipe recipe) // @Override
{ // public void apply()
this.recipe = recipe; // {
} // AlchemyRecipeRegistry.recipes.add(recipe);
// }
@Override //
public void apply() // @Override
{ // public boolean canUndo()
AlchemyRecipeRegistry.recipes.add(recipe); // {
} // return AlchemyRecipeRegistry.recipes != null;
// }
@Override //
public boolean canUndo() // @Override
{ // public void undo()
return AlchemyRecipeRegistry.recipes != null; // {
} // AlchemyRecipeRegistry.recipes.remove(recipe);
// }
@Override //
public void undo() // @Override
{ // public String describe()
AlchemyRecipeRegistry.recipes.remove(recipe); // {
} // return "Adding Alchemy Recipe for " + ((AlchemyRecipe) recipe).getResult().getDisplayName();
// }
@Override //
public String describe() // @Override
{ // public String describeUndo()
return "Adding Alchemy Recipe for " + ((AlchemyRecipe) recipe).getResult().getDisplayName(); // {
} // return "Removing Alchemy Recipe for " + ((AlchemyRecipe) recipe).getResult().getDisplayName();
// }
@Override //
public String describeUndo() // @Override
{ // public Object getOverrideKey()
return "Removing Alchemy Recipe for " + ((AlchemyRecipe) recipe).getResult().getDisplayName(); // {
} // return null;
// }
@Override // }
public Object getOverrideKey() //
{ // @ZenMethod
return null; // public static void removeRecipe(IItemStack output) {
} // MineTweakerAPI.apply(new Remove(toStack(output)));
} // }
//
@ZenMethod // private static class Remove implements IUndoableAction
public static void removeRecipe(IItemStack output) { // {
MineTweakerAPI.apply(new Remove(toStack(output))); // private final ItemStack output;
} // private AlchemyRecipe recipe;
//
private static class Remove implements IUndoableAction // public Remove(ItemStack output)
{ // {
private final ItemStack output; // this.output = output;
private AlchemyRecipe recipe; // }
//
public Remove(ItemStack output) // @Override
{ // public void apply()
this.output = output; // {
} // for (AlchemyRecipe r : AlchemyRecipeRegistry.recipes)
// {
@Override // if (r.getResult() != null && r.getResult().isItemEqual(output))
public void apply() // {
{ // recipe = r;
for (AlchemyRecipe r : AlchemyRecipeRegistry.recipes) // break;
{ // }
if (r.getResult() != null && r.getResult().isItemEqual(output)) // }
{ //
recipe = r; // AlchemyRecipeRegistry.recipes.remove(recipe);
break; // }
} //
} // @Override
// public boolean canUndo()
AlchemyRecipeRegistry.recipes.remove(recipe); // {
} // return AlchemyRecipeRegistry.recipes != null && recipe != null;
// }
@Override //
public boolean canUndo() // @Override
{ // public void undo()
return AlchemyRecipeRegistry.recipes != null && recipe != null; // {
} // AlchemyRecipeRegistry.recipes.add(recipe);
// }
@Override //
public void undo() // @Override
{ // public String describe()
AlchemyRecipeRegistry.recipes.add(recipe); // {
} // return "Removing Alchemy Recipe for " + output.getDisplayName();
// }
@Override //
public String describe() // @Override
{ // public String describeUndo()
return "Removing Alchemy Recipe for " + output.getDisplayName(); // {
} // return "Restoring Alchemy Recipe for " + output.getDisplayName();
// }
@Override //
public String describeUndo() // @Override
{ // public Object getOverrideKey()
return "Restoring Alchemy Recipe for " + output.getDisplayName(); // {
} // return null;
// }
@Override // }
public Object getOverrideKey() //}
{
return null;
}
}
}

View file

@ -1,130 +1,130 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack;
import minetweaker.IUndoableAction; //import minetweaker.IUndoableAction;
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import stanhebben.zenscript.annotations.ZenClass; //import stanhebben.zenscript.annotations.ZenClass;
import stanhebben.zenscript.annotations.ZenMethod; //import stanhebben.zenscript.annotations.ZenMethod;
import WayofTime.alchemicalWizardry.api.bindingRegistry.BindingRecipe; //import WayofTime.alchemicalWizardry.api.bindingRegistry.BindingRecipe;
import WayofTime.alchemicalWizardry.api.bindingRegistry.BindingRegistry; //import WayofTime.alchemicalWizardry.api.bindingRegistry.BindingRegistry;
//
/** ///**
* MineTweaker3 Binding Recipe Handler by joshie * // * MineTweaker3 Binding Recipe Handler by joshie *
*/ // */
@ZenClass("mods.bloodmagic.Binding") //@ZenClass("mods.bloodmagic.Binding")
public class Binding //public class Binding
{ //{
@ZenMethod // @ZenMethod
public static void addRecipe(IItemStack input, IItemStack output) { // public static void addRecipe(IItemStack input, IItemStack output) {
MineTweakerAPI.apply(new Add(new BindingRecipe(toStack(output), toStack(input)))); // MineTweakerAPI.apply(new Add(new BindingRecipe(toStack(output), toStack(input))));
} // }
//
private static class Add implements IUndoableAction // private static class Add implements IUndoableAction
{ // {
private final BindingRecipe recipe; // private final BindingRecipe recipe;
//
public Add(BindingRecipe recipe) // public Add(BindingRecipe recipe)
{ // {
this.recipe = recipe; // this.recipe = recipe;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
BindingRegistry.bindingRecipes.add(recipe); // BindingRegistry.bindingRecipes.add(recipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return BindingRegistry.bindingRecipes != null; // return BindingRegistry.bindingRecipes != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
BindingRegistry.bindingRecipes.remove(recipe); // BindingRegistry.bindingRecipes.remove(recipe);
} // }
//
@Override // @Override
public String describe() // public String describe()
{ // {
return "Adding Binding Recipe for " + ((BindingRecipe) recipe).getResult().getDisplayName(); // return "Adding Binding Recipe for " + ((BindingRecipe) recipe).getResult().getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Removing Binding Recipe for " + ((BindingRecipe) recipe).getResult().getDisplayName(); // return "Removing Binding Recipe for " + ((BindingRecipe) recipe).getResult().getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
//
@ZenMethod // @ZenMethod
public static void removeRecipe(IItemStack output) { // public static void removeRecipe(IItemStack output) {
MineTweakerAPI.apply(new Remove(toStack(output))); // MineTweakerAPI.apply(new Remove(toStack(output)));
} // }
//
private static class Remove implements IUndoableAction // private static class Remove implements IUndoableAction
{ // {
private final ItemStack output; // private final ItemStack output;
private BindingRecipe recipe; // private BindingRecipe recipe;
//
public Remove(ItemStack output) // public Remove(ItemStack output)
{ // {
this.output = output; // this.output = output;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
for (BindingRecipe r : BindingRegistry.bindingRecipes) // for (BindingRecipe r : BindingRegistry.bindingRecipes)
{ // {
if (r.getResult() != null && r.getResult().isItemEqual(output)) // if (r.getResult() != null && r.getResult().isItemEqual(output))
{ // {
recipe = r; // recipe = r;
break; // break;
} // }
} // }
//
BindingRegistry.bindingRecipes.remove(recipe); // BindingRegistry.bindingRecipes.remove(recipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return BindingRegistry.bindingRecipes != null && recipe != null; // return BindingRegistry.bindingRecipes != null && recipe != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
BindingRegistry.bindingRecipes.add(recipe); // BindingRegistry.bindingRecipes.add(recipe);
} // }
//
@Override // @Override
public String describe() // public String describe()
{ // {
return "Removing Binding Recipe for " + output.getDisplayName(); // return "Removing Binding Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Restoring Binding Recipe for " + output.getDisplayName(); // return "Restoring Binding Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
} //}

View file

@ -1,133 +1,133 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack;
import minetweaker.IUndoableAction; //import minetweaker.IUndoableAction;
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import stanhebben.zenscript.annotations.Optional; //import stanhebben.zenscript.annotations.Optional;
import stanhebben.zenscript.annotations.ZenClass; //import stanhebben.zenscript.annotations.ZenClass;
import stanhebben.zenscript.annotations.ZenMethod; //import stanhebben.zenscript.annotations.ZenMethod;
import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipe; //import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipe;
import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipeRegistry; //import WayofTime.alchemicalWizardry.api.altarRecipeRegistry.AltarRecipeRegistry;
//
/** ///**
* MineTweaker3 Blood Altar Recipe Handler by joshie * // * MineTweaker3 Blood Altar Recipe Handler by joshie *
*/ // */
@ZenClass("mods.bloodmagic.Altar") //@ZenClass("mods.bloodmagic.Altar")
public class BloodAltar //public class BloodAltar
{ //{
@ZenMethod // @ZenMethod
public static void addRecipe(IItemStack output, IItemStack input, int tier, int lp, @Optional int consume, @Optional int drain) { // public static void addRecipe(IItemStack output, IItemStack input, int tier, int lp, @Optional int consume, @Optional int drain) {
consume = consume > 0 ? consume : 20; // consume = consume > 0 ? consume : 20;
drain = drain > 0 ? drain : 20; // drain = drain > 0 ? drain : 20;
MineTweakerAPI.apply(new Add(new AltarRecipe(toStack(output), toStack(input), tier, lp, consume, drain, false))); // MineTweakerAPI.apply(new Add(new AltarRecipe(toStack(output), toStack(input), tier, lp, consume, drain, false)));
} // }
//
private static class Add implements IUndoableAction // private static class Add implements IUndoableAction
{ // {
private final AltarRecipe recipe; // private final AltarRecipe recipe;
//
public Add(AltarRecipe recipe) // public Add(AltarRecipe recipe)
{ // {
this.recipe = recipe; // this.recipe = recipe;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
AltarRecipeRegistry.altarRecipes.add(recipe); // AltarRecipeRegistry.altarRecipes.add(recipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return AltarRecipeRegistry.altarRecipes != null; // return AltarRecipeRegistry.altarRecipes != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
AltarRecipeRegistry.altarRecipes.remove(recipe); // AltarRecipeRegistry.altarRecipes.remove(recipe);
} // }
//
@Override // @Override
public String describe() // public String describe()
{ // {
return "Adding Blood Altar Recipe for " + ((AltarRecipe) recipe).getResult().getDisplayName(); // return "Adding Blood Altar Recipe for " + ((AltarRecipe) recipe).getResult().getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Removing Blood Altar Recipe for " + ((AltarRecipe) recipe).getResult().getDisplayName(); // return "Removing Blood Altar Recipe for " + ((AltarRecipe) recipe).getResult().getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
//
@ZenMethod // @ZenMethod
public static void removeRecipe(IItemStack output) { // public static void removeRecipe(IItemStack output) {
MineTweakerAPI.apply(new Remove(toStack(output))); // MineTweakerAPI.apply(new Remove(toStack(output)));
} // }
//
private static class Remove implements IUndoableAction // private static class Remove implements IUndoableAction
{ // {
private final ItemStack output; // private final ItemStack output;
private AltarRecipe recipe; // private AltarRecipe recipe;
//
public Remove(ItemStack output) // public Remove(ItemStack output)
{ // {
this.output = output; // this.output = output;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
for (AltarRecipe r : AltarRecipeRegistry.altarRecipes) // for (AltarRecipe r : AltarRecipeRegistry.altarRecipes)
{ // {
if (r.getResult() != null && r.getResult().isItemEqual(output)) // if (r.getResult() != null && r.getResult().isItemEqual(output))
{ // {
recipe = r; // recipe = r;
break; // break;
} // }
} // }
//
AltarRecipeRegistry.altarRecipes.remove(recipe); // AltarRecipeRegistry.altarRecipes.remove(recipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return AltarRecipeRegistry.altarRecipes != null && recipe != null; // return AltarRecipeRegistry.altarRecipes != null && recipe != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
AltarRecipeRegistry.altarRecipes.add(recipe); // AltarRecipeRegistry.altarRecipes.add(recipe);
} // }
//
@Override // @Override
public String describe() // public String describe()
{ // {
return "Removing Blood Altar Recipe for " + output.getDisplayName(); // return "Removing Blood Altar Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Restoring Blood Altar Recipe for " + output.getDisplayName(); // return "Restoring Blood Altar Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
} //}

View file

@ -1,147 +1,147 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toObjects; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toObjects;
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toShapedObjects; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toShapedObjects;
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack;
//
import java.util.List; //import java.util.List;
//
import WayofTime.alchemicalWizardry.api.items.ShapelessBloodOrbRecipe; //import WayofTime.alchemicalWizardry.api.items.ShapelessBloodOrbRecipe;
import minetweaker.IUndoableAction; //import minetweaker.IUndoableAction;
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
import minetweaker.api.item.IIngredient; //import minetweaker.api.item.IIngredient;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.CraftingManager; //import net.minecraft.item.crafting.CraftingManager;
import net.minecraft.item.crafting.IRecipe; //import net.minecraft.item.crafting.IRecipe;
import stanhebben.zenscript.annotations.ZenClass; //import stanhebben.zenscript.annotations.ZenClass;
import stanhebben.zenscript.annotations.ZenMethod; //import stanhebben.zenscript.annotations.ZenMethod;
import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe; //import WayofTime.alchemicalWizardry.api.items.ShapedBloodOrbRecipe;
//
/** ///**
* MineTweaker3 Blood Orb Recipe Handler by joshie * // * MineTweaker3 Blood Orb Recipe Handler by joshie *
*/ // */
@ZenClass("mods.bloodmagic.BloodOrb") //@ZenClass("mods.bloodmagic.BloodOrb")
public class BloodOrb //public class BloodOrb
{ //{
@ZenMethod // @ZenMethod
public static void addShaped(IItemStack output, IIngredient[][] ingredients) // public static void addShaped(IItemStack output, IIngredient[][] ingredients)
{ // {
MineTweakerAPI.apply(new Add(false, toStack(output), toShapedObjects(ingredients))); // MineTweakerAPI.apply(new Add(false, toStack(output), toShapedObjects(ingredients)));
} // }
//
@ZenMethod // @ZenMethod
public static void addShapeless(IItemStack output, IIngredient[] ingredients) // public static void addShapeless(IItemStack output, IIngredient[] ingredients)
{ // {
MineTweakerAPI.apply(new Add(true, toStack(output), toObjects(ingredients))); // MineTweakerAPI.apply(new Add(true, toStack(output), toObjects(ingredients)));
} // }
//
private static class Add implements IUndoableAction { // private static class Add implements IUndoableAction {
private IRecipe iRecipe; // private IRecipe iRecipe;
private final boolean isShapeless; // private final boolean isShapeless;
private final ItemStack output; // private final ItemStack output;
private final Object[] recipe; // private final Object[] recipe;
//
public Add(boolean isShapeless, ItemStack output, Object... recipe) // public Add(boolean isShapeless, ItemStack output, Object... recipe)
{ // {
this.isShapeless = isShapeless; // this.isShapeless = isShapeless;
this.output = output; // this.output = output;
this.recipe = recipe; // this.recipe = recipe;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
if (isShapeless) iRecipe = new ShapelessBloodOrbRecipe(output, recipe); // if (isShapeless) iRecipe = new ShapelessBloodOrbRecipe(output, recipe);
else iRecipe = new ShapedBloodOrbRecipe(output, recipe); // else iRecipe = new ShapedBloodOrbRecipe(output, recipe);
CraftingManager.getInstance().getRecipeList().add(iRecipe); // CraftingManager.getInstance().getRecipeList().add(iRecipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return CraftingManager.getInstance().getRecipeList() != null; // return CraftingManager.getInstance().getRecipeList() != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
CraftingManager.getInstance().getRecipeList().remove(iRecipe); // CraftingManager.getInstance().getRecipeList().remove(iRecipe);
} // }
//
@Override // @Override
public String describe() { // public String describe() {
return "Adding Blood Orb Recipe for " + output.getDisplayName(); // return "Adding Blood Orb Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Removing Blood Orb Recipe for " + output.getDisplayName(); // return "Removing Blood Orb Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
//
@ZenMethod // @ZenMethod
public static void removeRecipe(IItemStack output) { // public static void removeRecipe(IItemStack output) {
MineTweakerAPI.apply(new Remove(toStack(output))); // MineTweakerAPI.apply(new Remove(toStack(output)));
} // }
//
private static class Remove implements IUndoableAction { // private static class Remove implements IUndoableAction {
private final ItemStack output; // private final ItemStack output;
private IRecipe iRecipe; // private IRecipe iRecipe;
//
public Remove(ItemStack output) // public Remove(ItemStack output)
{ // {
this.output = output; // this.output = output;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
for (IRecipe r : (List<IRecipe>) CraftingManager.getInstance().getRecipeList()) // for (IRecipe r : (List<IRecipe>) CraftingManager.getInstance().getRecipeList())
{ // {
if((r instanceof ShapedBloodOrbRecipe || r instanceof ShapelessBloodOrbRecipe) && r.getRecipeOutput() != null && r.getRecipeOutput().isItemEqual(output)) { // if((r instanceof ShapedBloodOrbRecipe || r instanceof ShapelessBloodOrbRecipe) && r.getRecipeOutput() != null && r.getRecipeOutput().isItemEqual(output)) {
iRecipe = r; // iRecipe = r;
break; // break;
} // }
} // }
//
CraftingManager.getInstance().getRecipeList().remove(iRecipe); // CraftingManager.getInstance().getRecipeList().remove(iRecipe);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return CraftingManager.getInstance().getRecipeList() != null && iRecipe != null; // return CraftingManager.getInstance().getRecipeList() != null && iRecipe != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
CraftingManager.getInstance().getRecipeList().add(iRecipe); // CraftingManager.getInstance().getRecipeList().add(iRecipe);
} // }
//
@Override // @Override
public String describe() { // public String describe() {
return "Removing Blood Orb Recipe for " + output.getDisplayName(); // return "Removing Blood Orb Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Restoring Blood Orb Recipe for " + output.getDisplayName(); // return "Restoring Blood Orb Recipe for " + output.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
} //}

View file

@ -1,139 +1,139 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorParadigm; //import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorParadigm;
import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorRegistry; //import WayofTime.alchemicalWizardry.common.summoning.meteor.MeteorRegistry;
import minetweaker.IUndoableAction; //import minetweaker.IUndoableAction;
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import net.minecraftforge.oredict.OreDictionary; //import net.minecraftforge.oredict.OreDictionary;
import stanhebben.zenscript.annotations.ZenClass; //import stanhebben.zenscript.annotations.ZenClass;
import stanhebben.zenscript.annotations.ZenMethod; //import stanhebben.zenscript.annotations.ZenMethod;
//
import java.util.Iterator; //import java.util.Iterator;
//
import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack; //import static WayofTime.alchemicalWizardry.common.tweaker.MTHelper.toStack;
//
/** ///**
* MineTweaker3 Falling Tower Paradigm Handler by hilburn * // * MineTweaker3 Falling Tower Paradigm Handler by hilburn *
*/ // */
@ZenClass("mods.bloodmagic.FallingTower") //@ZenClass("mods.bloodmagic.FallingTower")
public class FallingTower //public class FallingTower
{ //{
@ZenMethod // @ZenMethod
public static void addFocus(IItemStack stack, int radius, String[] components) // public static void addFocus(IItemStack stack, int radius, String[] components)
{ // {
MineTweakerAPI.apply(new Add(toStack(stack),radius, components)); // MineTweakerAPI.apply(new Add(toStack(stack),radius, components));
} // }
//
@ZenMethod // @ZenMethod
public static void addFocus(IItemStack stack, int radius, String components) // public static void addFocus(IItemStack stack, int radius, String components)
{ // {
MineTweakerAPI.apply(new Add(toStack(stack),radius, components.split("\\s*,\\s*"))); // MineTweakerAPI.apply(new Add(toStack(stack),radius, components.split("\\s*,\\s*")));
} // }
//
@ZenMethod // @ZenMethod
public static void removeFocus(IItemStack output) { // public static void removeFocus(IItemStack output) {
MineTweakerAPI.apply(new Remove(toStack(output))); // MineTweakerAPI.apply(new Remove(toStack(output)));
} // }
//
private static class Add implements IUndoableAction // private static class Add implements IUndoableAction
{ // {
private MeteorParadigm paradigm; // private MeteorParadigm paradigm;
//
public Add(ItemStack stack, int radius, String[] components) // public Add(ItemStack stack, int radius, String[] components)
{ // {
paradigm = new MeteorParadigm(stack,radius); // paradigm = new MeteorParadigm(stack,radius);
paradigm.parseStringArray(components); // paradigm.parseStringArray(components);
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
MeteorRegistry.registerMeteorParadigm(paradigm); // MeteorRegistry.registerMeteorParadigm(paradigm);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return MeteorRegistry.paradigmList!= null; // return MeteorRegistry.paradigmList!= null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
MeteorRegistry.paradigmList.remove(paradigm); // MeteorRegistry.paradigmList.remove(paradigm);
} // }
//
@Override // @Override
public String describe() { // public String describe() {
return "Adding Falling Tower Focus for " + paradigm.focusStack.getDisplayName(); // return "Adding Falling Tower Focus for " + paradigm.focusStack.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Removing Falling Tower Focus for " + paradigm.focusStack.getDisplayName(); // return "Removing Falling Tower Focus for " + paradigm.focusStack.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
//
private static class Remove implements IUndoableAction { // private static class Remove implements IUndoableAction {
private final ItemStack focus; // private final ItemStack focus;
private MeteorParadigm paradigm; // private MeteorParadigm paradigm;
//
public Remove(ItemStack focus) // public Remove(ItemStack focus)
{ // {
this.focus = focus; // this.focus = focus;
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
for (Iterator<MeteorParadigm> itr = MeteorRegistry.paradigmList.iterator(); itr.hasNext();) // for (Iterator<MeteorParadigm> itr = MeteorRegistry.paradigmList.iterator(); itr.hasNext();)
{ // {
MeteorParadigm paradigm = itr.next(); // MeteorParadigm paradigm = itr.next();
if (OreDictionary.itemMatches(paradigm.focusStack,focus,false)) // if (OreDictionary.itemMatches(paradigm.focusStack,focus,false))
{ // {
this.paradigm = paradigm; // this.paradigm = paradigm;
itr.remove(); // itr.remove();
break; // break;
} // }
} // }
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return MeteorRegistry.paradigmList!= null && paradigm != null; // return MeteorRegistry.paradigmList!= null && paradigm != null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
MeteorRegistry.paradigmList.add(paradigm); // MeteorRegistry.paradigmList.add(paradigm);
} // }
//
@Override // @Override
public String describe() { // public String describe() {
return "Removing Falling Tower Focus for " + focus.getDisplayName(); // return "Removing Falling Tower Focus for " + focus.getDisplayName();
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Restoring Falling Tower Focus for " + focus.getDisplayName(); // return "Restoring Falling Tower Focus for " + focus.getDisplayName();
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
} //}

View file

@ -1,90 +1,90 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import WayofTime.alchemicalWizardry.api.harvest.HarvestRegistry; //import WayofTime.alchemicalWizardry.api.harvest.HarvestRegistry;
import WayofTime.alchemicalWizardry.api.harvest.IHarvestHandler; //import WayofTime.alchemicalWizardry.api.harvest.IHarvestHandler;
import WayofTime.alchemicalWizardry.common.harvest.GenericItemStackHarvestHandler; //import WayofTime.alchemicalWizardry.common.harvest.GenericItemStackHarvestHandler;
import minetweaker.IUndoableAction; //import minetweaker.IUndoableAction;
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import net.minecraft.block.Block; //import net.minecraft.block.Block;
import net.minecraft.init.Blocks; //import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
import net.minecraftforge.common.IPlantable; //import net.minecraftforge.common.IPlantable;
import stanhebben.zenscript.annotations.ZenClass; //import stanhebben.zenscript.annotations.ZenClass;
import stanhebben.zenscript.annotations.ZenMethod; //import stanhebben.zenscript.annotations.ZenMethod;
//
/** ///**
* MineTweaker3 Harvest Moon Handler by hilburn * // * MineTweaker3 Harvest Moon Handler by hilburn *
*/ // */
@ZenClass("mods.bloodmagic.HarvestMoon") //@ZenClass("mods.bloodmagic.HarvestMoon")
public class HarvestMoon //public class HarvestMoon
{ //{
//
@ZenMethod // @ZenMethod
public static void addHarvestable(IItemStack block, IItemStack seed) // public static void addHarvestable(IItemStack block, IItemStack seed)
{ // {
addHarvestable(block,block.getDamage(),seed); // addHarvestable(block,block.getDamage(),seed);
} // }
//
@ZenMethod // @ZenMethod
public static void addHarvestable(IItemStack block, int meta, IItemStack seed) // public static void addHarvestable(IItemStack block, int meta, IItemStack seed)
{ // {
ItemStack seedStack = MTHelper.toStack(seed); // ItemStack seedStack = MTHelper.toStack(seed);
Block plantBlock = Block.getBlockFromItem(MTHelper.toStack(block).getItem()); // Block plantBlock = Block.getBlockFromItem(MTHelper.toStack(block).getItem());
if (!(plantBlock==null || plantBlock== Blocks.air || seedStack==null || !(seedStack.getItem() instanceof IPlantable))) // if (!(plantBlock==null || plantBlock== Blocks.air || seedStack==null || !(seedStack.getItem() instanceof IPlantable)))
{ // {
MineTweakerAPI.apply(new Add(plantBlock, meta, seedStack)); // MineTweakerAPI.apply(new Add(plantBlock, meta, seedStack));
} // }
else // else
{ // {
throw new IllegalArgumentException("Invalid Harvest Block or Seed"); // throw new IllegalArgumentException("Invalid Harvest Block or Seed");
} // }
} // }
//
private static class Add implements IUndoableAction // private static class Add implements IUndoableAction
{ // {
private IHarvestHandler handler; // private IHarvestHandler handler;
private String name; // private String name;
//
public Add(Block block, int meta, ItemStack seed) // public Add(Block block, int meta, ItemStack seed)
{ // {
handler = new GenericItemStackHarvestHandler(block,meta,seed); // handler = new GenericItemStackHarvestHandler(block,meta,seed);
name = seed.getDisplayName(); // name = seed.getDisplayName();
} // }
//
@Override // @Override
public void apply() // public void apply()
{ // {
HarvestRegistry.registerHarvestHandler(handler); // HarvestRegistry.registerHarvestHandler(handler);
} // }
//
@Override // @Override
public boolean canUndo() // public boolean canUndo()
{ // {
return HarvestRegistry.handlerList!=null; // return HarvestRegistry.handlerList!=null;
} // }
//
@Override // @Override
public void undo() // public void undo()
{ // {
HarvestRegistry.handlerList.remove(handler); // HarvestRegistry.handlerList.remove(handler);
} // }
//
@Override // @Override
public String describe() { // public String describe() {
return "Adding Harvest Moon Support for " + name; // return "Adding Harvest Moon Support for " + name;
} // }
//
@Override // @Override
public String describeUndo() // public String describeUndo()
{ // {
return "Removing Harvest Moon Support for " + name; // return "Removing Harvest Moon Support for " + name;
} // }
//
@Override // @Override
public Object getOverrideKey() // public Object getOverrideKey()
{ // {
return null; // return null;
} // }
} // }
} //}

View file

@ -1,82 +1,82 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import static minetweaker.api.minecraft.MineTweakerMC.getItemStack; //import static minetweaker.api.minecraft.MineTweakerMC.getItemStack;
//
import java.util.ArrayList; //import java.util.ArrayList;
//
import minetweaker.api.item.IIngredient; //import minetweaker.api.item.IIngredient;
import minetweaker.api.item.IItemStack; //import minetweaker.api.item.IItemStack;
import minetweaker.api.oredict.IOreDictEntry; //import minetweaker.api.oredict.IOreDictEntry;
import net.minecraft.item.ItemStack; //import net.minecraft.item.ItemStack;
//
/** ///**
* MineTweaker3 Helper by joshie * // * MineTweaker3 Helper by joshie *
*/ // */
public class MTHelper { //public class MTHelper {
public static ItemStack toStack(IItemStack iStack) { // public static ItemStack toStack(IItemStack iStack) {
return getItemStack(iStack); // return getItemStack(iStack);
} // }
//
public static ItemStack[] toStacks(IItemStack[] iStack) { // public static ItemStack[] toStacks(IItemStack[] iStack) {
if (iStack == null) return null; // if (iStack == null) return null;
else { // else {
ItemStack[] output = new ItemStack[iStack.length]; // ItemStack[] output = new ItemStack[iStack.length];
for (int i = 0; i < iStack.length; i++) { // for (int i = 0; i < iStack.length; i++) {
output[i] = toStack(iStack[i]); // output[i] = toStack(iStack[i]);
} // }
//
return output; // return output;
} // }
} // }
//
public static Object toObject(IIngredient iStack) { // public static Object toObject(IIngredient iStack) {
if (iStack == null) return null; // if (iStack == null) return null;
else { // else {
if (iStack instanceof IOreDictEntry) { // if (iStack instanceof IOreDictEntry) {
return toString((IOreDictEntry) iStack); // return toString((IOreDictEntry) iStack);
} else if (iStack instanceof IItemStack) { // } else if (iStack instanceof IItemStack) {
return getItemStack((IItemStack) iStack); // return getItemStack((IItemStack) iStack);
} else return null; // } else return null;
} // }
} // }
//
public static Object[] toObjects(IIngredient[] ingredient) { // public static Object[] toObjects(IIngredient[] ingredient) {
if (ingredient == null) return null; // if (ingredient == null) return null;
else { // else {
Object[] output = new Object[ingredient.length]; // Object[] output = new Object[ingredient.length];
for (int i = 0; i < ingredient.length; i++) { // for (int i = 0; i < ingredient.length; i++) {
if (ingredient[i] != null) { // if (ingredient[i] != null) {
output[i] = toObject(ingredient[i]); // output[i] = toObject(ingredient[i]);
} else output[i] = ""; // } else output[i] = "";
} // }
//
return output; // return output;
} // }
} // }
//
public static Object[] toShapedObjects(IIngredient[][] ingredients) { // public static Object[] toShapedObjects(IIngredient[][] ingredients) {
if (ingredients == null) return null; // if (ingredients == null) return null;
else { // else {
ArrayList prep = new ArrayList(); // ArrayList prep = new ArrayList();
prep.add("abc"); // prep.add("abc");
prep.add("def"); // prep.add("def");
prep.add("ghi"); // prep.add("ghi");
char[][] map = new char[][] { { 'a', 'b', 'c' }, { 'd', 'e', 'f' }, { 'g', 'h', 'i' } }; // char[][] map = new char[][] { { 'a', 'b', 'c' }, { 'd', 'e', 'f' }, { 'g', 'h', 'i' } };
for (int x = 0; x < ingredients.length; x++) { // for (int x = 0; x < ingredients.length; x++) {
if (ingredients[x] != null) { // if (ingredients[x] != null) {
for (int y = 0; y < ingredients[x].length; y++) { // for (int y = 0; y < ingredients[x].length; y++) {
if (ingredients[x][y] != null && x < map.length && y < map[x].length) { // if (ingredients[x][y] != null && x < map.length && y < map[x].length) {
prep.add(map[x][y]); // prep.add(map[x][y]);
prep.add(toObject(ingredients[x][y])); // prep.add(toObject(ingredients[x][y]));
} // }
} // }
} // }
} // }
return prep.toArray(); // return prep.toArray();
} // }
} // }
//
public static String toString(IOreDictEntry entry) { // public static String toString(IOreDictEntry entry) {
return ((IOreDictEntry) entry).getName(); // return ((IOreDictEntry) entry).getName();
} // }
} //}

View file

@ -1,19 +1,19 @@
package WayofTime.alchemicalWizardry.common.tweaker; //package WayofTime.alchemicalWizardry.common.tweaker;
//
import minetweaker.MineTweakerAPI; //import minetweaker.MineTweakerAPI;
//
/** ///**
* MineTweaker3 Integration by joshie * // * MineTweaker3 Integration by joshie *
*/ // */
public class MineTweakerIntegration //public class MineTweakerIntegration
{ //{
public static void register() // public static void register()
{ // {
MineTweakerAPI.registerClass(Alchemy.class); // MineTweakerAPI.registerClass(Alchemy.class);
MineTweakerAPI.registerClass(Binding.class); // MineTweakerAPI.registerClass(Binding.class);
MineTweakerAPI.registerClass(BloodAltar.class); // MineTweakerAPI.registerClass(BloodAltar.class);
MineTweakerAPI.registerClass(BloodOrb.class); // MineTweakerAPI.registerClass(BloodOrb.class);
MineTweakerAPI.registerClass(FallingTower.class); // MineTweakerAPI.registerClass(FallingTower.class);
MineTweakerAPI.registerClass(HarvestMoon.class); // MineTweakerAPI.registerClass(HarvestMoon.class);
} // }
} //}