Added the .jsons for the base runes and added the BlockStates to it.

This commit is contained in:
WayofTime 2015-07-29 22:07:13 -04:00
parent aed8436204
commit 8241c3cbd1
4 changed files with 77 additions and 4 deletions

View file

@ -108,7 +108,7 @@ public class ModBlocks
public static void init()
{
blockAltar = (BlockAltar) registerBlock(new BlockAltar(), "altar");
bloodRune = (BlockBloodRune) registerBlock(new BlockBloodRune(), ItemBloodRuneBlock.class, ModBlocks.bloodRune.getUnlocalizedName());
bloodRune = (BlockBloodRune) registerBlock(new BlockBloodRune(), ItemBloodRuneBlock.class, "base_rune");
speedRune = (BlockSpeedRune) registerBlock(new BlockSpeedRune(), "speed_rune");
efficiencyRune = (BlockEfficiencyRune) registerBlock(new BlockEfficiencyRune(), "efficiency_rune");
runeOfSacrifice = (BlockRuneOfSacrifice) registerBlock(new BlockRuneOfSacrifice(), "sacrifice_rune");

View file

@ -1,25 +1,49 @@
package WayofTime.alchemicalWizardry.common.block;
import WayofTime.alchemicalWizardry.ModBlocks;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.block.properties.IProperty;
import net.minecraft.block.properties.PropertyInteger;
import net.minecraft.block.state.BlockState;
import net.minecraft.block.state.IBlockState;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import java.util.List;
import WayofTime.alchemicalWizardry.ModBlocks;
public class BlockBloodRune extends Block
{
public static final PropertyInteger INTEGER = PropertyInteger.create("rune", 0, 5);
public BlockBloodRune()
{
super(Material.iron);
this.setDefaultState(this.blockState.getBaseState().withProperty(INTEGER, Integer.valueOf(0)));
setHardness(2.0F);
setResistance(5.0F);
}
@Override
protected BlockState createBlockState()
{
return new BlockState(this, new IProperty[] {INTEGER});
}
@Override
public IBlockState getStateFromMeta(int meta)
{
return this.getDefaultState().withProperty(INTEGER, Integer.valueOf(meta));
}
@Override
public int getMetaFromState(IBlockState state)
{
return ((Integer)state.getValue(INTEGER)).intValue();
}
public int getRuneEffect(int metaData)
{

View file

@ -0,0 +1,44 @@
{
"forge_marker": 1,
"defaults": {
"textures": {
"all": "alchemicalwizardry:blocks/BlankRune"
},
"model": "cube_all",
"uvlock": true
},
"variants": {
"rune": {
0: {
"textures": {
"all": "alchemicalwizardry:blocks/AltarCapacityRune"
}
},
1: {
"textures": {
"all": "alchemicalwizardry:blocks/AltarCapacityRune"
}
},
2: {
"textures": {
"all": "alchemicalwizardry:blocks/DislocationRune"
}
},
3: {
"textures": {
"all": "alchemicalwizardry:blocks/OrbCapacityRune"
}
},
4: {
"textures": {
"all": "alchemicalwizardry:blocks/BetterCapacityRune"
}
},
5: {
"textures": {
"all": "alchemicalwizardry:blocks/AccelerationRune"
}
}
}
}
}

View file

@ -0,0 +1,5 @@
{
"variants": {
"normal": { "model": "alchemicalwizardry:soul_armour_forge" }
}
}