Revert "Fixed Teleposers"

This reverts commit da9866ac8f.
This commit is contained in:
Arcaratus 2015-05-11 19:05:14 -04:00
parent da9866ac8f
commit 307184fb85
15 changed files with 116 additions and 78 deletions

View file

@ -113,6 +113,7 @@ import WayofTime.alchemicalWizardry.common.harvest.GourdHarvestHandler;
import WayofTime.alchemicalWizardry.common.harvest.PamHarvestCompatRegistry; import WayofTime.alchemicalWizardry.common.harvest.PamHarvestCompatRegistry;
import WayofTime.alchemicalWizardry.common.items.ItemRitualDiviner; import WayofTime.alchemicalWizardry.common.items.ItemRitualDiviner;
import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmour; import WayofTime.alchemicalWizardry.common.items.armour.OmegaArmour;
import WayofTime.alchemicalWizardry.common.items.forestry.ItemBloodFrame;
import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfHolding; import WayofTime.alchemicalWizardry.common.items.sigil.SigilOfHolding;
import WayofTime.alchemicalWizardry.common.items.thaumcraft.ItemSanguineArmour; import WayofTime.alchemicalWizardry.common.items.thaumcraft.ItemSanguineArmour;
import WayofTime.alchemicalWizardry.common.omega.OmegaParadigmEarth; import WayofTime.alchemicalWizardry.common.omega.OmegaParadigmEarth;
@ -1190,14 +1191,14 @@ public class AlchemicalWizardry
{ {
this.isForestryLoaded = true; this.isForestryLoaded = true;
// ModItems.itemBloodFrame = new ItemBloodFrame(this.itemBloodFrameItemID).setUnlocalizedName("bloodFrame"); ModItems.itemBloodFrame = new ItemBloodFrame().setUnlocalizedName("bloodFrame");
//
// ItemStack provenFrame = GameRegistry.findItemStack("Forestry", "frameImpregnated", 1); ItemStack provenFrame = GameRegistry.findItemStack("Forestry", "frameImpregnated", 1);
//
// if(provenFrame !=null) if(provenFrame !=null)
// { {
// AltarRecipeRegistry.registerAltarRecipe(new ItemStack(ModItems.itemBloodFrame), provenFrame, 3, 30000, 20, 20, false); AltarRecipeRegistry.registerAltarRecipe(new ItemStack(ModItems.itemBloodFrame), provenFrame, 3, 30000, 20, 20, false);
// } }
} else } else
{ {
this.isForestryLoaded = false; this.isForestryLoaded = false;
@ -1397,7 +1398,7 @@ public class AlchemicalWizardry
Rituals.registerRitual("AW010Crusher", 1, 2500, new RitualEffectCrushing(), "Ritual of the Crusher", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW010Crusher", 1, 2500, new RitualEffectCrushing(), "Ritual of the Crusher", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));
Rituals.registerRitual("AW011Speed", 1, 1000, new RitualEffectLeap(), "Ritual of Speed", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW011Speed", 1, 1000, new RitualEffectLeap(), "Ritual of Speed", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));
Rituals.registerRitual("AW012AnimalGrowth", 1, 10000, new RitualEffectAnimalGrowth(), "Ritual of the Shepherd", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW012AnimalGrowth", 1, 10000, new RitualEffectAnimalGrowth(), "Ritual of the Shepherd", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));
Rituals.registerRitual("AW013Suffering", 1, 50000, new RitualEffectWellOfSuffering(), "Well of Suffering", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/TransCircleSuffering.png"), 0, 0, 0, 255, 0, 0.501, 0.8, 0, 2.5, true)); Rituals.registerRitual("AW013Suffering", 1, 50000, new RitualEffectWellOfSuffering(), "Well of Suffering", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/AlchemyArrays/WellOfSufferingArray.png"), 0, 0, 0, 255, 0, 0.501, 0.8, 0, 2.5, true));
Rituals.registerRitual("AW014Regen", 1, 25000, new RitualEffectHealing(), "Ritual of Regeneration", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW014Regen", 1, 25000, new RitualEffectHealing(), "Ritual of Regeneration", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));
Rituals.registerRitual("AW015FeatheredKnife", 1, 50000, new RitualEffectFeatheredKnife(), "Ritual of the Feathered Knife", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW015FeatheredKnife", 1, 50000, new RitualEffectFeatheredKnife(), "Ritual of the Feathered Knife", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));
Rituals.registerRitual("AW016FeatheredEarth", 2, 100000, new RitualEffectFeatheredEarth(), "Ritual of the Feathered Earth", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false)); Rituals.registerRitual("AW016FeatheredEarth", 2, 100000, new RitualEffectFeatheredEarth(), "Ritual of the Feathered Earth", new AlchemyCircleRenderer(new ResourceLocation("alchemicalwizardry:textures/models/SimpleTransCircle.png"), 0, 0, 0, 255, 0, 0.501, 0.501, 0, 1.5, false));

View file

@ -166,11 +166,11 @@ public class BloodMagicConfiguration
BoundArmour.tryComplexRendering = config.get("WimpySettings", "UseFancyBoundArmour", true).getBoolean(true); BoundArmour.tryComplexRendering = config.get("WimpySettings", "UseFancyBoundArmour", true).getBoolean(true);
ItemIncense.itemDuration = config.get("TestIncenseSettings", "ItemDuration", 100).getInt(); // ItemIncense.itemDuration = config.get("TestIncenseSettings", "ItemDuration", 100).getInt();
ItemIncense.minValue = config.get("TestIncenseSettings", "MinValue", 0).getInt(); // ItemIncense.minValue = config.get("TestIncenseSettings", "MinValue", 0).getInt();
ItemIncense.maxValue = config.get("TestIncenseSettings", "MaxValue", 100).getInt(); // ItemIncense.maxValue = config.get("TestIncenseSettings", "MaxValue", 100).getInt();
PlayerSacrificeHandler.scalingOfSacrifice = (float) config.get("TestIncenseSettings", "ScalingFactor", 0.0025f).getDouble(); // PlayerSacrificeHandler.scalingOfSacrifice = (float) config.get("TestIncenseSettings", "ScalingFactor", 0.0025f).getDouble();
PlayerSacrificeHandler.soulFrayDuration = config.get("TestIncenseSettings", "SoulFrayDuration", 400).getInt(); // PlayerSacrificeHandler.soulFrayDuration = config.get("TestIncenseSettings", "SoulFrayDuration", 400).getInt();
Side side = FMLCommonHandler.instance().getSide(); Side side = FMLCommonHandler.instance().getSide();

View file

@ -511,6 +511,5 @@ public class ModItems
GameRegistry.registerItem(ModItems.itemMailCatalogue, "itemMailCatalogue"); GameRegistry.registerItem(ModItems.itemMailCatalogue, "itemMailCatalogue");
GameRegistry.registerItem(ModItems.itemIncense, "bloodMagicIncenseItem"); GameRegistry.registerItem(ModItems.itemIncense, "bloodMagicIncenseItem");
//GameRegistry.registerItem(ModItems.itemBloodFrame, "itemBloodFrame");
} }
} }

