Fixed smelting stuff.
This commit is contained in:
parent
77acd03dbc
commit
a96e9dc140
1 changed files with 7 additions and 7 deletions
|
|
@ -94,11 +94,11 @@ public class ItemStaffFire extends Item {
|
||||||
{
|
{
|
||||||
ItemStack result = FurnaceRecipes.smelting().getSmeltingResult(new ItemStack(world.getBlockId(i, j, k), 1, world.getBlockMetadata(i, j, k)));
|
ItemStack result = FurnaceRecipes.smelting().getSmeltingResult(new ItemStack(world.getBlockId(i, j, k), 1, world.getBlockMetadata(i, j, k)));
|
||||||
|
|
||||||
|
if (!world.isRemote && !(result == null))
|
||||||
|
{
|
||||||
int id = result.itemID;
|
int id = result.itemID;
|
||||||
int meta = result.getItemDamage();
|
int meta = result.getItemDamage();
|
||||||
|
|
||||||
if (!world.isRemote && !(result == null))
|
|
||||||
{
|
|
||||||
world.playSoundEffect((double)i + 0.5D, (double)j + 0.5D, (double)k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
world.playSoundEffect((double)i + 0.5D, (double)j + 0.5D, (double)k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||||
world.setBlock(i, j, k, 0);
|
world.setBlock(i, j, k, 0);
|
||||||
world.spawnEntityInWorld(new EntityItem(world, i, j, k, new ItemStack(id, 1, meta)));
|
world.spawnEntityInWorld(new EntityItem(world, i, j, k, new ItemStack(id, 1, meta)));
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue