Skip to content

Commit

Permalink
[1.21.4] Display correct relative position as used in GameTestHelper#…
Browse files Browse the repository at this point in the history
…relativePos (#1949)
  • Loading branch information
ChampionAsh5357 authored Feb 9, 2025
1 parent e8440e1 commit 83c257a
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
--- a/net/minecraft/gametest/framework/TestCommand.java
+++ b/net/minecraft/gametest/framework/TestCommand.java
@@ -363,7 +_,7 @@
@@ -361,9 +_,9 @@
say(serverlevel, "Structure block entity could not be found", ChatFormatting.RED);
return 0;
} else {
BlockPos blockpos1 = blockpos.subtract(optional.get());
- BlockPos blockpos1 = blockpos.subtract(optional.get());
+ BlockPos blockpos1 = blockpos.subtract(optional.get()).subtract(structureblockentity.getStructurePos()); // Neo: Match relative position to GameTestHelper#relativePos
String s = blockpos1.getX() + ", " + blockpos1.getY() + ", " + blockpos1.getZ();
- String s1 = structureblockentity.getMetaData();
+ String s1 = structureblockentity.getMetaData().isBlank() ? structureblockentity.getStructureName() : structureblockentity.getMetaData(); // Neo: use the metadata for the structure name
Expand Down

0 comments on commit 83c257a

Please sign in to comment.