View file

@ -10,7 +10,7 @@ import WayofTime.alchemicalWizardry.api.tile.IBloodAltar;
public class PlayerSacrificeHandler public class PlayerSacrificeHandler
{ {
public static float scalingOfSacrifice = 0.0025f; public static float scalingOfSacrifice = 0.001f;
public static int soulFrayDuration = 400; public static int soulFrayDuration = 400;
public static float getPlayerIncense(EntityPlayer player) public static float getPlayerIncense(EntityPlayer player)
{ {
@ -22,7 +22,7 @@ public class PlayerSacrificeHandler
APISpellHelper.setCurrentIncense(player, amount); APISpellHelper.setCurrentIncense(player, amount);
} }
public static boolean incrementIncense(EntityPlayer player, float min, float max) public static boolean incrementIncense(EntityPlayer player, float min, float max, float increment)
{ {
float amount = getPlayerIncense(player); float amount = getPlayerIncense(player);
if(amount < min || amount >= max) if(amount < min || amount >= max)
@ -30,7 +30,7 @@ public class PlayerSacrificeHandler
return false; return false;
} }
amount++; amount = amount + Math.max(increment, max - amount);
setPlayerIncense(player, amount); setPlayerIncense(player, amount);
return true; return true;

View file

@ -1,11 +1,13 @@
package WayofTime.alchemicalWizardry.common.commands; package WayofTime.alchemicalWizardry.common.commands;
import WayofTime.alchemicalWizardry.api.soulNetwork.LifeEssenceNetwork;
import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler; import WayofTime.alchemicalWizardry.api.soulNetwork.SoulNetworkHandler;
import net.minecraft.command.CommandBase; import net.minecraft.command.CommandBase;
import net.minecraft.command.CommandException; import net.minecraft.command.CommandException;
import net.minecraft.command.ICommandSender; import net.minecraft.command.ICommandSender;
import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.server.MinecraftServer; import net.minecraft.server.MinecraftServer;
import net.minecraft.world.World;
import java.util.List; import java.util.List;
@ -97,7 +99,7 @@ public class CommandSN extends CommandBase
} }
else if (astring.length == 2) else if (astring.length == 2)
{ {
return getListOfStringsMatchingLastWord(astring, "add", "subtract", "fill", "empty", "get"); return getListOfStringsMatchingLastWord(astring, "add", "subtract", "fill", "empty");
} }
return null; return null;

View file

@ -17,7 +17,7 @@ import cpw.mods.fml.relauncher.SideOnly;
public class ItemIncense extends Item implements IIncense public class ItemIncense extends Item implements IIncense
{ {
private static final String[] ITEM_NAMES = new String[]{"Woodash"}; private static final String[] ITEM_NAMES = new String[]{"Woodash", "Cloves"};
@SideOnly(Side.CLIENT) @SideOnly(Side.CLIENT)
private IIcon[] icons; private IIcon[] icons;
@ -80,12 +80,26 @@ public class ItemIncense extends Item implements IIncense
@Override @Override
public int getMinLevel(ItemStack stack) public int getMinLevel(ItemStack stack)
{ {
switch(stack.getItemDamage())
{
case 0:
return 0;
case 1:
return 200;
}
return 0; return 0;
} }
@Override @Override
public int getMaxLevel(ItemStack stack) public int getMaxLevel(ItemStack stack)
{ {
switch(stack.getItemDamage())
{
case 0:
return 200;
case 1:
return 500;
}
return 100; return 100;
} }
@ -98,6 +112,13 @@ public class ItemIncense extends Item implements IIncense
@Override @Override
public float getTickRate(ItemStack stack) public float getTickRate(ItemStack stack)
{ {
switch(stack.getItemDamage())
{
case 0:
return 1.0f;
case 1:
return 0.5f;
}
return 1.0f; return 1.0f;
} }

View file

@ -328,7 +328,10 @@ public class ItemRitualDiviner extends EnergyItems implements IRitualDiviner
} }
NBTTagCompound locTag = (NBTTagCompound)tag.getTag("location"); NBTTagCompound locTag = (NBTTagCompound)tag.getTag("location");
locTag.setBoolean("isStored", false); if(locTag != null)
{
locTag.setBoolean("isStored", false);
}
} }
public Int3 getStoredLocation(ItemStack stack) public Int3 getStoredLocation(ItemStack stack)

View file

@ -91,11 +91,11 @@ public class SacrificialDagger extends Item
@Override @Override
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
{ {
// if (this.canUseForSacrifice(stack)) if (this.canUseForSacrifice(stack))
// { {
// player.setItemInUse(stack, this.getMaxItemUseDuration(stack)); player.setItemInUse(stack, this.getMaxItemUseDuration(stack));
// return stack; return stack;
// } }
if (!player.capabilities.isCreativeMode) if (!player.capabilities.isCreativeMode)
{ {
@ -183,6 +183,11 @@ public class SacrificialDagger extends Item
for (int k = -2; k <= 1; k++) for (int k = -2; k <= 1; k++)
{ {
tileEntity = world.getTileEntity(i + x, k + y, j + z); tileEntity = world.getTileEntity(i + x, k + y, j + z);
if(tileEntity instanceof IBloodAltar)
{
return (IBloodAltar)tileEntity;
}
} }
} }
} }

View file

