Throne - Recipes
Base recipe + dyeing recipe
This commit is contained in:
parent
510ecab1ac
commit
cab22724ea
1 changed files with 30 additions and 1 deletions
|
@ -5,6 +5,7 @@ import java.util.List;
|
||||||
|
|
||||||
import mmm.utils.I_UBlockSeat;
|
import mmm.utils.I_UBlockSeat;
|
||||||
import mmm.utils.I_UColoredBlock;
|
import mmm.utils.I_UColoredBlock;
|
||||||
|
import mmm.utils.I_URecipeRegistrar;
|
||||||
import mmm.utils.I_USupportBlock;
|
import mmm.utils.I_USupportBlock;
|
||||||
import mmm.utils.URegistry;
|
import mmm.utils.URegistry;
|
||||||
import mmm.utils.USeat;
|
import mmm.utils.USeat;
|
||||||
|
@ -22,6 +23,8 @@ import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.EntityLivingBase;
|
import net.minecraft.entity.EntityLivingBase;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
|
import net.minecraft.init.Blocks;
|
||||||
|
import net.minecraft.init.Items;
|
||||||
import net.minecraft.item.EnumDyeColor;
|
import net.minecraft.item.EnumDyeColor;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
@ -32,6 +35,7 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.RayTraceResult;
|
import net.minecraft.util.math.RayTraceResult;
|
||||||
import net.minecraft.world.IBlockAccess;
|
import net.minecraft.world.IBlockAccess;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
|
@ -39,7 +43,7 @@ import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
public class DThroneBlock
|
public class DThroneBlock
|
||||||
extends Block
|
extends Block
|
||||||
implements I_UColoredBlock , I_UBlockSeat
|
implements I_UColoredBlock , I_UBlockSeat , I_URecipeRegistrar
|
||||||
{
|
{
|
||||||
|
|
||||||
public static final PropertyDirection FACING;
|
public static final PropertyDirection FACING;
|
||||||
|
@ -314,4 +318,29 @@ public class DThroneBlock
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// *************************************************************************************************
|
||||||
|
// CRAFTING
|
||||||
|
// *************************************************************************************************
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void registerRecipes( )
|
||||||
|
{
|
||||||
|
for ( EnumDyeColor dyeColor : EnumDyeColor.values( ) ) {
|
||||||
|
GameRegistry.addShapedRecipe( new ItemStack( this , 1 , dyeColor.getMetadata( ) ) , //
|
||||||
|
" E " , //
|
||||||
|
"GWG" , //
|
||||||
|
"BBB" , //
|
||||||
|
'W' , new ItemStack( Blocks.WOOL , 1 , dyeColor.getMetadata( ) ) , //
|
||||||
|
'B' , new ItemStack( this.woodType.block , 1 , this.woodType.metaData ) , //
|
||||||
|
'G' , Items.GOLD_INGOT , //
|
||||||
|
'E' , Items.EMERALD //
|
||||||
|
);
|
||||||
|
GameRegistry.addShapelessRecipe( new ItemStack( this , 1 , dyeColor.getMetadata( ) ) , //
|
||||||
|
new ItemStack( this , 1 , 32767 ) , //
|
||||||
|
new ItemStack( Items.DYE , 1 , dyeColor.getDyeDamage( ) ) );
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue