mirror of
https://github.com/YatopiaMC/Yatopia.git
synced 2024-12-01 15:13:24 +01:00
58e66daeb4
Upstream/An Sidestream has released updates that appears to apply and compile correctly This update has NOT been tested by YatopiaMC and as with ANY update, please do your own testing. Tuinity Changes: a405b1b Merge branch 'master' of https://github.com/Spottedleaf/Tuinity into ver/1.16.4 f06591a Updated Upstream (Paper) 48d3556 Prevent light queue overfill when no players are online Origami Changes: 78f4af0 Require Java 11 b70595f Fix patch rebuilding for MojangAPI module 34170a7 Update Paper Purpur Changes: 3d455ff Updated Upstream (Paper & Tuinity) 7152b72 [ci-skip] Use shadowJar output as input for paperclip 822a35a [ci-skip] Publish shadowJar as server artifact f142481 Resolves #125 - Full netherite armor grants fire resistance 5e269e1 Updated Upstream (Paper) AirplaneLite Changes: 9326301 Update upstream, fix utf8
54 lines
1.8 KiB
Diff
54 lines
1.8 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: JellySquid <jellysquid+atwork@protonmail.com>
|
|
Date: Mon, 11 May 2020 21:02:57 +0200
|
|
Subject: [PATCH] lithium MixinBox
|
|
|
|
Original code by JellySquid, licensed under GNU Lesser General Public License v3.0
|
|
you can find the original code on https://github.com/jellysquid3/lithium-fabric/tree/1.16.x/fabric (Yarn mappings)
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/AxisAlignedBB.java b/src/main/java/net/minecraft/server/AxisAlignedBB.java
|
|
index acd009844099293befd28c5f1c20d947016fa19b..4fb61603ca2d7cb7df9742c72117f4d33bd2bbdf 100644
|
|
--- a/src/main/java/net/minecraft/server/AxisAlignedBB.java
|
|
+++ b/src/main/java/net/minecraft/server/AxisAlignedBB.java
|
|
@@ -202,12 +202,38 @@ public class AxisAlignedBB {
|
|
return new AxisAlignedBB(vec3d.x, vec3d.y, vec3d.z, vec3d.x + 1.0D, vec3d.y + 1.0D, vec3d.z + 1.0D);
|
|
}
|
|
|
|
+ /**
|
|
+ * @reason Simplify the code to better help the JVM optimize it
|
|
+ * @author JellySquid
|
|
+ */
|
|
public double a(EnumDirection.EnumAxis enumdirection_enumaxis) {
|
|
- return enumdirection_enumaxis.a(this.minX, this.minY, this.minZ);
|
|
+ switch (enumdirection_enumaxis) {
|
|
+ case X:
|
|
+ return this.minX;
|
|
+ case Y:
|
|
+ return this.minY;
|
|
+ case Z:
|
|
+ return this.minZ;
|
|
+ }
|
|
+
|
|
+ throw new IllegalArgumentException();
|
|
}
|
|
|
|
+ /**
|
|
+ * @reason Simplify the code to better help the JVM optimize it
|
|
+ * @author JellySquid
|
|
+ */
|
|
public double b(EnumDirection.EnumAxis enumdirection_enumaxis) {
|
|
- return enumdirection_enumaxis.a(this.maxX, this.maxY, this.maxZ);
|
|
+ switch (enumdirection_enumaxis) {
|
|
+ case X:
|
|
+ return this.maxX;
|
|
+ case Y:
|
|
+ return this.maxY;
|
|
+ case Z:
|
|
+ return this.maxZ;
|
|
+ }
|
|
+
|
|
+ throw new IllegalArgumentException();
|
|
}
|
|
|
|
public boolean equals(Object object) {
|