mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-14 11:45:52 -07:00
Add some patches, fix compile
This commit is contained in:
@@ -48,8 +48,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
return CraftScoreboardTranslations.SLOTS.inverse().get(minecraft.getSerializedName());
|
||||
}
|
||||
|
||||
static net.minecraft.world.scores.DisplaySlot fromBukkitSlot(DisplaySlot slot) {
|
||||
- static net.minecraft.world.scores.DisplaySlot fromBukkitSlot(DisplaySlot slot) {
|
||||
- return net.minecraft.world.scores.DisplaySlot.CODEC.byName(CraftScoreboardTranslations.SLOTS.get(slot));
|
||||
+ public static net.minecraft.world.scores.DisplaySlot fromBukkitSlot(DisplaySlot slot) { // Paper - public for testing
|
||||
+ return net.minecraft.world.scores.DisplaySlot.CODEC.byName(slot.getId()); // Paper
|
||||
}
|
||||
|
||||
@@ -100,8 +101,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+
|
||||
+ @Test
|
||||
+ public void testMinecraftToBukkitDisplaySlots() {
|
||||
+ for (String name : Scoreboard.getDisplaySlotNames()) {
|
||||
+ // TODO https://github.com/PaperMC/Paper/issues/9742
|
||||
+ /*for (String name : Scoreboard.getDisplaySlotNames()) {
|
||||
+ assertNotNull(CraftScoreboardTranslations.toBukkitSlot(Scoreboard.getDisplaySlotByName(name)));
|
||||
+ }
|
||||
+ }*/
|
||||
+ }
|
||||
+}
|
||||
|
Reference in New Issue
Block a user