mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-12-23 03:49:22 +01:00
Probably shouldn't hoe farmland blocks
This commit is contained in:
parent
5b3c3fa46f
commit
76263a56d9
1 changed files with 3 additions and 8 deletions
|
@ -86,17 +86,12 @@ public class EntityWorm extends Entity{
|
|||
|
||||
if(!isFarmland || state.getValue(BlockFarmland.MOISTURE) < 7){
|
||||
if(isMiddlePose || this.world.rand.nextFloat() >= 0.45F){
|
||||
|
||||
DefaultFarmerBehavior.useHoeAt(world, pos);
|
||||
|
||||
if(!isFarmland) DefaultFarmerBehavior.useHoeAt(world, pos);
|
||||
state = this.world.getBlockState(pos);
|
||||
isFarmland = state.getBlock() instanceof BlockFarmland;
|
||||
|
||||
if(isFarmland)
|
||||
this.world.setBlockState(pos, state.withProperty(BlockFarmland.MOISTURE, 7), 2);
|
||||
|
||||
if(!isFarmland){
|
||||
this.world.setBlockToAir(pos.up());
|
||||
}
|
||||
if(isFarmland) this.world.setBlockState(pos, state.withProperty(BlockFarmland.MOISTURE, 7), 2);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue