Created the proper rendering for the crystal clusters while in hand
This commit is contained in:
parent
19fec96bfd
commit
ea24e7edd8
15 changed files with 261 additions and 7 deletions
|
@ -1,9 +1,16 @@
|
|||
package WayofTime.bloodmagic.item.block;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.BlockPos;
|
||||
import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.world.World;
|
||||
import WayofTime.bloodmagic.api.soul.EnumDemonWillType;
|
||||
import WayofTime.bloodmagic.tile.TileDemonCrystal;
|
||||
|
||||
public class ItemBlockDemonCrystal extends ItemBlock
|
||||
{
|
||||
|
@ -24,4 +31,21 @@ public class ItemBlockDemonCrystal extends ItemBlock
|
|||
{
|
||||
return meta;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean placeBlockAt(ItemStack stack, EntityPlayer player, World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ, IBlockState newState)
|
||||
{
|
||||
if (super.placeBlockAt(stack, player, world, pos, side, hitX, hitY, hitZ, newState))
|
||||
{
|
||||
TileEntity tile = world.getTileEntity(pos);
|
||||
if (tile instanceof TileDemonCrystal)
|
||||
{
|
||||
((TileDemonCrystal) tile).setPlacement(side);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue