fixes
This commit is contained in:
parent
f6636fca9e
commit
f5f80a4aed
|
@ -37,7 +37,7 @@ index f48b830a9ae8160388cb0d0220a44b1ec9f0d214..5045507871db402305a43430194b4c5e
|
||||||
+ // Paper end - More Lidded Block API
|
+ // Paper end - More Lidded Block API
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java b/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java b/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
||||||
index 25add8bee6ea35beeb205dd828759304346e4f48..d4a5810111c81845c3b465468b470535f814889b 100644
|
index 25add8bee6ea35beeb205dd828759304346e4f48..599f6747dfa140e40fef26ed4d8244bfe87b7cdf 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftEnderChest.java
|
||||||
@@ -14,4 +14,33 @@ public class CraftEnderChest extends CraftBlockEntityState<EnderChestBlockEntity
|
@@ -14,4 +14,33 @@ public class CraftEnderChest extends CraftBlockEntityState<EnderChestBlockEntity
|
||||||
|
@ -51,7 +51,7 @@ index 25add8bee6ea35beeb205dd828759304346e4f48..d4a5810111c81845c3b465468b470535
|
||||||
+ requirePlaced();
|
+ requirePlaced();
|
||||||
+ if (!getTileEntity().openersCounter.opened) {
|
+ if (!getTileEntity().openersCounter.opened) {
|
||||||
+ net.minecraft.world.level.Level world = getTileEntity().getLevel();
|
+ net.minecraft.world.level.Level world = getTileEntity().getLevel();
|
||||||
+ world.blockEvent(getTileEntity().getBlockPos(), getTileEntity().getBlockState().getBlock(), 1, getTileEntity().getViewerCount() + 1);
|
+ world.blockEvent(getTileEntity().getBlockPos(), getTileEntity().getBlockState().getBlock(), 1, getTileEntity().openersCounter.getOpenerCount() + 1);
|
||||||
+ world.playSound(null, getPosition(), net.minecraft.sounds.SoundEvents.ENDER_CHEST_OPEN, net.minecraft.sounds.SoundSource.BLOCKS, 0.5F, world.random.nextFloat() * 0.1F + 0.9F);
|
+ world.playSound(null, getPosition(), net.minecraft.sounds.SoundEvents.ENDER_CHEST_OPEN, net.minecraft.sounds.SoundSource.BLOCKS, 0.5F, world.random.nextFloat() * 0.1F + 0.9F);
|
||||||
+ }
|
+ }
|
||||||
+ getTileEntity().openersCounter.opened = true;
|
+ getTileEntity().openersCounter.opened = true;
|
||||||
|
|
|
@ -21,7 +21,7 @@ index 75a02252f398b3d16f8588693e71f779d7fa062a..f2981aa82c26d7bdac08f45818813025
|
||||||
}
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
diff --git a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
||||||
index 2c4c1fc2a2afe88864b72d86708a3ddb6a1f50a0..5b9ba62ce37aabb268d76c23f5cb41a4a5c61a2f 100644
|
index 2c4c1fc2a2afe88864b72d86708a3ddb6a1f50a0..567a9755e7ef0d6bf1803a3ba8460fb7de2e66b1 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
--- a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
+++ b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EndCrystal.java
|
||||||
@@ -31,6 +31,7 @@ public class EndCrystal extends Entity {
|
@@ -31,6 +31,7 @@ public class EndCrystal extends Entity {
|
||||||
|
@ -32,7 +32,7 @@ index 2c4c1fc2a2afe88864b72d86708a3ddb6a1f50a0..5b9ba62ce37aabb268d76c23f5cb41a4
|
||||||
|
|
||||||
public EndCrystal(EntityType<? extends EndCrystal> type, Level world) {
|
public EndCrystal(EntityType<? extends EndCrystal> type, Level world) {
|
||||||
super(type, world);
|
super(type, world);
|
||||||
@@ -67,8 +68,20 @@ public class EndCrystal extends Entity {
|
@@ -67,6 +68,17 @@ public class EndCrystal extends Entity {
|
||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
}
|
}
|
||||||
|
@ -49,7 +49,12 @@ index 2c4c1fc2a2afe88864b72d86708a3ddb6a1f50a0..5b9ba62ce37aabb268d76c23f5cb41a4
|
||||||
+ // Paper end
|
+ // Paper end
|
||||||
}
|
}
|
||||||
|
|
||||||
+ if (this.generatedByDragonFight) tag.putBoolean("Paper.GeneratedByDragonFight", this.generatedByDragonFight); // Paper - Fix invulnerable end crystals
|
}
|
||||||
|
@@ -78,6 +90,7 @@ public class EndCrystal extends Entity {
|
||||||
|
}
|
||||||
|
|
||||||
|
nbt.putBoolean("ShowBottom", this.showsBottom());
|
||||||
|
+ if (this.generatedByDragonFight) nbt.putBoolean("Paper.GeneratedByDragonFight", this.generatedByDragonFight); // Paper - Fix invulnerable end crystals
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -57,7 +62,7 @@ index 2c4c1fc2a2afe88864b72d86708a3ddb6a1f50a0..5b9ba62ce37aabb268d76c23f5cb41a4
|
||||||
if (nbt.contains("ShowBottom", 1)) {
|
if (nbt.contains("ShowBottom", 1)) {
|
||||||
this.setShowBottom(nbt.getBoolean("ShowBottom"));
|
this.setShowBottom(nbt.getBoolean("ShowBottom"));
|
||||||
}
|
}
|
||||||
+ if (tag.contains("Paper.GeneratedByDragonFight", 1)) this.generatedByDragonFight = tag.getBoolean("Paper.GeneratedByDragonFight"); // Paper - Fix invulnerable end crystals
|
+ if (nbt.contains("Paper.GeneratedByDragonFight", 1)) this.generatedByDragonFight = nbt.getBoolean("Paper.GeneratedByDragonFight"); // Paper - Fix invulnerable end crystals
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@ Move the tick logic into the post tick, where portaling was
|
||||||
designed to happen in the first place.
|
designed to happen in the first place.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
index 5d4bee5470795bd9f362fff5ae653794223fa182..3e665504ff2138f8bc40cfac74b5af722d91f6e9 100644
|
index 5d4bee5470795bd9f362fff5ae653794223fa182..b2478c6aee858c362f92c292635bb14f812ccf0b 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||||
@@ -341,6 +341,37 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n
|
@@ -341,6 +341,37 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, n
|
||||||
|
@ -31,7 +31,7 @@ index 5d4bee5470795bd9f362fff5ae653794223fa182..3e665504ff2138f8bc40cfac74b5af72
|
||||||
+ return;
|
+ return;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
+ if (this.isPassenger() || this.isVehicle() || !this.canChangeDimensions() || this.removed || !this.valid || !this.isAlive()) {
|
+ if (this.isPassenger() || this.isVehicle() || !this.canChangeDimensions() || this.isRemoved() || !this.valid || !this.isAlive()) {
|
||||||
+ return;
|
+ return;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
|
|
Loading…
Reference in New Issue