Fixed supported plant types for Dried Salt blocks

This commit is contained in:
Forstride 2020-07-10 07:00:53 -04:00
parent ff777917a1
commit d504aebb96
3 changed files with 3 additions and 38 deletions

View File

@ -1,37 +0,0 @@
/*******************************************************************************
* Copyright 2014-2019, the Biomes O' Plenty Team
*
* This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International Public License.
*
* To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
******************************************************************************/
package biomesoplenty.common.block;
import net.minecraft.block.Block;
import net.minecraft.block.BlockState;
import net.minecraft.particles.ParticleTypes;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.World;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn;
import java.util.Random;
public class AshBlock extends Block
{
public AshBlock(Block.Properties properties)
{
super(properties);
}
@Override
@OnlyIn(Dist.CLIENT)
public void animateTick(BlockState stateIn, World worldIn, BlockPos pos, Random rand)
{
super.animateTick(stateIn, worldIn, pos, rand);
if (rand.nextInt(8) == 0)
{
worldIn.addParticle(ParticleTypes.SMOKE, (double)((float)pos.getX() + rand.nextFloat()), (double)((float)pos.getY() + 1.1F), (double)((float)pos.getZ() + rand.nextFloat()), 0.0D, 0.0D, 0.0D);
}
}
}

View File

@ -26,7 +26,9 @@ public class DriedSaltBlock extends Block
PlantType type = plantable.getPlantType(world, pos.relative(facing));
if (type == PlantType.DESERT) return true;
else if (type == PlantType.NETHER) return true;
else if (type == PlantType.CAVE) return true;
else if (type == PlantType.PLAINS) return true;
return false;
}
}

View File

@ -70,7 +70,7 @@ public class FlowerBlockBOP extends FlowerBlock
}
if (this == BOPBlocks.burning_blossom)
{
return ground == Blocks.NETHERRACK || ground == Blocks.SOUL_SAND || super.canSurvive(state, worldIn, pos);
return ground == Blocks.NETHERRACK || ground == Blocks.SOUL_SAND || ground == Blocks.SOUL_SOIL || ground == Blocks.CRIMSON_NYLIUM || ground == Blocks.WARPED_NYLIUM || super.canSurvive(state, worldIn, pos);
}
return super.canSurvive(state, worldIn, pos);