Exempt players in creative/spectator from nether ceiling damage (#8427)

This commit is contained in:
Warrior 2022-10-07 20:43:26 +02:00 committed by GitHub
parent bcb4220b5f
commit 60c973e461
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
33 changed files with 91 additions and 90 deletions

View file

@ -5,10 +5,10 @@ Subject: [PATCH] Add back EntityPortalExitEvent
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 517ee85a7425d89e4197887eb6b385bc64ecedd3..07ba08de35bac64eeac2657e15dcc60d1dce3cca 100644
index bce565c170c37f8009303bda9c5eb7c2a83ef795..ad51baf7d9e22f7181f718a332b3ae23d7e4d1b5 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3163,6 +3163,23 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
@@ -3164,6 +3164,23 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
} else {
// CraftBukkit start
worldserver = shapedetectorshape.world;
@ -32,7 +32,7 @@ index 517ee85a7425d89e4197887eb6b385bc64ecedd3..07ba08de35bac64eeac2657e15dcc60d
if (worldserver == this.level) {
// SPIGOT-6782: Just move the entity if a plugin changed the world to the one the entity is already in
this.moveTo(shapedetectorshape.pos.x, shapedetectorshape.pos.y, shapedetectorshape.pos.z, shapedetectorshape.yRot, shapedetectorshape.xRot);
@@ -3182,8 +3199,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
@@ -3183,8 +3200,8 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
if (entity != null) {
entity.restoreFrom(this);