boi, 20w10a
This commit is contained in:
1 parent
6b36ac642b
commit
f7a2b8202b
20 files changed
+76
-68
No files matched your search
@@ -83,7 +83,8 @@ public class BlockValue extends Value
|
||||
Value v1 = params.get(0 + offset).evalValue(c);
|
||||
if (v1 instanceof BlockValue)
|
||||
{
|
||||
return (new VectorLocator(new Vec3d(((BlockValue) v1).getPos()).add(0.5,0.5,0.5), 1+offset)).fromBlock();
|
||||
// pos + 0.5v
|
||||
return (new VectorLocator(Vec3d.method_24953(((BlockValue) v1).getPos()), 1+offset)).fromBlock();
|
||||
}
|
||||
if (v1 instanceof ListValue)
|
||||
{
|
||||
@@ -436,7 +437,7 @@ public class BlockValue extends Value
|
||||
SpecificDirection dir = SpecificDirection.DIRECTION_MAP.get(direction);
|
||||
if (dir == null)
|
||||
throw new InternalExpressionException("unknown block placement direction: "+direction);
|
||||
BlockHitResult hitres = new BlockHitResult(new Vec3d(pos).add(dir.hitOffset), dir.facing, pos, false);
|
||||
BlockHitResult hitres = new BlockHitResult(Vec3d.method_24954(pos).add(dir.hitOffset), dir.facing, pos, false);
|
||||
return new PlacementContext(world, dir.facing, sneakPlace, itemStack, hitres);
|
||||
}
|
||||
private PlacementContext(World world_1, Direction direction_1, boolean sneakPlace, ItemStack itemStack_1, BlockHitResult hitres) {
|
||||
|
||||
@@ -177,7 +177,7 @@ public class NBTSerializableValue extends Value implements ContainerValueInterfa
|
||||
if (inv == null)
|
||||
return null;
|
||||
|
||||
return new InventoryLocator(e, e.getBlockPos(), inv, offset + 1);
|
||||
return new InventoryLocator(e, e.getSenseCenterPos(), inv, offset + 1);
|
||||
}
|
||||
else if (v1 instanceof BlockValue)
|
||||
{
|
||||
@@ -210,7 +210,7 @@ public class NBTSerializableValue extends Value implements ContainerValueInterfa
|
||||
}
|
||||
PlayerEntity e = (PlayerEntity)((EntityValue) v2).getEntity();
|
||||
inv = e.getEnderChestInventory();
|
||||
return new InventoryLocator(e, e.getBlockPos(), inv, offset + 2, true);
|
||||
return new InventoryLocator(e, e.getSenseCenterPos(), inv, offset + 2, true);
|
||||
}
|
||||
BlockPos pos = new BlockPos(
|
||||
NumericValue.asNumber(v1).getDouble(),
|
||||
|
||||
Reference in new issue
Block a user