Finished adding all of the dungeon blocks and localized them. Added the appropriate models for rotated pillars/pillar caps.

This commit is contained in:
WayofTime 2016-09-05 10:30:59 -04:00
parent b08c7fd7ae
commit afcba54df4
21 changed files with 569 additions and 60 deletions

View file

@ -1,30 +1,29 @@
package WayofTime.bloodmagic.item.block;
import net.minecraft.block.Block;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import WayofTime.bloodmagic.block.BlockDemonPillar;
import WayofTime.bloodmagic.block.BlockDemonPillarBase;
public class ItemBlockDemonPillarBase extends ItemBlock
{
// public final BlockDemonBase demonBlock;
public final BlockDemonPillarBase demonBlock;
public ItemBlockDemonPillarBase(Block block)
public ItemBlockDemonPillarBase(BlockDemonPillarBase block)
{
super(block);
setHasSubtypes(true);
// demonBlock = block;
demonBlock = block;
}
@Override
public String getUnlocalizedName(ItemStack stack)
{
return super.getUnlocalizedName(stack) + BlockDemonPillar.names[stack.getItemDamage() % BlockDemonPillar.names.length];
return super.getUnlocalizedName(stack) + demonBlock.names[stack.getItemDamage() % demonBlock.names.length];
}
@Override
public int getMetadata(int meta)
{
return meta % BlockDemonPillar.names.length;
return meta % demonBlock.names.length;
}
}

View file

@ -0,0 +1,29 @@
package WayofTime.bloodmagic.item.block;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import WayofTime.bloodmagic.block.BlockDemonPillarCapBase;
public class ItemBlockDemonPillarCapBase extends ItemBlock
{
public final BlockDemonPillarCapBase demonBlock;
public ItemBlockDemonPillarCapBase(BlockDemonPillarCapBase block)
{
super(block);
setHasSubtypes(true);
demonBlock = block;
}
@Override
public String getUnlocalizedName(ItemStack stack)
{
return super.getUnlocalizedName(stack) + demonBlock.names[stack.getItemDamage() % demonBlock.names.length];
}
@Override
public int getMetadata(int meta)
{
return meta % demonBlock.names.length;
}
}