Mappings Update

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2018-12-06 10:00:00 +11:00
parent e9e6bec4e5
commit 102dee7d4f
123 changed files with 393 additions and 442 deletions

View File

@@ -629,9 +629,9 @@ public class CraftBlock implements Block {
// Similar to to nms.World#rayTrace:
IBlockData blockData = world.getType(position);
Fluid fluid = world.b(position); // PAIL getFluid
boolean collidableBlock = blockData.getBlock().d(blockData); // PAIL isCollidable
boolean collideWithFluid = CraftFluidCollisionMode.toNMS(fluidCollisionMode).d.test(fluid); // PAIL predicate
Fluid fluid = world.getFluid(position);
boolean collidableBlock = blockData.getBlock().isCollidable(blockData);
boolean collideWithFluid = CraftFluidCollisionMode.toNMS(fluidCollisionMode).predicate.test(fluid);
if (!collidableBlock && !collideWithFluid) {
return null;
@@ -639,11 +639,11 @@ public class CraftBlock implements Block {
MovingObjectPosition nmsHitResult = null;
if (collidableBlock) {
nmsHitResult = net.minecraft.server.Block.a(blockData, world.getMinecraftWorld(), position, startPos, endPos); // PAIL rayTrace
nmsHitResult = net.minecraft.server.Block.rayTrace(blockData, world.getMinecraftWorld(), position, startPos, endPos);
}
if (nmsHitResult == null && collideWithFluid) {
nmsHitResult = VoxelShapes.a(0.0D, 0.0D, 0.0D, 1.0D, (double) fluid.f(), 1.0D).a(startPos, endPos, position); // PAIL create, getHeight, rayTrace
nmsHitResult = VoxelShapes.create(0.0D, 0.0D, 0.0D, 1.0D, (double) fluid.getHeight(), 1.0D).rayTrace(startPos, endPos, position);
}
return CraftRayTraceResult.fromNMS(this.getWorld(), nmsHitResult);

View File

@@ -47,12 +47,12 @@ public class CraftEndGateway extends CraftBlockEntityState<TileEntityEndGateway>
@Override
public long getAge() {
return this.getSnapshot().e;
return this.getSnapshot().age;
}
@Override
public void setAge(long age) {
this.getSnapshot().e = age;
this.getSnapshot().age = age;
}
@Override