Make smoldering grass melt snow
This commit is contained in:
parent
ee22af02e0
commit
6a1347ff6f
1 changed files with 9 additions and 1 deletions
|
@ -37,7 +37,6 @@ import net.minecraft.world.World;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
// TODO: smoldering grass should probably melt snow that falls on it
|
|
||||||
public class BlockBOPGrass extends BlockGrass implements IBOPBlock
|
public class BlockBOPGrass extends BlockGrass implements IBOPBlock
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -241,6 +240,15 @@ public class BlockBOPGrass extends BlockGrass implements IBOPBlock
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case SMOLDERING:
|
||||||
|
// smoldering grass melts snow
|
||||||
|
IBlockState stateAbove = world.getBlockState(pos.up());
|
||||||
|
if (stateAbove.getBlock().getMaterial() == Material.snow)
|
||||||
|
{
|
||||||
|
world.setBlockToAir(pos.up());
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue