-
Bug
-
Resolution: Fixed
-
Minecraft 1.10.2, Minecraft 16w40a, Minecraft 16w41a, Minecraft 16w43a, Minecraft 16w44a, Minecraft 1.11 Pre-Release 1, Minecraft 1.11
-
None
-
Confirmed
When moving a 1.5 high block such as fences, walls or fence gates they will not move entities in the upper 0.5 part of the collision box.
For the not moving entities part of the issue this is a good test setup:
Video: https://youtu.be/0tT4VgPSdkM
Cause/Fix
When pistons move entities they do a "rough check" with a 1x1x1 bounding box first and only match the real bounding boxes against the entities that are within this box.
The easiest way to fix this is to soften up the first check a bit to a 1x1.5x1 box.
TileEntityPiston.java
private void moveCollidedEntities(float p_184322_1_) { EnumFacing enumfacing = this.extending?this.pistonFacing:this.pistonFacing.getOpposite(); double d0 = (double)(p_184322_1_ - this.progress); List<AxisAlignedBB> list = Lists.<AxisAlignedBB>newArrayList(); this.func_190606_j().addCollisionBoxToList(this.world, BlockPos.ORIGIN /*Cause of MC-110244*/, new AxisAlignedBB(BlockPos.ORIGIN), list, (Entity)null); if(!((List)list).isEmpty()) { AxisAlignedBB axisalignedbb = this.func_190607_a(new AxisAlignedBB(BlockPos.ORIGIN).setMaxY(1.5)); // Added ".setMaxY(1.5)" to support 1.5 high blocks. (MC-108673) List<Entity> list1 = this.world.getEntitiesWithinAABBExcludingEntity((Entity)null, this.func_190610_a(axisalignedbb, enumfacing, d0).union(axisalignedbb)); if(!list1.isEmpty()) { boolean flag = this.pistonState.getBlock() == Blocks.SLIME_BLOCK; // ... } } }
I noticed that I mixed two issues up in this report and split it up now. Second report: MC-110094
- is duplicated by
-
MC-109013 Cobblestone walls and fences don't use their full collision boxes when being moved by a piston
- Resolved