@ -1,25 +1,29 @@
package WayofTime.alchemicalWizardry.common.items.forestry; package WayofTime.alchemicalWizardry.common.items.forestry;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import java.util.List;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
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.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import forestry.api.apiculture.IBee;
import forestry.api.apiculture.IBeeGenome;
import forestry.api.apiculture.IBeeHousing;
import forestry.api.apiculture.IHiveFrame;
import java.util.List; 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(3000); setEnergyUsed(1000);
setCreativeTab(AlchemicalWizardry.tabBloodMagic); setCreativeTab(AlchemicalWizardry.tabBloodMagic);
} }
@ -48,14 +52,15 @@ public class ItemBloodFrame extends EnergyItems //implements IHiveFrame
{ {
if (par1ItemStack.getItemDamage() > 0) if (par1ItemStack.getItemDamage() > 0)
{ {
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;
} }
/**TODO Bee Stuff
@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
@ -135,6 +140,6 @@ public class ItemBloodFrame extends EnergyItems //implements IHiveFrame
} }
*/
} }

View file

@ -1,5 +1,18 @@
package WayofTime.alchemicalWizardry.common.items.sigil; package WayofTime.alchemicalWizardry.common.items.sigil;
import java.util.List;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChatComponentText;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import WayofTime.alchemicalWizardry.AlchemicalWizardry; import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.alchemy.energy.IReagentHandler; import WayofTime.alchemicalWizardry.api.alchemy.energy.IReagentHandler;
import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentContainerInfo; import WayofTime.alchemicalWizardry.api.alchemy.energy.ReagentContainerInfo;
@ -10,21 +23,6 @@ import WayofTime.alchemicalWizardry.api.items.interfaces.IReagentManipulator;
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 net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChatComponentText;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import java.util.List;
public class DivinationSigil extends Item implements ArmourUpgrade, IReagentManipulator, IBindable public class DivinationSigil extends Item implements ArmourUpgrade, IReagentManipulator, IBindable
{ {
@ -130,7 +128,7 @@ public class DivinationSigil extends Item implements ArmourUpgrade, IReagentMani
@Override @Override
public boolean isUpgrade() public boolean isUpgrade()
{ {
return true; return false;
} }
@Override @Override

View file

@ -23,6 +23,7 @@ public class TECrucible extends TEInventory
public int ticksRemaining = 0; public int ticksRemaining = 0;
public int minValue = 0; public int minValue = 0;
public int maxValue = 0; public int maxValue = 0;
public float incrementValue = 0;
public int state = 0; //0 is when it gives off gray particles, 1 is when it gives off white particles (player can't use this incense anymore), 2 is the normal colour of the incense, 3 means no particles (it is out) public int state = 0; //0 is when it gives off gray particles, 1 is when it gives off white particles (player can't use this incense anymore), 2 is the normal colour of the incense, 3 means no particles (it is out)
@ -59,6 +60,8 @@ public class TECrucible extends TEInventory
minValue = incense.getMinLevel(stack); minValue = incense.getMinLevel(stack);
maxValue = incense.getMaxLevel(stack); maxValue = incense.getMaxLevel(stack);
incrementValue = incense.getTickRate(stack);
stack.stackSize--; stack.stackSize--;
if(stack.stackSize <= 0) if(stack.stackSize <= 0)
{ {
@ -78,7 +81,7 @@ public class TECrucible extends TEInventory
for(EntityPlayer player : playerList) for(EntityPlayer player : playerList)
{ {
if(ticksRemaining > 0 && PlayerSacrificeHandler.incrementIncense(player, minValue, maxValue)) if(ticksRemaining > 0 && PlayerSacrificeHandler.incrementIncense(player, minValue, maxValue, incrementValue))
{ {
ticksRemaining--; ticksRemaining--;
if(state != 2) if(state != 2)

View file

@ -1,6 +1,5 @@
package WayofTime.alchemicalWizardry.common.tileEntity.container; package WayofTime.alchemicalWizardry.common.tileEntity.container;
import WayofTime.alchemicalWizardry.common.items.TelepositionFocus;
import WayofTime.alchemicalWizardry.common.tileEntity.TETeleposer; import WayofTime.alchemicalWizardry.common.tileEntity.TETeleposer;
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.entity.player.InventoryPlayer;
@ -15,7 +14,7 @@ public class ContainerTeleposer extends Container
public ContainerTeleposer(InventoryPlayer inventoryPlayer, TETeleposer te) public ContainerTeleposer(InventoryPlayer inventoryPlayer, TETeleposer te)
{ {
tileEntity = te; tileEntity = te;
addSlotToContainer(new Slot(tileEntity, 0, 80, 15)); addSlotToContainer(new Slot(tileEntity, 0, 80, 67));
bindPlayerInventory(inventoryPlayer); bindPlayerInventory(inventoryPlayer);
} }
@ -31,13 +30,13 @@ public class ContainerTeleposer extends Container
{ {
for (int j = 0; j < 9; j++) for (int j = 0; j < 9; j++)
{ {
addSlotToContainer(new Slot(inventoryPlayer, j + i * 9 + 9, 8 + j * 18, 39 + i * 18)); addSlotToContainer(new Slot(inventoryPlayer, j + i * 9 + 9, 8 + j * 18, 140 + i * 18));
} }
} }
for (int i = 0; i < 9; i++) for (int i = 0; i < 9; i++)
{ {
addSlotToContainer(new Slot(inventoryPlayer, i, 8 + i * 18, 97)); addSlotToContainer(new Slot(inventoryPlayer, i, 8 + i * 18, 198));
} }
} }
@ -46,27 +45,30 @@ public class ContainerTeleposer extends Container
{ {
ItemStack stack = null; ItemStack stack = null;
Slot slotObject = (Slot) inventorySlots.get(slot); Slot slotObject = (Slot) inventorySlots.get(slot);
int slots = inventorySlots.size();
if (slotObject != null && slotObject.getHasStack()) if (slotObject != null && slotObject.getHasStack())
{ {
ItemStack stackInSlot = slotObject.getStack(); ItemStack stackInSlot = slotObject.getStack();
stack = stackInSlot.copy(); stack = stackInSlot.copy();
System.out.println("Slots: " + slots);
if (stack.getItem() instanceof TelepositionFocus) if (slot == 7)
{ {
if (slot <= slots) if (!this.mergeItemStack(stackInSlot, 7, 35, true))
{
if (!this.mergeItemStack(stackInSlot, 0, slots, false))
{
return null;
}
}
else if (!this.mergeItemStack(stackInSlot, slots, 36 + slots, false))
{ {
return null; return null;
} }
slotObject.onSlotChange(stackInSlot, stack);
}
if (slot < 1)
{
if (!this.mergeItemStack(stackInSlot, 7, 35, true))
{
return null;
}
}
else if (!this.mergeItemStack(stackInSlot, 0, 0, false))
{
return null;
} }
if (stackInSlot.stackSize == 0) if (stackInSlot.stackSize == 0)

View file

@ -62,15 +62,13 @@ public class ContainerWritingTable extends Container
{ {
return null; return null;
} }
} } else if (stack.getItem() instanceof IBloodOrb)
else if (stack.getItem() instanceof IBloodOrb)
{ {
if (!this.mergeItemStack(stackInSlot, 0, 1, false)) if (!this.mergeItemStack(stackInSlot, 0, 1, false))
{ {
return null; return null;
} }
} } else if (!this.mergeItemStack(stackInSlot, 1, 6, false))
else if (!this.mergeItemStack(stackInSlot, 1, 6, false))
{ {
return null; return null;
} }

View file

@ -15,16 +15,16 @@ public class GuiTeleposer extends GuiContainer
{ {
super(new ContainerTeleposer(inventoryPlayer, tileEntity)); super(new ContainerTeleposer(inventoryPlayer, tileEntity));
xSize = 176; xSize = 176;
ySize = 121; ySize = 222;
} }
@Override @Override
protected void drawGuiContainerForegroundLayer(int param1, int param2) protected void drawGuiContainerForegroundLayer(int param1, int param2)
{ {
//the parameters for drawString are: string, x, y, color //the parameters for drawString are: string, x, y, color
fontRendererObj.drawString("Teleposer", 64, 5, 4210752); fontRendererObj.drawString("Teleposer", 8, 6, 4210752);
//draws "Inventory" or your regional equivalent //draws "Inventory" or your regional equivalent
fontRendererObj.drawString(StatCollector.translateToLocal("container.inventory"), 8, 29, 4210752); fontRendererObj.drawString(StatCollector.translateToLocal("container.inventory"), 8, 130, 4210752);
} }
@Override @Override
@ -37,5 +37,6 @@ public class GuiTeleposer extends GuiContainer
int x = (width - xSize) / 2; int x = (width - xSize) / 2;
int y = (height - ySize) / 2; int y = (height - ySize) / 2;
this.drawTexturedModalRect(x, y, 0, 0, xSize, ySize); this.drawTexturedModalRect(x, y, 0, 0, xSize, ySize);
GuiBrewingStand d;
} }
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 986 B