mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-30 04:02:50 +01:00
526795bacd
* Update patches to handle vineflower decompiler * update patches again to handle inlined simple lambdas * update vf again and re-apply/rebuild patches * update patches after removal of verify-merges flag * fix compile issue * remove maven local * fix some issues * address more issues * fix collision patch * use paperweight release * more fixes * update fineflower and fix patches again * add missing comment descriptor --------- Co-authored-by: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
33 lines
1.7 KiB
Diff
33 lines
1.7 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Spottedleaf <Spottedleaf@users.noreply.github.com>
|
|
Date: Sat, 15 Jun 2019 10:28:25 -0700
|
|
Subject: [PATCH] Show blockstate location if we failed to read it
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
|
|
index e7fd9ebd47af277d6dbced0f17e954722c202776..ff3f88f107a4c059688566b69dcdf48bc01210ab 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/block/CraftBlockEntityState.java
|
|
@@ -25,6 +25,7 @@ public class CraftBlockEntityState<T extends BlockEntity> extends CraftBlockStat
|
|
|
|
this.tileEntity = tileEntity;
|
|
|
|
+ try { // Paper - Show blockstate location if we failed to read it
|
|
// Paper start
|
|
this.snapshotDisabled = DISABLE_SNAPSHOT;
|
|
if (DISABLE_SNAPSHOT) {
|
|
@@ -37,6 +38,14 @@ public class CraftBlockEntityState<T extends BlockEntity> extends CraftBlockStat
|
|
this.load(this.snapshot);
|
|
}
|
|
// Paper end
|
|
+ // Paper start - Show blockstate location if we failed to read it
|
|
+ } catch (Throwable thr) {
|
|
+ if (thr instanceof ThreadDeath) {
|
|
+ throw (ThreadDeath)thr;
|
|
+ }
|
|
+ throw new RuntimeException("Failed to read BlockState at: world: " + this.getWorld().getName() + " location: (" + this.getX() + ", " + this.getY() + ", " + this.getZ() + ")", thr);
|
|
+ }
|
|
+ // Paper end - Show blockstate location if we failed to read it
|
|
}
|
|
|
|
protected CraftBlockEntityState(CraftBlockEntityState<T> state) {
|