aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches
diff options
context:
space:
mode:
authorBillyGalbreath <[email protected]>2021-10-19 20:46:52 -0700
committerGitHub <[email protected]>2021-10-19 20:46:52 -0700
commite5f9241d1511c2e20e3a6cdc3b611052815a5b17 (patch)
tree526edb9e2c094e093258889bd87a38d010b74dde /patches
parent40057019e07c50d132dbe8597a3794717a995e4f (diff)
downloadPaper-e5f9241d1511c2e20e3a6cdc3b611052815a5b17.tar.gz
Paper-e5f9241d1511c2e20e3a6cdc3b611052815a5b17.zip
Left handed API (#6775)
Diffstat (limited to 'patches')
-rw-r--r--patches/api/0339-Left-handed-API.patch31
-rw-r--r--patches/server/0829-Left-handed-API.patch26
2 files changed, 57 insertions, 0 deletions
diff --git a/patches/api/0339-Left-handed-API.patch b/patches/api/0339-Left-handed-API.patch
new file mode 100644
index 0000000000..c6c9f1b39f
--- /dev/null
+++ b/patches/api/0339-Left-handed-API.patch
@@ -0,0 +1,31 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: William Blake Galbreath <[email protected]>
+Date: Thu, 14 Oct 2021 12:36:46 -0500
+Subject: [PATCH] Left handed API
+
+
+diff --git a/src/main/java/org/bukkit/entity/Mob.java b/src/main/java/org/bukkit/entity/Mob.java
+index 07bedbc15ba2463d3c629ae68d229286d4033f79..984ad873f36c3dcc73703eb6902c4eab5f1e72b6 100644
+--- a/src/main/java/org/bukkit/entity/Mob.java
++++ b/src/main/java/org/bukkit/entity/Mob.java
+@@ -148,4 +148,20 @@ public interface Mob extends LivingEntity, Lootable {
+ * @return whether the mob is aware
+ */
+ public boolean isAware();
++
++ // Paper start
++ /**
++ * Check if Mob is left-handed
++ *
++ * @return True if left-handed
++ */
++ public boolean isLeftHanded();
++
++ /**
++ * Set if Mob is left-handed
++ *
++ * @param leftHanded True if left-handed
++ */
++ public void setLeftHanded(boolean leftHanded);
++ // Paper end
+ }
diff --git a/patches/server/0829-Left-handed-API.patch b/patches/server/0829-Left-handed-API.patch
new file mode 100644
index 0000000000..099fa6769c
--- /dev/null
+++ b/patches/server/0829-Left-handed-API.patch
@@ -0,0 +1,26 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: William Blake Galbreath <[email protected]>
+Date: Thu, 14 Oct 2021 12:36:58 -0500
+Subject: [PATCH] Left handed API
+
+
+diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java
+index 2386edf499cb292241f6ba60c1cdb46f2fe704ff..5a43e420f14fa52d71d41ff3694a179e7a1a5be3 100644
+--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java
++++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftMob.java
+@@ -134,5 +134,15 @@ public abstract class CraftMob extends CraftLivingEntity implements Mob {
+ public int getMaxHeadPitch() {
+ return getHandle().getMaxHeadXRot();
+ }
++
++ @Override
++ public boolean isLeftHanded() {
++ return getHandle().isLeftHanded();
++ }
++
++ @Override
++ public void setLeftHanded(boolean leftHanded) {
++ getHandle().setLeftHanded(leftHanded);
++ }
+ // Paper end
+ }