Made doors stackable
Fixed click on rift to place door bug Signed-off-by: StevenRS11 <stevenrs11@aol.com>
This commit is contained in:
@@ -32,15 +32,16 @@ public class ItemRiftBlade extends itemDimDoor
|
||||
private int weaponDamage;
|
||||
private final EnumToolMaterial toolMaterial= EnumToolMaterial.GOLD;
|
||||
private Material doorMaterial;
|
||||
|
||||
Random rand = new Random();
|
||||
public ItemRiftBlade(int par1, Material par2Material)
|
||||
{
|
||||
super(par1, par2Material);
|
||||
this.setMaxStackSize(1);
|
||||
|
||||
// this.setTextureFile("/PocketBlockTextures.png");
|
||||
this.setCreativeTab(CreativeTabs.tabTransport);
|
||||
this.weaponDamage =8;
|
||||
|
||||
this.setMaxStackSize(1);
|
||||
|
||||
// this.itemIcon=5;
|
||||
this.setMaxDamage(500);
|
||||
@@ -221,7 +222,7 @@ public class ItemRiftBlade extends itemDimDoor
|
||||
{
|
||||
int var12 = MathHelper.floor_double((double)((par3EntityPlayer.rotationYaw + 180.0F) * 4.0F / 360.0F) - 0.5D) & 3;
|
||||
|
||||
if (!this.canPlace(par2World, par4, par5, par6, var12)||!this.canPlace(par2World, par4+1, par5, par6, var12)||dimHelper.instance.getLinkDataFromCoords(par4, par5+1, par6, par2World)==null)
|
||||
if (!this.canPlace(par2World, par4, par5, par6, var12)||!this.canPlace(par2World, par4, par5+1, par6, var12)||dimHelper.instance.getLinkDataFromCoords(par4, par5+1, par6, par2World)==null)
|
||||
{
|
||||
return par1ItemStack;
|
||||
}
|
||||
|
||||
@@ -28,6 +28,7 @@ public class itemDimDoor extends ItemDoor
|
||||
public itemDimDoor(int par1, Material par2Material)
|
||||
{
|
||||
super(par1, par2Material);
|
||||
this.setMaxStackSize(64);
|
||||
this.doorMaterial = par2Material;
|
||||
this.setCreativeTab(CreativeTabs.tabTransport);
|
||||
}
|
||||
@@ -167,7 +168,7 @@ public class itemDimDoor extends ItemDoor
|
||||
{
|
||||
int var12 = MathHelper.floor_double((double)((par3EntityPlayer.rotationYaw + 180.0F) * 4.0F / 360.0F) - 0.5D) & 3;
|
||||
|
||||
if (!this.canPlace(par2World, par4, par5, par6, var12)||!this.canPlace(par2World, par4-1, par5, par6, var12)||dimHelper.instance.getLinkDataFromCoords(par4, par5+1, par6, par2World)==null)
|
||||
if (!this.canPlace(par2World, par4, par5, par6, var12)||!this.canPlace(par2World, par4, par5-1, par6, var12)||dimHelper.instance.getLinkDataFromCoords(par4, par5+1, par6, par2World)==null)
|
||||
{
|
||||
return par1ItemStack;
|
||||
}
|
||||
|
||||
@@ -24,7 +24,6 @@ public class itemExitDoor extends itemDimDoor
|
||||
this.doorMaterial = par2Material;
|
||||
this.setCreativeTab(CreativeTabs.tabTransport);
|
||||
|
||||
// this.setitemIcon(Item.doorWood.getIconFromDamage(0));
|
||||
}
|
||||
|
||||
public void registerIcons(IconRegister par1IconRegister)
|
||||
|
||||
Reference in New Issue
Block a user