Minecraft: Java Edition 26.3 rewritten from scratch in Rust, checked against vanilla with 281 differential harnesses. Get it with the Horizon launcher.
Rust differential-testinggame-enginegamedevlinuxminecraftminecraft-javareimplementationrustvoxelvulkanwgpu
Localization: sign edit's Done, the AI Agent page, the newer graphics settings and the Extras page follow the language (#1927)
Mariuslozo78a634a19152
diff --git a/crates/horizon-client-core/src/lang.rs b/crates/horizon-client-core/src/lang.rsindex 7fa3a96d1..16be4e537 100644--- a/crates/horizon-client-core/src/lang.rs+++ b/crates/horizon-client-core/src/lang.rs@@ -3,6 +3,7 @@//! from `pack.mcmeta` `language` sections, and a process-wide current//! language used by every screen.use std::{+ cell::RefCell,collections::{BTreeMap, HashMap},sync::{Arc, RwLock,@@ -34,6 +35,15 @@ pub struct Language {pub const DEFAULT: &str = "en_us";static CURRENT: RwLock<Option<Arc<Language>>> = RwLock::new(None);+/// A language that only the calling thread sees, and the keys it was asked for and did not have+/// (`scoped`).+struct Scope {+ language: Arc<Language>,+ missed: Vec<String>,+}+thread_local! {+ static SCOPE: RefCell<Option<Scope>> = const { RefCell::new(None) };+}/// The current language's `bidirectional`, read for every drawn string.static BIDIRECTIONAL: AtomicBool = AtomicBool::new(false);@@ -254,8 +264,50 @@ pub fn set(language: Language) {*CURRENT.write().unwrap_or_else(|e| e.into_inner()) = Some(Arc::new(language));}pub fn current() -> Option<Arc<Language>> {+ if let Some(language) = SCOPE.with(|s| s.borrow().as_ref().map(|s| s.language.clone())) {+ return Some(language);+ }CURRENT.read().unwrap_or_else(|e| e.into_inner()).clone()}+/// Runs `f` with `language` as the current language of this thread only, and returns what it+/// returned with the keys `get` and `get_or` looked up and `language` did not have, in the order+/// asked and without repeats. Nothing is set process-wide, so a test can draw a screen in another+/// language while the tests beside it read theirs. Scopes nest: the inner one wins, and the outer+/// one's misses do not include the inner one's. For tests: `bidirectional` stays the process-wide+/// language's.+pub fn scoped<R>(language: Language, f: impl FnOnce() -> R) -> (R, Vec<String>) {+ /// Puts the outer scope back, also when `f` panics.+ struct Restore(Option<Scope>);+ impl Drop for Restore {+ fn drop(&mut self) {+ SCOPE.with(|s| *s.borrow_mut() = self.0.take());+ }+ }+ let outer = SCOPE.with(|s| {+ s.borrow_mut().replace(Scope {+ language: Arc::new(language),+ missed: Vec::new(),+ })+ });+ let _restore = Restore(outer);+ let result = f();+ let missed = SCOPE.with(|s| {+ s.borrow_mut()+ .as_mut()+ .map(|s| std::mem::take(&mut s.missed))+ });+ (result, missed.unwrap_or_default())+}+/// `key` was asked for in a `scoped` language that has no text for it.+fn missed(key: &str) {+ SCOPE.with(|s| {+ if let Some(scope) = s.borrow_mut().as_mut()+ && !scope.missed.iter().any(|m| m == key)+ {+ scope.missed.push(key.to_owned());+ }+ });+}/// `ClientLanguage.defaultRightToLeft` of the current language.pub fn bidirectional() -> bool {BIDIRECTIONAL.load(Ordering::Relaxed)@@ -267,13 +319,19 @@ pub fn code() -> String {pub fn get(key: &str) -> String {current().and_then(|l| l.get(key).map(str::to_owned))- .unwrap_or_else(|| key.to_owned())+ .unwrap_or_else(|| {+ missed(key);+ key.to_owned()+ })}/// The translation, or `fallback` when the key is missing.pub fn get_or(key: &str, fallback: &str) -> String {current().and_then(|l| l.get(key).map(str::to_owned))- .unwrap_or_else(|| fallback.to_owned())+ .unwrap_or_else(|| {+ missed(key);+ fallback.to_owned()+ })}pub fn has(key: &str) -> bool {current().is_some_and(|l| l.get(key).is_some())@@ -350,6 +408,52 @@ mod tests {);}+ #[test]+ fn a_scoped_language_is_the_calling_threads_and_reports_what_it_lacks() {+ let empty = Mem(HashMap::new());+ let outside = code();+ let ((german, english_only, fallback, elsewhere), missed) =+ scoped(Language::load(&[&empty], "de_de"), || {+ (+ get("horizon.osk.close"),+ get("horizon.no_such_key"),+ get_or("horizon.no_fallback", "English"),+ // Another thread keeps the process-wide language.+ std::thread::spawn(code).join().unwrap(),+ )+ });+ assert_eq!(german, "Schließen");+ assert_eq!(english_only, "horizon.no_such_key");+ assert_eq!(fallback, "English");+ assert_eq!(elsewhere, outside);+ assert_eq!(missed, ["horizon.no_such_key", "horizon.no_fallback"]);+ // The scope ends with its closure.+ assert_eq!(code(), outside);+ }++ #[test]+ fn scopes_nest_and_end_when_their_closure_panics() {+ let empty = Mem(HashMap::new());+ let outside = code();+ let (inner, missed) = scoped(Language::load(&[&empty], "fr_fr"), || {+ let (inner, inner_missed) = scoped(Language::load(&[&empty], "pl_pl"), || {+ (code(), get("horizon.inner_miss"))+ });+ assert_eq!(inner_missed, ["horizon.inner_miss"]);+ assert_eq!(code(), "fr_fr");+ inner.0+ });+ assert_eq!(inner, "pl_pl");+ assert!(missed.is_empty());+ let panicked = std::panic::catch_unwind(|| {+ scoped(Language::load(&[&Mem(HashMap::new())], "de_de"), || {+ panic!("a test failed inside a scope")+ })+ });+ assert!(panicked.is_err());+ assert_eq!(code(), outside);+ }+/// `crates/horizon-client/assets/horizon/lang`, where Horizon's own strings live.fn bundled_dir() -> std::path::PathBuf {std::path::Path::new(env!("CARGO_MANIFEST_DIR"))diff --git a/crates/horizon-client-render/src/graphics_ui.rs b/crates/horizon-client-render/src/graphics_ui.rsindex 1432ff07c..2ab2f0cca 100644--- a/crates/horizon-client-render/src/graphics_ui.rs+++ b/crates/horizon-client-render/src/graphics_ui.rs@@ -2229,4 +2229,112 @@ mod tests {}}}+ /// Horizon's graphics captions are English sentences that the language table keys by+ /// themselves, so a caption, description or value that is not in `en_us.json` shows in+ /// English in every language. Every text the three pages show, with each setting cycled+ /// through its values (#1927).+ #[test]+ fn every_graphics_text_is_in_the_language_table() {+ let (_, missed) = lang::scoped(lang::Language::load(&[], "de_de"), || {+ for hdr in [false, true] {+ let mut s = Settings::default();+ s.horizon.hdr = hdr;+ s.horizon.taa = true;+ for level in [Level::Simple, Level::Advanced, Level::Hdr] {+ for _ in 0..8 {+ for row in extra_rows(level, &s) {+ match row {+ Row::Header(name) => {+ lang::get(name);+ }+ Row::Setting(row) => {+ row.item.label(&s);+ let text = description(row.item, &s, row.text);+ lang::get(text);+ lang::get(row.cost.label());+ if let Some(why) = row.item.blocked(&s) {+ lang::get(why);+ }+ }+ }+ }+ for row in extra_rows(level, &s) {+ if let Row::Setting(Setting {+ item: Item::Horizon(h),+ ..+ }) = row+ {+ h.cycle(&mut s, false);+ }+ }+ }+ }+ }+ for button in ["Advanced...", "Simple...", "Done"] {+ lang::get(button);+ }+ });+ // `labelled` also looks up values that are already words in the language ("An") or+ // numbers with a unit ("12 chunks", "Auto (8)"); those are not keys, and "FSR 3.1" is+ // a name.+ let missed: Vec<_> = missed+ .into_iter()+ .filter(|m| !m.starts_with(|c: char| c.is_ascii_digit()) && !m.starts_with("Auto ("))+ .filter(|m| !["An", "Aus", "FSR 3.1", "key.keyboard.unknown"].contains(&m.as_str()))+ .collect();+ assert_eq!(missed, Vec::<String>::new());+ }+ /// Leaf Culling, Frame Generation and Shadow Cache came with English captions only (#1927).+ #[test]+ fn newer_graphics_settings_are_translated() {+ let mut s = Settings::default();+ s.horizon.leaf_culling = LeafCullingMode::Hollow;+ s.horizon.entity_culling = EntityCullingMode::Asynchronous;+ for (code, leaf, entity, leaf_text) in [+ (+ "de_de",+ "Laub-Culling: Hohl",+ "Objekt-Culling: Asynchron",+ "Lässt Flächen zwischen Blättern weg: schneller, aber Lücken sind durchsichtig.",+ ),+ (+ "pl_pl",+ "Pomijanie liści: Puste",+ "Pomijanie bytów: Asynchroniczne",+ "Pomija ściany między liśćmi: szybciej, ale luki są przezroczyste.",+ ),+ (+ "uk_ua",+ "Відсікання листя: Порожнє",+ "Відсік. сутностей: Асинхронно",+ "Прибирає грані між листям: швидше, але прогалини прозорі.",+ ),+ (+ "zh_cn",+ "树叶剔除: 镂空",+ "实体剔除: 异步",+ "省略树叶之间的面:更快,但缝隙会透视。",+ ),+ (+ "fr_fr",+ "Occlusion feuillage: Creux",+ "Occlusion des entités: Asynchrone",+ "Supprime les faces entre feuilles : plus rapide, mais on voit à travers les trous.",+ ),+ ] {+ let (shown, _) = lang::scoped(lang::Language::load(&[], code), || {+ let item = |h| Item::Horizon(h);+ (+ item(H::LeafCulling).label(&s).plain(),+ item(H::EntityCulling).label(&s).plain(),+ lang::get(description(item(H::LeafCulling), &s, "")),+ )+ });+ assert_eq!(+ shown,+ (leaf.into(), entity.into(), leaf_text.into()),+ "{code}"+ );+ }+ }}diff --git a/crates/horizon-client-render/src/options_ui.rs b/crates/horizon-client-render/src/options_ui.rsindex acbc12a6c..c0678919a 100644--- a/crates/horizon-client-render/src/options_ui.rs+++ b/crates/horizon-client-render/src/options_ui.rs@@ -5345,6 +5345,61 @@ mod tests {assert!(ui.resource_error.is_none());}+ /// The texts of an options page, as laid out in `code`'s language, and the keys it lacked.+ fn page_texts(code: &str, pages: &[Page]) -> (Vec<String>, Vec<String>) {+ let s = Settings::default();+ lang::scoped(lang::Language::load(&[], code), || {+ let mut texts = Vec::new();+ for page in pages {+ let mut ui = OptionsUi::default();+ ui.show(*page);+ for w in ui.layout(&s, 480.0, 4000.0).0 {+ match w.kind {+ WKind::Button { label: t, .. }+ | WKind::Slider { label: t, .. }+ | WKind::Text { text: t, .. } => texts.push(t.plain()),+ _ => {}+ }+ }+ }+ texts+ })+ }++ /// Horizon's own options pages said "Splitscreen...", "Hide block-break particles" and+ /// "Hotbar: Previous Slot" in every language (#1927).+ #[test]+ fn horizon_option_pages_follow_the_language() {+ let (texts, missed) = page_texts("de_de", &[Page::Horizon, Page::Extras, Page::PadBinds]);+ for want in [+ "Splitscreen …",+ "Partikel",+ "Blockpartikel weg: Aus",+ "Weicher Chat: Aus",+ "Nachrichtenmarkierung: An",+ "Kanäle für UI-Töne: Aus",+ "Schnellzugriffsleiste: Vorheriger Platz",+ "Schnellzugriffsleiste: Nächster Platz",+ ] {+ assert!(texts.iter().any(|t| t == want), "{want:?} not in {texts:?}");+ }+ // Every key these pages ask for is in the table; vanilla's own keys (`options.*`,+ // `key.*`: dotted ids without spaces) come from the prepared resources, which this+ // language does not have.+ let missed: Vec<_> = missed+ .into_iter()+ .filter(|k| k.starts_with("horizon.") || k.contains(' ') || !k.contains('.'))+ .collect();+ assert_eq!(missed, Vec::<String>::new());+ let (texts, _) = page_texts("pl_pl", &[Page::Extras, Page::PadBinds]);+ for want in [+ "Ukryj cząstki bloków: Wył.",+ "Pasek szybkiego wyboru: poprzednie pole",+ ] {+ assert!(texts.iter().any(|t| t == want), "{want:?} not in {texts:?}");+ }+ }+#[test]fn classic_mods_page_toggles_mods_and_keeps_dev_and_invalid_entries_inactive() {let atlas = atlas();diff --git a/crates/horizon-client/assets/horizon/lang/de_de.json b/crates/horizon-client/assets/horizon/lang/de_de.jsonindex 57c2c1c8a..94195a6cd 100644--- a/crates/horizon-client/assets/horizon/lang/de_de.json+++ b/crates/horizon-client/assets/horizon/lang/de_de.json@@ -95,6 +95,7 @@"UI Brightness": "GUI-Helligkeit","Battery Mode": "Akkumodus","Graphics API": "Grafik-API",+ "Translucent Batching": "Transparenz-Batching","Performance Overlay": "Leistungsanzeige","Full Detail Distance": "Detailweite","On": "An",@@ -142,6 +143,7 @@"This feature is not yet available in Horizon.": "Diese Funktion ist in Horizon noch nicht verfügbar.","Your display or system doesn't offer HDR output.": "Dein Bildschirm oder System unterstützt keine HDR-Ausgabe.","Turn HDR on to use it.": "Schalte HDR ein, um es zu nutzen.",+ "Your GPU or graphics API doesn't support it.": "Deine GPU oder Grafik-API unterstützt das nicht.","%s chunks": "%s Chunks","%s per frame": "%s pro Bild","%s MiB/frame": "%s MiB/Bild",@@ -167,7 +169,6 @@"How far mobs, crops and machines keep working. CPU time.": "Wie weit Kreaturen, Pflanzen und Maschinen weiterarbeiten. Kostet CPU-Zeit.","How far away mobs and items are drawn, as a share of normal.": "Zeichenweite für Kreaturen und Gegenstände, anteilig zur Norm.","Skips terrain hidden behind closed sections. Off costs a lot.": "Überspringt Gelände hinter geschlossenen Abschnitten. Aus kostet viel.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Versteckt Modelle hinter Blöcken. Bei eigenen Paketen ausschalten.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Mesh-Abschnitte pro Bild. Weniger: flüssigeres Laden.","Soft shadows in corners. Costs chunk building time only.": "Weiche Schatten in Ecken. Kostet nur Zeit beim Chunk-Aufbau.","Smaller copies of block textures for distant terrain: less shimmer.": "Kleinere Textur-Kopien für fernes Gelände: weniger Flimmern.",@@ -201,6 +202,7 @@"60 FPS cap (30 in menus or unfocused), half the workers: less power.": "60 FPS (30 im Menü/ohne Fokus), halb so viele Worker: spart Strom.","Threads that generate, light and mesh chunks. Next start.": "Threads für Erzeugung, Licht und Mesh der Chunks. Nach Neustart.","Vulkan, then DirectX 12 (Windows) or OpenGL (Linux) where it fails. Next start.": "Vulkan, sonst DirectX 12 (Windows) oder OpenGL (Linux). Nach Neustart.",+ "Water and glass in one buffer: fewer draw calls, a bit more VRAM. Next start.": "Wasser und Glas in einem Puffer: weniger Draw-Calls, etwas mehr VRAM. Nach Neustart.","Mesh data sent to the GPU per frame. Lower is smoother while loading.": "Pro Bild an die GPU gesendete Mesh-Daten. Weniger ist flüssiger beim Laden.","Frame rate and frame times over the game, with a graph.": "Bildrate und Bildzeiten über dem Spiel, mit Diagramm.","horizon.multiplayer.finding_friend": "Die Welt deines Freundes wird gesucht …",@@ -289,5 +291,53 @@"horizon.multiplayer.not_signed_in": "Dieser Server läuft im Online-Modus. Melde dich im Horizon-Launcher mit deinem Microsoft-Konto an, um ihm beizutreten.","horizon.multiplayer.invalid_address": "Ungültige Serveradresse: %s","horizon.multiplayer.connected_friend_direct": "Direkt mit deinem Freund verbunden …",- "horizon.multiplayer.connected_friend_relay": "Über das Relay mit deinem Freund verbunden …"+ "horizon.multiplayer.connected_friend_relay": "Über das Relay mit deinem Freund verbunden …",+ "Culling": "Culling",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "Versteckt Modelle hinter Blöcken. Prüfung im Hintergrund; Objekte laufen weiter.",+ "Leaf Culling": "Laub-Culling",+ "Every leaf face. Vanilla's fancy leaves.": "Jede Blattfläche, wie Minecraft sie bei schönen Blättern zeichnet.",+ "Distant Plant Dither": "Pflanzen-Dithering",+ "Keeps fine plants in high-res packs from fading far away.": "Verhindert, dass feine Pflanzen in hochauflösenden Paketen in der Ferne verblassen.",+ "Screenshot Quality": "Screenshot-Qualität",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "F2-Screenshots in diesem Vielfachen der Spielauflösung. Höher dauert länger.",+ "Frame Generation": "Bildgenerierung",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "Zeigt zwischen zwei echten Bildern ein errechnetes: flüssiger, etwas mehr Verzögerung.",+ "Shadow Cache": "Schatten-Cache",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "Verwendet die Schattenkarte des Pakets erneut, wenn Sonne, Blick und Welt gleich bleiben. Standardmäßig aus.",+ "Synchronous": "Synchron",+ "Asynchronous": "Asynchron",+ "Solid": "Massiv",+ "Solid Aggressive": "Massiv, aggressiv",+ "Hollow": "Hohl",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "Blätter mitten im Blätterdach werden massiv gezeichnet: weniger durchsichtige Schichten.",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "Auch Blätter mit einer offenen Seite werden massiv gezeichnet: schneller, gröbere Kanten.",+ "Drops faces between leaves: faster, but gaps look through.": "Lässt Flächen zwischen Blättern weg: schneller, aber Lücken sind durchsichtig.",+ "Hotbar: Previous Slot": "Schnellzugriffsleiste: Vorheriger Platz",+ "Hotbar: Next Slot": "Schnellzugriffsleiste: Nächster Platz",+ "horizon.agent.connected.one": "Verbunden: 1 Agentenverbindung",+ "horizon.agent.connected.many": "Verbunden: %s Agentenverbindungen",+ "horizon.agent.connected.one_ago": "Verbunden: 1 Agentenverbindung, letzter Befehl vor %s s",+ "horizon.agent.connected.many_ago": "Verbunden: %s Agentenverbindungen, letzter Befehl vor %s s",+ "horizon.agent.waiting": "Wartet auf einen Agenten.",+ "horizon.agent.off": "Aus: Agenten können dieses Spiel nicht erreichen.",+ "horizon.agent.session_opened": "Für diese Sitzung von dem Programm geöffnet, das das Spiel gestartet hat.",+ "horizon.agent.socket": "Socket: %s (Verbindungsdaten kopieren für den vollständigen Pfad)",+ "horizon.agent.local_only": "Nur lokal: Agenten auf diesem Computer, nie über das Netzwerk.",+ "horizon.extras.chat_animation": "Weicher Chat",+ "horizon.extras.chat_animation.tooltip": "Eine neue Chatzeile gleitet von links herein und blendet dabei ein, statt sofort ganz zu erscheinen.",+ "horizon.extras.chat_indicator": "Nachrichtenmarkierung",+ "horizon.extras.chat_indicator.tooltip": "Der farbige Balken links neben einer Chatzeile.",+ "horizon.extras.header.chat": "Chat",+ "horizon.extras.header.particles": "Partikel",+ "horizon.extras.header.sound": "Ton",+ "horizon.extras.hide_block_particles": "Blockpartikel weg",+ "horizon.extras.hide_block_particles.tooltip": "Blendet die Trümmerpartikel aus, die aus einem zerstörten Block sprühen und von dem abbröckeln, den du abbaust. Andere Partikel bleiben.",+ "horizon.extras.splitscreen": "Splitscreen",+ "horizon.extras.splitscreen.tooltip": "In einer Welt kann ein weiterer Controller als neuer Spieler beitreten: A drücken, wenn gefragt, dann Profil und Spielort wählen.",+ "horizon.extras.ui_sound_reserve": "Kanäle für UI-Töne",+ "horizon.extras.ui_sound_reserve.tooltip": "Weltgeräusche lassen 16 der 247 Tonkanäle frei, damit eine Flut davon (eine große Explosion) Menü-Klicks nicht verstummen lässt.",+ "horizon.pages.open.split_setup": "Splitscreen …",+ "horizon.pages.split_settings": "Splitscreen-Einstellungen",+ "horizon.pages.split_setup": "Splitscreen",+ "horizon.pages.split_setup.tooltip": "Spieler an diesem Computer: Controller können deiner Welt beitreten."}diff --git a/crates/horizon-client/assets/horizon/lang/en_us.json b/crates/horizon-client/assets/horizon/lang/en_us.jsonindex 9cd6fe524..6377b543e 100644--- a/crates/horizon-client/assets/horizon/lang/en_us.json+++ b/crates/horizon-client/assets/horizon/lang/en_us.json@@ -173,7 +173,6 @@"How far mobs, crops and machines keep working. CPU time.": "How far mobs, crops and machines keep working. CPU time.","How far away mobs and items are drawn, as a share of normal.": "How far away mobs and items are drawn, as a share of normal.","Skips terrain hidden behind closed sections. Off costs a lot.": "Skips terrain hidden behind closed sections. Off costs a lot.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Hides models behind opaque blocks. Entities update. Off with custom packs.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Meshed sections uploaded per frame. Lower is smoother while loading.","Soft shadows in corners. Costs chunk building time only.": "Soft shadows in corners. Costs chunk building time only.","Smaller copies of block textures for distant terrain: less shimmer.": "Smaller copies of block textures for distant terrain: less shimmer.",@@ -309,5 +308,36 @@"horizon.osk.close": "Close","horizon.extras.chat_animation.tooltip": "A new chat line slides in from the left while it fades in, instead of appearing whole.","horizon.extras.chat_indicator.tooltip": "The coloured bar at the left of a chat line.",- "horizon.extras.splitscreen.tooltip": "In a world, another controller can join as a new player: press A when it asks, then pick a profile and where to play."+ "horizon.extras.splitscreen.tooltip": "In a world, another controller can join as a new player: press A when it asks, then pick a profile and where to play.",+ "Culling": "Culling",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "Hides models behind opaque blocks. Async checks off-thread; entities tick.",+ "Leaf Culling": "Leaf Culling",+ "Every leaf face. Vanilla's fancy leaves.": "Every leaf face. Vanilla's fancy leaves.",+ "Distant Plant Dither": "Distant Plant Dither",+ "Keeps fine plants in high-res packs from fading far away.": "Keeps fine plants in high-res packs from fading far away.",+ "Screenshot Quality": "Screenshot Quality",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "F2 screenshots at this many times the game's resolution. Higher takes longer.",+ "Frame Generation": "Frame Generation",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "Shows a made-up frame between each two real ones: smoother, a little more lag.",+ "Shadow Cache": "Shadow Cache",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "Reuses the pack shadow map when sun, view and world match. Off by default.",+ "Synchronous": "Synchronous",+ "Asynchronous": "Asynchronous",+ "Solid": "Solid",+ "Solid Aggressive": "Solid Aggressive",+ "Hollow": "Hollow",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "Leaves fully inside a canopy draw solid: fewer see-through layers.",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "Leaves with one open side draw solid too: faster, chunkier edges.",+ "Drops faces between leaves: faster, but gaps look through.": "Drops faces between leaves: faster, but gaps look through.",+ "Hotbar: Previous Slot": "Hotbar: Previous Slot",+ "Hotbar: Next Slot": "Hotbar: Next Slot",+ "horizon.agent.connected.one": "Connected: 1 agent connection",+ "horizon.agent.connected.many": "Connected: %s agent connections",+ "horizon.agent.connected.one_ago": "Connected: 1 agent connection, last command %s s ago",+ "horizon.agent.connected.many_ago": "Connected: %s agent connections, last command %s s ago",+ "horizon.agent.waiting": "Waiting for an agent.",+ "horizon.agent.off": "Off: agents can't reach this game.",+ "horizon.agent.session_opened": "Opened for this session by the program that started the game.",+ "horizon.agent.socket": "Socket: %s (copy the details for its full path)",+ "horizon.agent.local_only": "Local only: agents on this computer, never the network."}diff --git a/crates/horizon-client/assets/horizon/lang/es_es.json b/crates/horizon-client/assets/horizon/lang/es_es.jsonindex 9fd06db71..2291278e2 100644--- a/crates/horizon-client/assets/horizon/lang/es_es.json+++ b/crates/horizon-client/assets/horizon/lang/es_es.json@@ -161,7 +161,6 @@"How far mobs, crops and machines keep working. CPU time.": "Hasta dónde siguen funcionando mobs, cultivos y máquinas. Tiempo de CPU.","How far away mobs and items are drawn, as a share of normal.": "A qué distancia se dibujan mobs y objetos, como proporción de lo normal.","Skips terrain hidden behind closed sections. Off costs a lot.": "Omite el terreno oculto tras secciones cerradas. Desactivarlo cuesta mucho.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Oculta modelos tras bloques opacos. Las entidades se actualizan. Desactivado con paquetes personalizados.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Secciones malladas subidas por fotograma. Menos es más fluido durante la carga.","Soft shadows in corners. Costs chunk building time only.": "Sombras suaves en las esquinas. Solo cuesta tiempo de construcción de chunks.","Smaller copies of block textures for distant terrain: less shimmer.": "Copias más pequeñas de las texturas de bloques para el terreno lejano: menos parpadeo.",diff --git a/crates/horizon-client/assets/horizon/lang/fr_fr.json b/crates/horizon-client/assets/horizon/lang/fr_fr.jsonindex 56bedd872..20e5254b1 100644--- a/crates/horizon-client/assets/horizon/lang/fr_fr.json+++ b/crates/horizon-client/assets/horizon/lang/fr_fr.json@@ -95,6 +95,7 @@"UI Brightness": "Luminosité UI","Battery Mode": "Mode batterie","Graphics API": "API graphique",+ "Translucent Batching": "Regroupement translucide","Performance Overlay": "Infos de perfs","Full Detail Distance": "Dist. détail","On": "Oui",@@ -142,6 +143,7 @@"This feature is not yet available in Horizon.": "Cette fonction n'est pas encore disponible dans Horizon.","Your display or system doesn't offer HDR output.": "Votre écran ou votre système ne propose pas de sortie HDR.","Turn HDR on to use it.": "Activez le HDR pour l'utiliser.",+ "Your GPU or graphics API doesn't support it.": "Votre GPU ou votre API graphique ne le prend pas en charge.","%s chunks": "%s chunks","%s per frame": "%s par image","%s MiB/frame": "%s MiB/image",@@ -167,7 +169,6 @@"How far mobs, crops and machines keep working. CPU time.": "Portée d'activité des créatures, cultures, machines. Coût : CPU.","How far away mobs and items are drawn, as a share of normal.": "Distance des créatures et objets, en part de la normale.","Skips terrain hidden behind closed sections. Off costs a lot.": "Ignore le terrain caché. Désactiver coûte cher.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Masque les modèles derrière les blocs. Éteindre avec packs.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Sections maillées par image. Moins : chargement plus fluide.","Soft shadows in corners. Costs chunk building time only.": "Ombres douces dans les coins. Coût : construction des chunks.","Smaller copies of block textures for distant terrain: less shimmer.": "Textures réduites au loin : moins de scintillement.",@@ -201,6 +202,7 @@"60 FPS cap (30 in menus or unfocused), half the workers: less power.": "60 FPS max (30 en menu/sans focus), moitié de threads : économie.","Threads that generate, light and mesh chunks. Next start.": "Threads de génération, lumière et maillage. Au redémarrage.","Vulkan, then DirectX 12 (Windows) or OpenGL (Linux) where it fails. Next start.": "Vulkan, sinon DirectX 12 (Windows) ou OpenGL (Linux). Au redémarrage.",+ "Water and glass in one buffer: fewer draw calls, a bit more VRAM. Next start.": "Eau et verre dans un seul tampon : moins d'appels de dessin, un peu plus de VRAM. Au redémarrage.","Mesh data sent to the GPU per frame. Lower is smoother while loading.": "Données de maillage vers le GPU par image. Moins : plus fluide.","Frame rate and frame times over the game, with a graph.": "Fréquence et temps d'image par-dessus le jeu, avec un graphique.","horizon.multiplayer.finding_friend": "Recherche du monde de votre ami...",@@ -289,5 +291,53 @@"horizon.multiplayer.not_signed_in": "Ce serveur est en mode en ligne. Connectez-vous avec votre compte Microsoft dans le lanceur Horizon pour le rejoindre.","horizon.multiplayer.invalid_address": "Adresse de serveur invalide : %s","horizon.multiplayer.connected_friend_direct": "Connecté directement à votre ami...",- "horizon.multiplayer.connected_friend_relay": "Connecté à votre ami via le relais..."+ "horizon.multiplayer.connected_friend_relay": "Connecté à votre ami via le relais...",+ "Culling": "Occlusion",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "Masque les modèles derrière les blocs opaques. Vérification en arrière-plan ; les entités continuent.",+ "Leaf Culling": "Occlusion feuillage",+ "Every leaf face. Vanilla's fancy leaves.": "Toutes les faces de feuillage, comme les feuilles détaillées de Minecraft.",+ "Distant Plant Dither": "Tramage des plantes",+ "Keeps fine plants in high-res packs from fading far away.": "Empêche les plantes fines des packs haute résolution de s'estomper au loin.",+ "Screenshot Quality": "Qualité des captures",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "Captures F2 à ce multiple de la résolution du jeu. Plus c'est haut, plus c'est long.",+ "Frame Generation": "Génération d'images",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "Insère une image calculée entre deux vraies : plus fluide, un peu plus de latence.",+ "Shadow Cache": "Cache des ombres",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "Réutilise la carte d'ombres du pack si soleil, vue et monde sont identiques. Désactivé par défaut.",+ "Synchronous": "Synchrone",+ "Asynchronous": "Asynchrone",+ "Solid": "Opaque",+ "Solid Aggressive": "Opaque agressif",+ "Hollow": "Creux",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "Les feuilles au cœur d'un feuillage sont opaques : moins de couches transparentes.",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "Les feuilles avec un côté ouvert sont aussi opaques : plus rapide, bords plus grossiers.",+ "Drops faces between leaves: faster, but gaps look through.": "Supprime les faces entre feuilles : plus rapide, mais on voit à travers les trous.",+ "Hotbar: Previous Slot": "Barre d'action : case précédente",+ "Hotbar: Next Slot": "Barre d'action : case suivante",+ "horizon.agent.connected.one": "Connecté : 1 connexion d'agent",+ "horizon.agent.connected.many": "Connecté : %s connexions d'agent",+ "horizon.agent.connected.one_ago": "Connecté : 1 connexion d'agent, dernière commande il y a %s s",+ "horizon.agent.connected.many_ago": "Connecté : %s connexions d'agent, dernière commande il y a %s s",+ "horizon.agent.waiting": "En attente d'un agent.",+ "horizon.agent.off": "Désactivé : les agents ne peuvent pas joindre ce jeu.",+ "horizon.agent.session_opened": "Ouvert pour cette session par le programme qui a lancé le jeu.",+ "horizon.agent.socket": "Socket : %s (copiez les détails pour le chemin complet)",+ "horizon.agent.local_only": "Local uniquement : agents sur cet ordinateur, jamais via le réseau.",+ "horizon.extras.chat_animation": "Chat fluide",+ "horizon.extras.chat_animation.tooltip": "Une nouvelle ligne de chat glisse depuis la gauche en apparaissant progressivement, au lieu d'apparaître d'un coup.",+ "horizon.extras.chat_indicator": "Marqueur de message",+ "horizon.extras.chat_indicator.tooltip": "La barre colorée à gauche d'une ligne de chat.",+ "horizon.extras.header.chat": "Chat",+ "horizon.extras.header.particles": "Particules",+ "horizon.extras.header.sound": "Son",+ "horizon.extras.hide_block_particles": "Masquer particules",+ "horizon.extras.hide_block_particles.tooltip": "Masque les débris qui jaillissent d'un bloc cassé et s'effritent de celui que vous minez. Les autres particules restent.",+ "horizon.extras.splitscreen": "Écran partagé",+ "horizon.extras.splitscreen.tooltip": "Dans un monde, une autre manette peut rejoindre en tant que nouveau joueur : appuyez sur A quand c'est demandé, puis choisissez un profil et où jouer.",+ "horizon.extras.ui_sound_reserve": "Canaux pour sons UI",+ "horizon.extras.ui_sound_reserve.tooltip": "Les sons du monde laissent 16 des 247 canaux sonores libres, pour qu'un déluge de sons (une grosse explosion) ne couvre pas les clics de menu.",+ "horizon.pages.open.split_setup": "Écran partagé...",+ "horizon.pages.split_settings": "Options de l'écran partagé",+ "horizon.pages.split_setup": "Écran partagé",+ "horizon.pages.split_setup.tooltip": "Joueurs sur cet ordinateur : des manettes peuvent rejoindre votre monde."}diff --git a/crates/horizon-client/assets/horizon/lang/pl_pl.json b/crates/horizon-client/assets/horizon/lang/pl_pl.jsonindex b20b4e9fb..02e017c7b 100644--- a/crates/horizon-client/assets/horizon/lang/pl_pl.json+++ b/crates/horizon-client/assets/horizon/lang/pl_pl.json@@ -95,6 +95,7 @@"UI Brightness": "Jasność interfejsu","Battery Mode": "Tryb baterii","Graphics API": "API grafiki",+ "Translucent Batching": "Grupowanie półprzezroczystych","Performance Overlay": "Nakładka wydajności","Full Detail Distance": "Zasięg detali","On": "Wł.",@@ -142,6 +143,7 @@"This feature is not yet available in Horizon.": "Ta funkcja nie jest jeszcze dostępna w Horizon.","Your display or system doesn't offer HDR output.": "Twój wyświetlacz lub system nie obsługuje wyjścia HDR.","Turn HDR on to use it.": "Włącz HDR, aby tego użyć.",+ "Your GPU or graphics API doesn't support it.": "Twoje GPU lub API graficzne tego nie obsługuje.","%s chunks": "%s chunków","%s per frame": "%s na klatkę","%s MiB/frame": "%s MiB/klatka",@@ -167,7 +169,6 @@"How far mobs, crops and machines keep working. CPU time.": "Jak daleko stworzenia, uprawy i maszyny nadal działają. Czas procesora.","How far away mobs and items are drawn, as a share of normal.": "Odległość rysowania stworzeń i przedmiotów, jako ułamek normy.","Skips terrain hidden behind closed sections. Off costs a lot.": "Pomija teren ukryty za zamkniętymi sekcjami. Wyłączone dużo kosztuje.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Ukrywa modele za pełnymi blokami. Wył. przy własnych paczkach.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Liczba sekcji siatki wysyłanych na klatkę. Mniej to płynniej podczas ładowania.","Soft shadows in corners. Costs chunk building time only.": "Miękkie cienie w narożnikach. Kosztuje tylko czas budowania chunków.","Smaller copies of block textures for distant terrain: less shimmer.": "Mniejsze kopie tekstur bloków dla odległego terenu: mniej migotania.",@@ -201,6 +202,7 @@"60 FPS cap (30 in menus or unfocused), half the workers: less power.": "Limit 60 FPS (30 w menu/bez fokusu), połowa wątków: mniej energii.","Threads that generate, light and mesh chunks. Next start.": "Wątki generujące, oświetlające i meshujące chunki. Po restarcie.","Vulkan, then DirectX 12 (Windows) or OpenGL (Linux) where it fails. Next start.": "Vulkan, awaryjnie DirectX 12 (Windows) / OpenGL (Linux). Po restarcie.",+ "Water and glass in one buffer: fewer draw calls, a bit more VRAM. Next start.": "Woda i szkło w jednym buforze: mniej wywołań rysowania, trochę więcej VRAM. Po restarcie.","Mesh data sent to the GPU per frame. Lower is smoother while loading.": "Dane siatki wysyłane do GPU na klatkę. Mniej to płynniej podczas ładowania.","Frame rate and frame times over the game, with a graph.": "Liczba klatek i czasy klatek nad grą, z wykresem.","horizon.multiplayer.finding_friend": "Szukanie świata znajomego…",@@ -289,5 +291,53 @@"horizon.osk.delete": "Usuń","horizon.osk.type": "Wpisz","horizon.osk.symbols": "Symbole",- "horizon.osk.close": "Zamknij"+ "horizon.osk.close": "Zamknij",+ "Culling": "Pomijanie",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "Ukrywa modele za pełnymi blokami. Sprawdzanie w tle; byty nadal się aktualizują.",+ "Leaf Culling": "Pomijanie liści",+ "Every leaf face. Vanilla's fancy leaves.": "Każda ściana liści, tak jak rysuje je Minecraft.",+ "Distant Plant Dither": "Dithering roślin",+ "Keeps fine plants in high-res packs from fading far away.": "Zapobiega zanikaniu drobnych roślin w paczkach wysokiej rozdzielczości w oddali.",+ "Screenshot Quality": "Jakość zrzutów ekranu",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "Zrzuty F2 w tylokrotności rozdzielczości gry. Więcej trwa dłużej.",+ "Frame Generation": "Generowanie klatek",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "Pokazuje wygenerowaną klatkę między każdymi dwiema prawdziwymi: płynniej, trochę większe opóźnienie.",+ "Shadow Cache": "Pamięć cieni",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "Używa ponownie mapy cieni paczki, gdy słońce, widok i świat się zgadzają. Domyślnie wyłączone.",+ "Synchronous": "Synchroniczne",+ "Asynchronous": "Asynchroniczne",+ "Solid": "Pełne",+ "Solid Aggressive": "Pełne, agresywnie",+ "Hollow": "Puste",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "Liście w środku korony rysują się jako pełne: mniej przezroczystych warstw.",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "Liście z jedną otwartą stroną też rysują się jako pełne: szybciej, grubsze krawędzie.",+ "Drops faces between leaves: faster, but gaps look through.": "Pomija ściany między liśćmi: szybciej, ale luki są przezroczyste.",+ "Hotbar: Previous Slot": "Pasek szybkiego wyboru: poprzednie pole",+ "Hotbar: Next Slot": "Pasek szybkiego wyboru: następne pole",+ "horizon.agent.connected.one": "Połączono: 1 połączenie agenta",+ "horizon.agent.connected.many": "Połączenia agenta: %s",+ "horizon.agent.connected.one_ago": "Połączono: 1 połączenie agenta, ostatnie polecenie %s s temu",+ "horizon.agent.connected.many_ago": "Połączenia agenta: %s, ostatnie polecenie %s s temu",+ "horizon.agent.waiting": "Czeka na agenta.",+ "horizon.agent.off": "Wyłączone: agenci nie mają dostępu do tej gry.",+ "horizon.agent.session_opened": "Otwarte na tę sesję przez program, który uruchomił grę.",+ "horizon.agent.socket": "Gniazdo: %s (skopiuj dane, aby poznać pełną ścieżkę)",+ "horizon.agent.local_only": "Tylko lokalnie: agenci na tym komputerze, nigdy przez sieć.",+ "horizon.extras.chat_animation": "Płynny czat",+ "horizon.extras.chat_animation.tooltip": "Nowa linia czatu wsuwa się z lewej i pojawia stopniowo, zamiast wyświetlać się od razu w całości.",+ "horizon.extras.chat_indicator": "Znacznik wiadomości",+ "horizon.extras.chat_indicator.tooltip": "Kolorowy pasek po lewej stronie linii czatu.",+ "horizon.extras.header.chat": "Czat",+ "horizon.extras.header.particles": "Cząsteczki",+ "horizon.extras.header.sound": "Dźwięk",+ "horizon.extras.hide_block_particles": "Ukryj cząstki bloków",+ "horizon.extras.hide_block_particles.tooltip": "Ukrywa cząsteczki odłamków, które tryskają ze zniszczonego bloku i kruszą się z tego, który kopiesz. Inne cząsteczki zostają.",+ "horizon.extras.splitscreen": "Podzielony ekran",+ "horizon.extras.splitscreen.tooltip": "W świecie może dołączyć kolejny kontroler jako nowy gracz: naciśnij A, gdy zapyta, potem wybierz profil i miejsce gry.",+ "horizon.extras.ui_sound_reserve": "Kanały dla dźwięków UI",+ "horizon.extras.ui_sound_reserve.tooltip": "Dźwięki świata zostawiają wolnych 16 z 247 kanałów, by ich nawał (duży wybuch) nie wyciszył kliknięć w menu.",+ "horizon.pages.open.split_setup": "Podzielony ekran…",+ "horizon.pages.split_settings": "Ustawienia podzielonego ekranu",+ "horizon.pages.split_setup": "Podzielony ekran",+ "horizon.pages.split_setup.tooltip": "Gracze na tym komputerze: kontrolery mogą dołączyć do twojego świata."}diff --git a/crates/horizon-client/assets/horizon/lang/ru_ru.json b/crates/horizon-client/assets/horizon/lang/ru_ru.jsonindex 2f92bac71..87f16c401 100644--- a/crates/horizon-client/assets/horizon/lang/ru_ru.json+++ b/crates/horizon-client/assets/horizon/lang/ru_ru.json@@ -160,7 +160,6 @@"How far mobs, crops and machines keep working. CPU time.": "Как далеко мобы, посевы и механизмы продолжают работать. Нагрузка на процессор.","How far away mobs and items are drawn, as a share of normal.": "С какой дистанции рисуются мобы и предметы, в долях от обычной.","Skips terrain hidden behind closed sections. Off costs a lot.": "Пропускает рельеф, скрытый за закрытыми секциями. Выключено — дорого.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Прячет модели за непрозрачными блоками. Сущности тикают. Выключать со своими наборами.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Секций меша за кадр. Меньше — плавнее во время загрузки.","Soft shadows in corners. Costs chunk building time only.": "Мягкие тени по углам. Замедляет только построение чанков.","Smaller copies of block textures for distant terrain: less shimmer.": "Уменьшенные копии текстур блоков для дали: меньше мерцания.",diff --git a/crates/horizon-client/assets/horizon/lang/tr_tr.json b/crates/horizon-client/assets/horizon/lang/tr_tr.jsonindex 8034c7898..6f5381fc4 100644--- a/crates/horizon-client/assets/horizon/lang/tr_tr.json+++ b/crates/horizon-client/assets/horizon/lang/tr_tr.json@@ -161,7 +161,6 @@"How far mobs, crops and machines keep working. CPU time.": "Yaratıkların, ekinlerin ve makinelerin ne kadar uzaktan çalışmaya devam edeceğini belirler. İşlemci gücü kullanır.","How far away mobs and items are drawn, as a share of normal.": "Yaratıkların ve eşyaların ne kadar uzaktan görüntüleneceğini, normal mesafeye oranla belirler.","Skips terrain hidden behind closed sections. Off costs a lot.": "Kapalı alanların arkasında kalan arazilerin çizilmesini önler. Kapalı olması ciddi performans kaybına neden olur.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Opak blokların arkasında kalan modelleri gizler. Varlıkların güncellemeleri devam eder. Özel paketler kullanırken kapatın.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Her karede GPU'ya yüklenen oluşturulmuş bölüm sayısı. Daha düşük değerler yükleme sırasında daha akıcı bir deneyim sağlar.","Soft shadows in corners. Costs chunk building time only.": "Köşelerde yumuşak gölgeler oluşturur. Yalnızca parça oluşturma süresini etkiler.","Smaller copies of block textures for distant terrain: less shimmer.": "Uzak arazilerde blok dokularının daha küçük kopyalarını kullanır. Titreşimli görüntüyü azaltır.",diff --git a/crates/horizon-client/assets/horizon/lang/uk_ua.json b/crates/horizon-client/assets/horizon/lang/uk_ua.jsonindex 8362fd154..bf97437ae 100644--- a/crates/horizon-client/assets/horizon/lang/uk_ua.json+++ b/crates/horizon-client/assets/horizon/lang/uk_ua.json@@ -95,6 +95,7 @@"UI Brightness": "Яскравість UI","Battery Mode": "Режим батареї","Graphics API": "API графіки",+ "Translucent Batching": "Групування напівпрозорого","Performance Overlay": "Накладка швидкодії","Full Detail Distance": "Дальність деталей","On": "Увімк.",@@ -142,6 +143,7 @@"This feature is not yet available in Horizon.": "Ця функція ще недоступна в Horizon.","Your display or system doesn't offer HDR output.": "Ваш дисплей або система не підтримує вивід HDR.","Turn HDR on to use it.": "Увімкніть HDR, щоб користуватися цим.",+ "Your GPU or graphics API doesn't support it.": "Ваш GPU або графічний API цього не підтримує.","%s chunks": "%s чанків","%s per frame": "%s на кадр","%s MiB/frame": "%s MiB/кадр",@@ -167,7 +169,6 @@"How far mobs, crops and machines keep working. CPU time.": "Як далеко працюють моби, посіви й механізми. Витрачає CPU.","How far away mobs and items are drawn, as a share of normal.": "Відстань малювання мобів і предметів, у частці від норми.","Skips terrain hidden behind closed sections. Off costs a lot.": "Пропускає приховану місцевість. Вимкнення коштує дорого.",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "Ховає моделі за блоками. Вимкніть із власними пакетами.","Meshed sections uploaded per frame. Lower is smoother while loading.": "Секцій сітки за кадр. Менше — плавніше під час завантаження.","Soft shadows in corners. Costs chunk building time only.": "М’які тіні в кутах. Витрачає лише час на побудову чанків.","Smaller copies of block textures for distant terrain: less shimmer.": "Менші копії текстур блоків для віддаленої місцевості: менше мерехтіння.",@@ -201,6 +202,7 @@"60 FPS cap (30 in menus or unfocused), half the workers: less power.": "60 FPS (30 у меню/без фокуса), половина потоків: економія.","Threads that generate, light and mesh chunks. Next start.": "Потоки генерації, світла й сітки чанків. Після перезапуску.","Vulkan, then DirectX 12 (Windows) or OpenGL (Linux) where it fails. Next start.": "Vulkan, інакше DirectX 12 (Windows)/OpenGL (Linux). Після рестарту.",+ "Water and glass in one buffer: fewer draw calls, a bit more VRAM. Next start.": "Вода і скло в одному буфері: менше викликів малювання, трохи більше VRAM. Після перезапуску.","Mesh data sent to the GPU per frame. Lower is smoother while loading.": "Дані сітки до GPU за кадр. Менше — плавніше завантаження.","Frame rate and frame times over the game, with a graph.": "Частота та час кадрів поверх гри, з графіком.","horizon.multiplayer.finding_friend": "Шукаємо світ друга…",@@ -289,5 +291,53 @@"horizon.osk.delete": "Видалити","horizon.osk.type": "Ввести","horizon.osk.symbols": "Символи",- "horizon.osk.close": "Закрити"+ "horizon.osk.close": "Закрити",+ "Culling": "Відсікання",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "Ховає моделі за непрозорими блоками. Перевірка у фоні; сутності оновлюються.",+ "Leaf Culling": "Відсікання листя",+ "Every leaf face. Vanilla's fancy leaves.": "Кожна грань листя, як це робить Minecraft у гарній графіці.",+ "Distant Plant Dither": "Дизеринг рослин",+ "Keeps fine plants in high-res packs from fading far away.": "Не дає дрібним рослинам у пакетах високої роздільності зникати здалеку.",+ "Screenshot Quality": "Якість знімків екрана",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "Знімки F2 у стільки разів більшій роздільності, ніж гра. Більше значить довше.",+ "Frame Generation": "Генерація кадрів",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "Показує згенерований кадр між кожними двома справжніми: плавніше, трохи більша затримка.",+ "Shadow Cache": "Кеш тіней",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "Повторно використовує карту тіней пакета, коли сонце, вигляд і світ збігаються. Типово вимкнено.",+ "Synchronous": "Синхронно",+ "Asynchronous": "Асинхронно",+ "Solid": "Суцільне",+ "Solid Aggressive": "Суцільне, агресивно",+ "Hollow": "Порожнє",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "Листя всередині крони малюється суцільним: менше прозорих шарів.",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "Листя з одним відкритим боком теж малюється суцільним: швидше, грубіші краї.",+ "Drops faces between leaves: faster, but gaps look through.": "Прибирає грані між листям: швидше, але прогалини прозорі.",+ "Hotbar: Previous Slot": "Панель швидкого доступу: попередній слот",+ "Hotbar: Next Slot": "Панель швидкого доступу: наступний слот",+ "horizon.agent.connected.one": "Підключено: 1 з’єднання агента",+ "horizon.agent.connected.many": "Підключено з’єднань агента: %s",+ "horizon.agent.connected.one_ago": "Підключено: 1 з’єднання агента, остання команда %s с тому",+ "horizon.agent.connected.many_ago": "Підключено з’єднань агента: %s, остання команда %s с тому",+ "horizon.agent.waiting": "Очікування агента.",+ "horizon.agent.off": "Вимкнено: агенти не можуть дістатися цієї гри.",+ "horizon.agent.session_opened": "Відкрито на цей сеанс програмою, що запустила гру.",+ "horizon.agent.socket": "Сокет: %s (скопіюйте дані, щоб побачити повний шлях)",+ "horizon.agent.local_only": "Лише локально: агенти на цьому комп’ютері, ніколи через мережу.",+ "horizon.extras.chat_animation": "Плавний чат",+ "horizon.extras.chat_animation.tooltip": "Новий рядок чату виїжджає зліва, поступово з’являючись, замість того щоб з’явитися одразу.",+ "horizon.extras.chat_indicator": "Позначка повідомлення",+ "horizon.extras.chat_indicator.tooltip": "Кольорова смужка ліворуч від рядка чату.",+ "horizon.extras.header.chat": "Чат",+ "horizon.extras.header.particles": "Частинки",+ "horizon.extras.header.sound": "Звук",+ "horizon.extras.hide_block_particles": "Без частинок блоків",+ "horizon.extras.hide_block_particles.tooltip": "Ховає частинки уламків, що розлітаються зі зламаного блока та осипаються з того, який ви ламаєте. Інші частинки залишаються.",+ "horizon.extras.splitscreen": "Розділений екран",+ "horizon.extras.splitscreen.tooltip": "У світі може долучитися ще один геймпад як новий гравець: натисніть A, коли запитає, потім виберіть профіль і де грати.",+ "horizon.extras.ui_sound_reserve": "Канали для звуків UI",+ "horizon.extras.ui_sound_reserve.tooltip": "Звуки у світі залишають вільними 16 із 247 звукових каналів, щоб їхній потік (великий вибух) не заглушив кліки в меню.",+ "horizon.pages.open.split_setup": "Розділений екран…",+ "horizon.pages.split_settings": "Налаштування розділеного екрана",+ "horizon.pages.split_setup": "Розділений екран",+ "horizon.pages.split_setup.tooltip": "Гравці на цьому комп’ютері: геймпади можуть долучитися до вашого світу."}diff --git a/crates/horizon-client/assets/horizon/lang/zh_cn.json b/crates/horizon-client/assets/horizon/lang/zh_cn.jsonindex 15ac07583..832cfcb46 100644--- a/crates/horizon-client/assets/horizon/lang/zh_cn.json+++ b/crates/horizon-client/assets/horizon/lang/zh_cn.json@@ -89,6 +89,7 @@"UI Brightness": "界面亮度","Battery Mode": "电池模式","Graphics API": "图形 API",+ "Translucent Batching": "半透明批处理","Performance Overlay": "性能叠加层","Full Detail Distance": "全细节距离","On": "开",@@ -136,6 +137,7 @@"This feature is not yet available in Horizon.": "此功能在 Horizon 中尚不可用。","Your display or system doesn't offer HDR output.": "你的显示器或系统不支持 HDR 输出。","Turn HDR on to use it.": "开启 HDR 后才能使用。",+ "Your GPU or graphics API doesn't support it.": "你的 GPU 或图形 API 不支持此功能。","%s chunks": "%s 个区块","%s per frame": "每帧 %s","%s MiB/frame": "每帧 %s MiB",@@ -161,7 +163,6 @@"How far mobs, crops and machines keep working. CPU time.": "生物、农作物和机器持续工作的距离。占用 CPU 时间。","How far away mobs and items are drawn, as a share of normal.": "生物和物品的绘制距离,按正常值的比例。","Skips terrain hidden behind closed sections. Off costs a lot.": "跳过被封闭区块遮挡的地形。关闭的开销很大。",- "Hides models behind opaque blocks. Entities update. Off with custom packs.": "隐藏不透明方块后面的模型。实体仍会更新。自定义资源包时应关闭。","Meshed sections uploaded per frame. Lower is smoother while loading.": "每帧上传的网格化区块数。越低加载时越流畅。","Soft shadows in corners. Costs chunk building time only.": "角落里的柔和阴影。只占用区块构建时间。","Smaller copies of block textures for distant terrain: less shimmer.": "为远处地形生成更小的方块纹理副本:减少闪烁。",@@ -195,6 +196,7 @@"60 FPS cap (30 in menus or unfocused), half the workers: less power.": "限制 60 FPS(菜单或失焦时 30),工作线程减半:更省电。","Threads that generate, light and mesh chunks. Next start.": "负责生成、光照与网格化区块的线程数。下次启动生效。","Vulkan, then DirectX 12 (Windows) or OpenGL (Linux) where it fails. Next start.": "优先 Vulkan,失败时用 DirectX 12(Windows)或 OpenGL(Linux)。下次启动生效。",+ "Water and glass in one buffer: fewer draw calls, a bit more VRAM. Next start.": "水和玻璃放在同一个缓冲区:绘制调用更少,显存略多。下次启动生效。","Mesh data sent to the GPU per frame. Lower is smoother while loading.": "每帧发送给 GPU 的网格数据。越低加载时越流畅。","Frame rate and frame times over the game, with a graph.": "游戏运行时的帧率与帧时间,附带图表。","horizon.multiplayer.finding_friend": "正在查找好友的世界…",@@ -306,5 +308,36 @@"horizon.osk.close": "关闭","horizon.extras.chat_animation.tooltip": "新聊天行从左侧滑入并淡入,而不是整行直接出现。","horizon.extras.chat_indicator.tooltip": "聊天行左侧的彩色竖条。",- "horizon.extras.splitscreen.tooltip": "在世界中,另一个手柄可以以新玩家身份加入:提示时按 A,然后选择档案和游玩位置。"+ "horizon.extras.splitscreen.tooltip": "在世界中,另一个手柄可以以新玩家身份加入:提示时按 A,然后选择档案和游玩位置。",+ "Culling": "剔除",+ "Hides models behind opaque blocks. Async checks off-thread; entities tick.": "隐藏不透明方块后面的模型。检测在后台线程进行,实体仍会更新。",+ "Leaf Culling": "树叶剔除",+ "Every leaf face. Vanilla's fancy leaves.": "绘制每个树叶面,与原版的华丽树叶一致。",+ "Distant Plant Dither": "远处植物抖动",+ "Keeps fine plants in high-res packs from fading far away.": "避免高分辨率资源包中的细小植物在远处逐渐消失。",+ "Screenshot Quality": "截图质量",+ "F2 screenshots at this many times the game's resolution. Higher takes longer.": "F2 截图的分辨率为游戏分辨率的这个倍数。越高耗时越长。",+ "Frame Generation": "帧生成",+ "Shows a made-up frame between each two real ones: smoother, a little more lag.": "在每两个真实帧之间插入一个生成帧:更流畅,延迟略增。",+ "Shadow Cache": "阴影缓存",+ "Reuses the pack shadow map when sun, view and world match. Off by default.": "太阳、视角和世界不变时重复使用资源包的阴影贴图。默认关闭。",+ "Synchronous": "同步",+ "Asynchronous": "异步",+ "Solid": "实心",+ "Solid Aggressive": "激进实心",+ "Hollow": "镂空",+ "Leaves fully inside a canopy draw solid: fewer see-through layers.": "树冠内部的树叶绘制为实心:透明层更少。",+ "Leaves with one open side draw solid too: faster, chunkier edges.": "只有一面外露的树叶也绘制为实心:更快,边缘更粗糙。",+ "Drops faces between leaves: faster, but gaps look through.": "省略树叶之间的面:更快,但缝隙会透视。",+ "Hotbar: Previous Slot": "快捷栏:上一个栏位",+ "Hotbar: Next Slot": "快捷栏:下一个栏位",+ "horizon.agent.connected.one": "已连接:1 个代理连接",+ "horizon.agent.connected.many": "已连接:%s 个代理连接",+ "horizon.agent.connected.one_ago": "已连接:1 个代理连接,上次命令在 %s 秒前",+ "horizon.agent.connected.many_ago": "已连接:%s 个代理连接,上次命令在 %s 秒前",+ "horizon.agent.waiting": "正在等待代理。",+ "horizon.agent.off": "关闭:代理无法访问此游戏。",+ "horizon.agent.session_opened": "由启动游戏的程序为本次会话开启。",+ "horizon.agent.socket": "套接字:%s(复制详细信息以获取完整路径)",+ "horizon.agent.local_only": "仅限本机:此电脑上的代理可用,网络不可用。"}diff --git a/crates/horizon-client/src/game/agent_settings.rs b/crates/horizon-client/src/game/agent_settings.rsindex 5045f1c49..cd41625e6 100644--- a/crates/horizon-client/src/game/agent_settings.rs+++ b/crates/horizon-client/src/game/agent_settings.rs@@ -86,34 +86,21 @@ impl Game<'_> {let server = self.control.as_ref()- .filter(|c| !c.path().as_os_str().is_empty());- let mut lines = vec![match server {- Some(s) if s.clients() > 0 => {- let ago = self- .agent_last- .map(|t| format!(", last command {} s ago", t.elapsed().as_secs()))- .unwrap_or_default();- format!(- "Connected: {} agent connection{}{ago}",- s.clients(),- if s.clients() == 1 { "" } else { "s" }- )- }- Some(_) => "Waiting for an agent.".into(),- None => "Off: agents can't reach this game.".into(),- }];- if let Some(s) = server {- if self.options.control.is_some() && !self.agent_control_on {- lines.push("Opened for this session by the program that started the game.".into());- }- // The full path is too wide for the page: Copy Connection Details has it.- let name = s.path().file_name().unwrap_or_default().to_string_lossy();- lines.push(format!(- "Socket: {name} (copy the details for its full path)"- ));- }- lines.push("Local only: agents on this computer, never the network.".into());- lines+ .filter(|c| !c.path().as_os_str().is_empty())+ .map(|s| Socket {+ clients: s.clients(),+ name: s+ .path()+ .file_name()+ .unwrap_or_default()+ .to_string_lossy()+ .into_owned(),+ });+ status_lines(+ server,+ self.agent_last.map(|t| t.elapsed().as_secs()),+ self.options.control.is_some() && !self.agent_control_on,+ )}/// What Copy Connection Details puts on the clipboard: the socket, a horizon-ctl line to try,@@ -138,3 +125,127 @@ impl Game<'_> {)}}++/// The control socket as the AI Agent page tells of it.+struct Socket {+ /// Agents connected now.+ clients: usize,+ /// The socket's file name; the full path is too wide for the page (Copy Connection Details+ /// has it).+ name: String,+}++/// The AI Agent page's lines in the selected language: the state, then where agents connect.+/// `last_command` is the seconds since an agent's last command, `session_only` whether the+/// program that started the game opened the socket and the player's switch did not.+fn status_lines(+ server: Option<Socket>,+ last_command: Option<u64>,+ session_only: bool,+) -> Vec<String> {+ use horizon_client::lang::{get, tr};+ let mut lines = vec![match &server {+ Some(s) if s.clients > 0 => {+ let (one, many) = match last_command {+ Some(_) => ("one_ago", "many_ago"),+ None => ("one", "many"),+ };+ let key = format!(+ "horizon.agent.connected.{}",+ if s.clients == 1 { one } else { many }+ );+ let mut args: Vec<&dyn std::fmt::Display> = Vec::new();+ if s.clients != 1 {+ args.push(&s.clients);+ }+ if let Some(ago) = &last_command {+ args.push(ago);+ }+ tr(&key, &args)+ }+ Some(_) => get("horizon.agent.waiting"),+ None => get("horizon.agent.off"),+ }];+ if let Some(s) = &server {+ if session_only {+ lines.push(get("horizon.agent.session_opened"));+ }+ lines.push(tr("horizon.agent.socket", &[&s.name]));+ }+ lines.push(get("horizon.agent.local_only"));+ lines+}++#[cfg(test)]+mod tests {+ use super::{Socket, status_lines};+ use horizon_client::lang::{Language, scoped};++ fn lines(code: &str, clients: usize, ago: Option<u64>, session_only: bool) -> Vec<String> {+ let socket = Socket {+ clients,+ name: "ctl.sock".into(),+ };+ let (lines, missed) = scoped(Language::load(&[], code), || {+ status_lines(Some(socket), ago, session_only)+ });+ assert!(missed.is_empty(), "{code}: {missed:?}");+ lines+ }++ /// The AI Agent page told its state in English in every language (#1927).+ #[test]+ fn agent_page_lines_follow_the_language() {+ assert_eq!(+ lines("de_de", 2, Some(5), false),+ [+ "Verbunden: 2 Agentenverbindungen, letzter Befehl vor 5 s",+ "Socket: ctl.sock (Verbindungsdaten kopieren für den vollständigen Pfad)",+ "Nur lokal: Agenten auf diesem Computer, nie über das Netzwerk.",+ ]+ );+ assert_eq!(+ lines("pl_pl", 1, None, true),+ [+ "Połączono: 1 połączenie agenta",+ "Otwarte na tę sesję przez program, który uruchomił grę.",+ "Gniazdo: ctl.sock (skopiuj dane, aby poznać pełną ścieżkę)",+ "Tylko lokalnie: agenci na tym komputerze, nigdy przez sieć.",+ ]+ );+ let (off, missed) = scoped(Language::load(&[], "fr_fr"), || {+ status_lines(None, None, false)+ });+ assert!(missed.is_empty(), "{missed:?}");+ assert_eq!(+ off,+ [+ "Désactivé : les agents ne peuvent pas joindre ce jeu.",+ "Local uniquement : agents sur cet ordinateur, jamais via le réseau.",+ ]+ );+ }++ /// English keeps the sentences it always had: the count, its plural, the time since the last+ /// command, and the wait for a first agent.+ #[test]+ fn agent_page_lines_in_english() {+ assert_eq!(+ lines("en_us", 2, Some(5), false)[0],+ "Connected: 2 agent connections, last command 5 s ago"+ );+ assert_eq!(+ lines("en_us", 1, None, false)[0],+ "Connected: 1 agent connection"+ );+ assert_eq!(+ lines("en_us", 1, Some(0), false)[0],+ "Connected: 1 agent connection, last command 0 s ago"+ );+ assert_eq!(+ lines("en_us", 3, None, false)[0],+ "Connected: 3 agent connections"+ );+ assert_eq!(lines("en_us", 0, None, true)[0], "Waiting for an agent.");+ }+}diff --git a/crates/horizon-client/src/game/sign_edit.rs b/crates/horizon-client/src/game/sign_edit.rsindex ce29e81b1..fca643c46 100644--- a/crates/horizon-client/src/game/sign_edit.rs+++ b/crates/horizon-client/src/game/sign_edit.rs@@ -38,6 +38,10 @@ fn sign_box() -> EditBox {edit}+/// The Done button's text, `CommonComponents.GUI_DONE`, in the selected language.+fn done_label() -> String {+ super::screen_info::tr("gui.done", &[])+}/// AbstractSignEditScreen.init's Done button: `width / 2 - 100`,/// `height / 4 + 144`, int GUI pixels.fn done_button(w: f32, h: f32) -> (f32, f32) {@@ -841,11 +845,7 @@ impl Game<'_> {}let (bx, by) = done_button(w, h);horizon_client::widgets::narratable(|| {- horizon_client::widgets::Narratable::button(- super::screen_info::tr("gui.done", &[]),- [bx, by, 200.0, 20.0],- true,- )+ horizon_client::widgets::Narratable::button(done_label(), [bx, by, 200.0, 20.0], true)});batch.sprite_scaled(atlas,@@ -856,10 +856,11 @@ impl Game<'_> {20.0,u32::MAX,);- let tw = HudBatch::text_width(atlas, "Done");+ let done = done_label();+ let tw = HudBatch::text_width(atlas, &done);batch.text(atlas,- "Done",+ &done,bx + 100.0 - (tw / 2.0).floor(),by + 6.0,u32::MAX,@@ -876,4 +877,27 @@ mod tests {assert_eq!(super::done_button(427.0, 334.0), (113.0, 227.0));assert_eq!(super::done_button(320.0, 240.0), (60.0, 204.0));}++ /// The Done button said "Done" in every language (#1927).+ #[test]+ fn done_button_reads_the_selected_language() {+ use horizon_client::lang::{Language, ResourceSource, scoped};+ struct Vanilla;+ impl ResourceSource for Vanilla {+ fn read(&self, path: &str) -> Option<Vec<u8>> {+ match path {+ "assets/minecraft/lang/en_us.json" => Some(br#"{"gui.done": "Done"}"#.to_vec()),+ "assets/minecraft/lang/de_de.json" => {+ Some(br#"{"gui.done": "Fertig"}"#.to_vec())+ }+ _ => None,+ }+ }+ }+ for (code, want) in [("de_de", "Fertig"), ("en_us", "Done")] {+ let (label, missed) = scoped(Language::load(&[&Vanilla], code), super::done_label);+ assert_eq!(label, want, "{code}");+ assert!(missed.is_empty(), "{code}: {missed:?}");+ }+ }}