--- a/net/minecraft/core/Vec3i.java
+++ b/net/minecraft/core/Vec3i.java
@@ -22,9 +_,9 @@
         ByteBufCodecs.VAR_INT, Vec3i::getX, ByteBufCodecs.VAR_INT, Vec3i::getY, ByteBufCodecs.VAR_INT, Vec3i::getZ, Vec3i::new
     );
     public static final Vec3i ZERO = new Vec3i(0, 0, 0);
-    private int x;
-    private int y;
-    private int z;
+    protected int x; // Paper - Perf: Manually inline methods in BlockPosition; protected
+    protected int y; // Paper - Perf: Manually inline methods in BlockPosition; protected
+    protected int z; // Paper - Perf: Manually inline methods in BlockPosition; protected
 
     public static Codec<Vec3i> offsetCodec(int maxOffset) {
         return CODEC.validate(
@@ -41,12 +_,12 @@
     }
 
     @Override
-    public boolean equals(Object other) {
+    public final boolean equals(Object other) { // Paper - Perf: Final for inline
         return this == other || other instanceof Vec3i vec3i && this.getX() == vec3i.getX() && this.getY() == vec3i.getY() && this.getZ() == vec3i.getZ();
     }
 
     @Override
-    public int hashCode() {
+    public final int hashCode() { // Paper - Perf: Final for inline
         return (this.getY() + this.getZ() * 31) * 31 + this.getX();
     }
 
@@ -59,15 +_,15 @@
         }
     }
 
-    public int getX() {
+    public final int getX() { // Paper - Perf: Final for inline
         return this.x;
     }
 
-    public int getY() {
+    public final int getY() { // Paper - Perf: Final for inline
         return this.y;
     }
 
-    public int getZ() {
+    public final int getZ() { // Paper - Perf: Final for inline
         return this.z;
     }
 
@@ -241,4 +_,10 @@
     public String toShortString() {
         return this.getX() + ", " + this.getY() + ", " + this.getZ();
     }
+
+    // Paper start - Perf: Optimize isInWorldBounds
+    public final boolean isInsideBuildHeightAndWorldBoundsHorizontal(final net.minecraft.world.level.LevelHeightAccessor levelHeightAccessor) {
+        return this.getX() >= -30000000 && this.getZ() >= -30000000 && this.getX() < 30000000 && this.getZ() < 30000000 && !levelHeightAccessor.isOutsideBuildHeight(this.getY());
+    }
+    // Paper end - Perf: Optimize isInWorldBounds
 }
