3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-11-15 04:20:04 +01:00
Paper/patches/server/0791-Correctly-handle-ArmorStand-invisibility.patch
2024-10-27 18:39:30 +01:00

26 Zeilen
1.1 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Jake Potrebic <jake.m.potrebic@gmail.com>
Date: Sun, 5 Mar 2023 14:38:21 -0800
Subject: [PATCH] Correctly handle ArmorStand invisibility
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
index c8713200d946b0fdd74b60d0c2c136c8226389e0..184fe8257e5ffb0ef090ffa2833786a4db8b59ea 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
@@ -152,6 +152,14 @@ public class CraftArmorStand extends CraftLivingEntity implements ArmorStand {
this.getHandle().noPhysics = !gravity;
}
+ // Paper start - Armor Stand has its own invisible field
+ @Override
+ public void setInvisible(final boolean invisible) {
+ this.getHandle().setInvisible(invisible);
+ super.setInvisible(invisible);
+ }
+ // Paper end
+
@Override
public boolean isVisible() {
return !this.getHandle().isInvisible();