mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-01-09 08:50:29 +00:00
Log current block entity in TickScheduler
This check should be impossible (the BE has not been removed, but is no longer present in the world), but we've had one instance where it has happened (#1925). I don't have a good solution here, so at least let's print both BEs for now.
This commit is contained in:
parent
216f0adb3c
commit
bfb28b4710
@ -109,8 +109,9 @@ public final class TickScheduler {
|
||||
return State.UNLOADED;
|
||||
} else {
|
||||
// This should be impossible: either the block entity is at the above position, or it has been removed.
|
||||
if (level.getBlockEntity(pos) != blockEntity) {
|
||||
throw new IllegalStateException("Expected " + blockEntity + " at " + pos);
|
||||
var currentBlockEntity = level.getBlockEntity(pos);
|
||||
if (currentBlockEntity != blockEntity) {
|
||||
throw new IllegalStateException("Expected " + blockEntity + " at " + pos + ", got " + currentBlockEntity);
|
||||
}
|
||||
|
||||
// Otherwise schedule a tick and remove it from the queue.
|
||||
|
Loading…
Reference in New Issue
Block a user