Move subtitles into the HUD overlays and save scoreboards end to end
The subtitle overlay now lays out GuiDraw calls in hud_overlays and the game paints them like the other overlays. Hover events that show an entity save its UUID as an int array, as UUIDUtil.CODEC does. The save round trip builds a vanilla scoreboard with every saved field (objectives, number formats, display slots, locked and displayed scores, teams with every option) and requires Horizon to save scoreboard.dat as vanilla did. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -98,6 +98,15 @@ public final class VanillaScoreboardOracle {
|
||||
if (tag instanceof DoubleTag d) {
|
||||
return new JsonPrimitive("d:" + Long.toHexString(Double.doubleToRawLongBits(d.value())));
|
||||
}
|
||||
if (tag instanceof IntArrayTag a) {
|
||||
JsonObject o = new JsonObject();
|
||||
JsonArray v = new JsonArray();
|
||||
for (int i : a.getAsIntArray()) {
|
||||
v.add(i);
|
||||
}
|
||||
o.add("I;", v);
|
||||
return o;
|
||||
}
|
||||
return new JsonPrimitive("?" + tag.getType().getName());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user