Finished the pillar but rearranged the .json for testing
This commit is contained in:
parent
1286efbca7
commit
f1b3d6f4bc
|
@ -17,7 +17,7 @@ import WayofTime.bloodmagic.client.IVariantProvider;
|
||||||
|
|
||||||
public class BlockDemonPillar extends BlockStringPillar implements IVariantProvider
|
public class BlockDemonPillar extends BlockStringPillar implements IVariantProvider
|
||||||
{
|
{
|
||||||
public static final String[] names = new String[] { "raw", "corrosive" };
|
public static final String[] names = new String[] { "raw", "corrosive", "destructive", "vengeful", "steadfast" };
|
||||||
|
|
||||||
public BlockDemonPillar(String baseName, Material materialIn)
|
public BlockDemonPillar(String baseName, Material materialIn)
|
||||||
{
|
{
|
||||||
|
@ -43,7 +43,7 @@ public class BlockDemonPillar extends BlockStringPillar implements IVariantProvi
|
||||||
{
|
{
|
||||||
for (int j = 0; j < names.length; j++)
|
for (int j = 0; j < names.length; j++)
|
||||||
{
|
{
|
||||||
ret.add(new ImmutablePair<Integer, String>(i * 4 + j, "axis=" + axis[i] + ",type=" + names[j]));
|
ret.add(new ImmutablePair<Integer, String>(i * 5 + j, "axis=" + axis[i] + ",type=" + names[j]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -30,17 +30,17 @@ public class BlockStringPillar extends BlockString
|
||||||
@Override
|
@Override
|
||||||
public IBlockState getStateFromMeta(int meta)
|
public IBlockState getStateFromMeta(int meta)
|
||||||
{
|
{
|
||||||
IBlockState iblockstate = this.getDefaultState().withProperty(this.getStringProp(), this.getValues().get((meta & 3) % 4));
|
IBlockState iblockstate = this.getDefaultState().withProperty(this.getStringProp(), this.getValues().get(meta % 5));
|
||||||
|
|
||||||
switch (meta & 12)
|
switch (meta / 5)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.Y);
|
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.Y);
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 1:
|
||||||
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.X);
|
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.X);
|
||||||
break;
|
break;
|
||||||
case 8:
|
case 2:
|
||||||
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.Z);
|
iblockstate = iblockstate.withProperty(BlockRotatedPillar.AXIS, EnumFacing.Axis.Z);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -61,10 +61,10 @@ public class BlockStringPillar extends BlockString
|
||||||
switch ((EnumFacing.Axis) state.getValue(BlockRotatedPillar.AXIS))
|
switch ((EnumFacing.Axis) state.getValue(BlockRotatedPillar.AXIS))
|
||||||
{
|
{
|
||||||
case X:
|
case X:
|
||||||
i = i + 4;
|
i = i + 5;
|
||||||
break;
|
break;
|
||||||
case Z:
|
case Z:
|
||||||
i = i + 8;
|
i = i + 10;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -123,7 +123,7 @@ public class BlockStringPillar extends BlockString
|
||||||
@Override
|
@Override
|
||||||
protected BlockStateContainer createRealBlockState()
|
protected BlockStateContainer createRealBlockState()
|
||||||
{
|
{
|
||||||
return new ExtendedBlockState(this, new IProperty[] { BlockRotatedPillar.AXIS, this.getStringProp() }, new IUnlistedProperty[] { this.getUnlistedStringProp() });
|
return new ExtendedBlockState(this, new IProperty[] { this.getStringProp(), BlockRotatedPillar.AXIS }, new IUnlistedProperty[] { this.getUnlistedStringProp() });
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -9,6 +9,39 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"variants": {
|
"variants": {
|
||||||
|
"type": {
|
||||||
|
"raw": {
|
||||||
|
|
||||||
|
},
|
||||||
|
"corrosive": {
|
||||||
|
"textures": {
|
||||||
|
"bottom": "bloodmagic:blocks/dungeon/dungeon_pillarheart_c",
|
||||||
|
"top": "bloodmagic:blocks/dungeon/dungeon_pillarheart_c",
|
||||||
|
"side": "bloodmagic:blocks/dungeon/dungeon_pillar_c"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"destructive": {
|
||||||
|
"textures": {
|
||||||
|
"bottom": "bloodmagic:blocks/dungeon/dungeon_pillarheart_d",
|
||||||
|
"top": "bloodmagic:blocks/dungeon/dungeon_pillarheart_d",
|
||||||
|
"side": "bloodmagic:blocks/dungeon/dungeon_pillar_d"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"vengeful": {
|
||||||
|
"textures": {
|
||||||
|
"bottom": "bloodmagic:blocks/dungeon/dungeon_pillarheart_v",
|
||||||
|
"top": "bloodmagic:blocks/dungeon/dungeon_pillarheart_v",
|
||||||
|
"side": "bloodmagic:blocks/dungeon/dungeon_pillar_v"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"steadfast": {
|
||||||
|
"textures": {
|
||||||
|
"bottom": "bloodmagic:blocks/dungeon/dungeon_pillarheart_s",
|
||||||
|
"top": "bloodmagic:blocks/dungeon/dungeon_pillarheart_s",
|
||||||
|
"side": "bloodmagic:blocks/dungeon/dungeon_pillar_s"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"axis": {
|
"axis": {
|
||||||
"x": {
|
"x": {
|
||||||
"transform": {
|
"transform": {
|
||||||
|
@ -24,18 +57,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"type": {
|
|
||||||
"raw": {
|
|
||||||
|
|
||||||
},
|
|
||||||
"corrosive": {
|
|
||||||
"textures": {
|
|
||||||
"bottom": "bloodmagic:blocks/dungeon/dungeon_pillarheart_c",
|
|
||||||
"top": "bloodmagic:blocks/dungeon/dungeon_pillarheart_c",
|
|
||||||
"side": "bloodmagic:blocks/dungeon/dungeon_pillar_c"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"inventory": [{
|
"inventory": [{
|
||||||
"variants": {
|
"variants": {
|
||||||
"raw": {
|
"raw": {
|
||||||
|
|
|
@ -316,7 +316,7 @@ tile.BloodMagic.pillar1.raw.name=Raw Stone Pillar
|
||||||
tile.BloodMagic.pillar1.corrosive.name=Corrosive Stone Pillar
|
tile.BloodMagic.pillar1.corrosive.name=Corrosive Stone Pillar
|
||||||
tile.BloodMagic.pillar1.destructive.name=Destructive Stone Pillar
|
tile.BloodMagic.pillar1.destructive.name=Destructive Stone Pillar
|
||||||
tile.BloodMagic.pillar1.vengeful.name=Vengeful Stone Pillar
|
tile.BloodMagic.pillar1.vengeful.name=Vengeful Stone Pillar
|
||||||
tile.BloodMagic.pillar2.steadfast.name=Steadfast Stone Pillar
|
tile.BloodMagic.pillar1.steadfast.name=Steadfast Stone Pillar
|
||||||
|
|
||||||
# Fluids
|
# Fluids
|
||||||
fluid.lifeEssence=Life Essence
|
fluid.lifeEssence=Life Essence
|
||||||
|
|
Loading…
Reference in a new issue