mirror of
https://github.com/db9979/uconsole_asw_game.git
synced 2026-12-05 12:24:25 +01:00
Realism levels Beginner, Standard, Realistic with a score factor
The level (options row, saved per mission) tunes only the computer opponent (AI submarine attack eagerness and firing-solution threshold, AI frigate classification and helicopter delays) and the operator assistance; the mission score is scaled by 75/100/125 %. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018ezHkjXB8fqbp1sWev2J9D
This commit is contained in:
25 files changed
+277
-56
No files matched your search
@@ -2,7 +2,7 @@
|
||||
|
||||
## Authority and scope
|
||||
|
||||
- This is U-Jagd 1.3.87 (`src/core/version.py`); current saves are v34-only. Treat these as compatibility contracts, not changelog entries.
|
||||
- This is U-Jagd 1.3.88 (`src/core/version.py`); current saves are v34-only. Treat these as compatibility contracts, not changelog entries.
|
||||
- Resolve conflicts in this order: executable code and focused tests; packaged JSON/runtime resources; `pyproject.toml` and provenance/license notices; `README.md`; design/history documents under `docs/`. A plan or old comment is not an implementation contract.
|
||||
- Preserve explicit compatibility tests and user data unless a task intentionally changes the contract. Add a regression test for behavior changes.
|
||||
- Older phase/milestone labels under `docs/GDD.md`, `docs/implementation-plan.md`, `docs/plan-0.1.6.md`, and `docs/plan-0.1.7.md` are historical. Current resumable work is tracked in `docs/plan-1.3.md` and `docs/resume.md`.
|
||||
|
||||
+7
-4
@@ -1554,15 +1554,12 @@
|
||||
"option.bottom_panel": "Ereignislog / Telemetrie",
|
||||
"option.bottom_panel.ticker": "Statuszeile (F11 öffnet das Log)",
|
||||
"option.bottom_panel.docked": "feste Leiste",
|
||||
"option.operator_assist": "Bedienerassistenz",
|
||||
"option.page": "Seite {page}/{pages}",
|
||||
"option.local_side": "uConsole spielt",
|
||||
"option.local_side.frigate": "Fregatte (Standard)",
|
||||
"option.local_side.uboot": "Feindliches U-Boot",
|
||||
"option.local_side.help": "Standard ist die Fregatte. Mit dem feindlichen U-Boot führt der uConsole das gegnerische U-Boot (U-Boot-Führung und U-Boot-Sonar); die Fregatte wird dann aus den Browsern über Remote Crew (F9) besetzt oder fährt mit Autocrew. Die Wahl gilt ab der nächsten Mission, nur für diesen Programmstart und wird nie gespeichert: Jeder Start beginnt mit der Fregatte.",
|
||||
"option.local_side.locked": "Nur im Hauptmenü änderbar, nicht während einer Mission.",
|
||||
"option.operator_assist.off": "aus (Rohdaten, manuelle Analyse)",
|
||||
"option.operator_assist.training": "Training (automatische Hinweise)",
|
||||
"option.live_traffic": "Echtzeit-Verkehr (AIS / ADS-B)...",
|
||||
"live_traffic.title": "ECHTZEIT-VERKEHR",
|
||||
"live_traffic.online": "Internetverbindung: verfügbar",
|
||||
@@ -1997,6 +1994,12 @@
|
||||
"menu.fixed_chart": "FESTE REFERENZKARTE",
|
||||
"menu.real_fixed_hint": "Fester realer Sektor {sector} | Bild auf/ab: Sektor wählen",
|
||||
"level.custom": "Individuell",
|
||||
"level.beginner": "Einsteiger",
|
||||
"level.standard": "Standard",
|
||||
"level.realistic": "Realistisch",
|
||||
"level.display": "{level} (Punkte {factor} %)",
|
||||
"option.level": "Realismus: {level} (Punkte {factor} %)",
|
||||
"option.level_next": "Realismus: {level} (ab der nächsten Mission)",
|
||||
"difficulty.quiet_mult": "U-Boot-Tarnung",
|
||||
"difficulty.repair_mult": "Reparaturrate",
|
||||
"difficulty.torpedo_count": "Torpedo-Anzahl",
|
||||
@@ -3357,7 +3360,7 @@
|
||||
"menu.loss_value": "Verlust: {loss}",
|
||||
"end.result": "{result} - {reason}",
|
||||
"end.score_value": "Punkte: {score}",
|
||||
"end.mission_level": "Mission: {mission} | Schwierigkeit: {level}",
|
||||
"end.mission_level": "Mission: {mission} | Realismus: {level}",
|
||||
"end.time_remaining": "Zeit: {remaining} übrig",
|
||||
"mission.objective.asm": " | {count}x ASM!",
|
||||
"mission.objective.warship": " | {count}x feindliches Oberflächenschiff!",
|
||||
|
||||
+7
-4
@@ -1554,15 +1554,12 @@
|
||||
"option.bottom_panel": "Event log / telemetry",
|
||||
"option.bottom_panel.ticker": "status ticker (F11 opens the log)",
|
||||
"option.bottom_panel.docked": "docked band",
|
||||
"option.operator_assist": "Operator assistance",
|
||||
"option.page": "Page {page}/{pages}",
|
||||
"option.local_side": "uConsole plays",
|
||||
"option.local_side.frigate": "Frigate (standard)",
|
||||
"option.local_side.uboot": "Hostile submarine",
|
||||
"option.local_side.help": "Frigate is the standard. With the hostile submarine, the uConsole commands the enemy submarine (submarine command and submarine sonar); the frigate is then crewed from the browsers through Remote Crew (F9) or runs on autocrew. The choice applies from the next mission, lasts for this launch only and is never saved: every launch starts with the frigate.",
|
||||
"option.local_side.locked": "Can only be changed in the main menu, not during a mission.",
|
||||
"option.operator_assist.off": "off (raw data, manual analysis)",
|
||||
"option.operator_assist.training": "training (automatic hints)",
|
||||
"option.live_traffic": "Real-world traffic (AIS / ADS-B)...",
|
||||
"live_traffic.title": "REAL-WORLD TRAFFIC",
|
||||
"live_traffic.online": "Internet connection: available",
|
||||
@@ -1997,6 +1994,12 @@
|
||||
"menu.fixed_chart": "FIXED REFERENCE CHART",
|
||||
"menu.real_fixed_hint": "Fixed real sector {sector} | Page Up/Down: choose sector",
|
||||
"level.custom": "Custom",
|
||||
"level.beginner": "Beginner",
|
||||
"level.standard": "Standard",
|
||||
"level.realistic": "Realistic",
|
||||
"level.display": "{level} (score {factor} %)",
|
||||
"option.level": "Realism: {level} (score {factor} %)",
|
||||
"option.level_next": "Realism: {level} (from the next mission)",
|
||||
"difficulty.quiet_mult": "Submarine stealth",
|
||||
"difficulty.repair_mult": "Repair rate",
|
||||
"difficulty.torpedo_count": "Torpedo count",
|
||||
@@ -3357,7 +3360,7 @@
|
||||
"menu.loss_value": "Loss: {loss}",
|
||||
"end.result": "{result} - {reason}",
|
||||
"end.score_value": "Score: {score}",
|
||||
"end.mission_level": "Mission: {mission} | Difficulty: {level}",
|
||||
"end.mission_level": "Mission: {mission} | Realism: {level}",
|
||||
"end.time_remaining": "Time: {remaining} remaining",
|
||||
"mission.objective.asm": " | {count}x ASM!",
|
||||
"mission.objective.warship": " | {count}x hostile surface ship!",
|
||||
|
||||
@@ -87,7 +87,7 @@ Die Statuszeile unten zeigt das neueste Ereignis und die wichtigste Telemetrie;
|
||||
- **Fehler melden** (Hauptmenü): schreibt `~/.u-jagd/bug-report.txt` (Version, Plattform und die neuesten Zeilen aus `~/.u-jagd/crash.log`, Ihr Benutzername aus Pfaden entfernt) und zeigt einen QR-Code, der am Handy ein neues GitHub-Issue mit Version und Plattform öffnet; dort die Datei anhängen. `Enter` öffnet das Issue mit Log in einem Browser, falls das Gerät einen hat, `Esc` geht zurück. Nach einem abgestürzten Start wählt das Hauptmenü diesen Eintrag vor und weist darauf hin. Gesendet wird erst, wenn Sie das Issue mit Ihrem eigenen GitHub-Konto abschicken. Der Windows-Starter („Fehler melden“) und das Einstellungsmenü im Browser haben denselben Link.
|
||||
- `S` / `L`: Speichern / Laden (Plätze 1-5). Spielstände sind exakt und deterministisch: ein geladenes Spiel läuft identisch weiter.
|
||||
- **Autosave:** Eine laufende Mission wird alle 5 Minuten und beim Beenden oder Verlassen ins Hauptmenü nach `~/.u-jagd/autosave.json` gespeichert, neben den fünf Plätzen. Das Hauptmenü beginnt dann mit **Einsatz fortsetzen**, das sie exakt weiterführt; nach einem Absturz ist es der letzte 5-Minuten-Stand. Eine beendete Mission (Sieg, Niederlage oder Schiff gesunken) und jede neue Mission löschen den Autosave. Der Web-Host (`--web-host`) speichert nicht automatisch.
|
||||
- `F10`: Optionen - Sprache, Vollbild, Audio, große Schrift, Tooltips, Bildrate (30 oder 60 FPS; 30 spart Rechenleistung auf der uConsole und ist voreingestellt), Ereignislog/Telemetrie als Statuszeile (Standard, mehr Platz für die Station) oder feste Leiste, Bedienerassistenz aus (Standard: Rohdaten und manuelle Analyse) oder Training (automatische Linienbeschriftung, Blattfrequenz- und Katalog-/Senderkandidaten). Seite 2 (`Bild ab`/`Tab`): welche Seite der uConsole spielt, Fregatte (Standard) oder feindliches U-Boot; nur im Hauptmenü, nie gespeichert. Ein neues Spiel fragt ohnehin zuerst danach. Auf Seite 2 liegen auch die **geglätteten Kartenlinien** (standardmäßig aus; glättet Peilstriche, Küste und Plot, kostet auf der uConsole etwas Rechenzeit). Dazu die **gesprochenen Crew-Meldungen** (standardmäßig aus): die Crew meldet Torpedo im Wasser, neuen Kontakt mit Peilung, Sinkgeräusche, Torpedo los, Treffer, Gefechtsstationen, Seefernaufklärer auf Station und das Missionsende laut, Peilungen Ziffer für Ziffer. Die uConsole spricht über ein installiertes `espeak-ng` (`sudo apt install espeak-ng`) und bleibt ohne es stumm; Remote-Crew-Browser haben einen eigenen Schalter unter Einstellungen (Sprachausgabe des Browsers, in dessen Sprache). Spielt die uConsole das U-Boot, meldet stattdessen dessen Crew (siehe Kapitel Referenz).
|
||||
- `F10`: Optionen - Sprache, Vollbild, Audio, große Schrift, Tooltips, Bildrate (30 oder 60 FPS; 30 spart Rechenleistung auf der uConsole und ist voreingestellt), Ereignislog/Telemetrie als Statuszeile (Standard, mehr Platz für die Station) oder feste Leiste, und die **Realismusstufe** der nächsten Mission: **Einsteiger** (Bedienerassistenz an: automatische Linienbeschriftung, Blattfrequenz- und Katalog-/Senderkandidaten; der Computergegner greift zögerlicher an, wartet auf eine bessere Schusslösung und klassifiziert und startet als Fregatte seinen Hubschrauber 1,5-mal langsamer; Punkte 75 %), **Standard** (voreingestellt: Rohdaten und manuelle Analyse, der kalibrierte Gegner; Punkte 100 %) oder **Realistisch** (keine Assistenz; der Gegner greift entschlossener an, schießt auf eine gröbere Lösung und reagiert als Fregatte 30 % schneller; Punkte 125 %). Die Stufe stimmt nur den Computergegner ab, nie einen Menschen auf der anderen Seite, und eine laufende Mission behält die Stufe, mit der sie begann (die Zeile sagt dann "ab der nächsten Mission"). Das Endpanel zeigt die Stufe mit ihrem Punktefaktor; Spielstände behalten sie. Seite 2 (`Bild ab`/`Tab`): welche Seite der uConsole spielt, Fregatte (Standard) oder feindliches U-Boot; nur im Hauptmenü, nie gespeichert. Ein neues Spiel fragt ohnehin zuerst danach. Auf Seite 2 liegen auch die **geglätteten Kartenlinien** (standardmäßig aus; glättet Peilstriche, Küste und Plot, kostet auf der uConsole etwas Rechenzeit). Dazu die **gesprochenen Crew-Meldungen** (standardmäßig aus): die Crew meldet Torpedo im Wasser, neuen Kontakt mit Peilung, Sinkgeräusche, Torpedo los, Treffer, Gefechtsstationen, Seefernaufklärer auf Station und das Missionsende laut, Peilungen Ziffer für Ziffer. Die uConsole spricht über ein installiertes `espeak-ng` (`sudo apt install espeak-ng`) und bleibt ohne es stumm; Remote-Crew-Browser haben einen eigenen Schalter unter Einstellungen (Sprachausgabe des Browsers, in dessen Sprache). Spielt die uConsole das U-Boot, meldet stattdessen dessen Crew (siehe Kapitel Referenz).
|
||||
- `F9`: Commander / Remote Crew - Browser im LAN können Stationen übernehmen. Eine freie Station wird sofort mit allen ihren Rechten übernommen (auch Direktfeuer und Sonar-Liveaudio, wo die Station sie hat); eine Station, die ein Crewmitglied hält, wird angefragt, und der Host kann sie übergeben. Der Host kann jederzeit eine Station oder einzelne Rechte entziehen und bis zu zwei Browser zu reinen Beobachtern machen (Roster-Taste `O`): sie sehen jede Station beider Einheiten, ohne sie zu halten, können nichts befehlen und erhalten das SimLog mit Zeitstrahl zur Nachbesprechung und JSON-Export. Auf einem Windows-PC startet das Programm `U-Jagd-Windows.exe` das Spiel mit bereits eingeschalteter Remote Crew (Besatzungs- oder Solomodus) und zeigt Browser-Adresse, Beitrittscode und QR-Code; sein Feld Sprache stellt Starter, Spiel und Crew-Seiten zwischen English und Deutsch um und wird in den Einstellungen gespeichert. `--remote-crew` macht dasselbe über die Kommandozeile (siehe README). Die Crew-Seiten öffnen in der gespeicherten Sprache des Hosts (`F10`-Optionen auf der uConsole); der Knopf English/Deutsch in der Statusleiste des Browsers stellt nur diesen Browser um. Die Crew-Seite ist für Chrome oder Chromium (auch Edge) auf einem Desktop-PC gebaut; ein anderer Browser zeigt über dem Kopplungscode einen Hinweis, und eine Seite, die dort nicht starten kann, sagt das, statt endlos zu laden. Nach einem Update des Hosts lädt sich eine offene Browserseite einmal selbst neu und läuft so immer mit dem passenden Web-Client.
|
||||
|
||||
## Handy-Ausguck und Sehrohr {#qs-phone}
|
||||
|
||||
@@ -87,7 +87,7 @@ The bottom status ticker shows the newest event and key telemetry; `F11` opens t
|
||||
- **Report a bug** (main menu): writes `~/.u-jagd/bug-report.txt` (version, platform and the newest lines of `~/.u-jagd/crash.log`, with your user name removed from paths) and shows a QR code that opens a new GitHub issue on a phone with version and platform filled in; attach the file there. `Enter` opens the issue with the log in a browser if the device has one, `Esc` goes back. After a crashed start the main menu selects this entry and says so. Nothing is sent until you submit the issue with your own GitHub account. The Windows starter ("Report a bug") and the browser settings menu have the same link.
|
||||
- `S` / `L`: save / load (slots 1-5). Saves are exact and deterministic: a loaded game continues identically.
|
||||
- **Autosave:** a running mission is saved every 5 minutes and when you quit or leave it for the main menu, to `~/.u-jagd/autosave.json` beside the five slots. The main menu then starts with **Continue mission**, which resumes it exactly; after a crash it holds the last 5-minute save. A mission that ends (won, lost or ship sunk) and any new mission delete the autosave. The web host (`--web-host`) does not autosave.
|
||||
- `F10`: options - language, fullscreen, audio, large text, tooltips, frame rate (30 or 60 FPS; 30 saves CPU on the uConsole and is the default), event log / telemetry as status ticker (default, more room for the station) or docked band, operator assistance off (default: raw data and manual analysis) or training (automatic line labels, blade-rate and catalogue/emitter candidates). Page 2 (`PgDn`/`Tab`): which side the uConsole plays, frigate (default) or hostile submarine; only in the main menu, never saved. A new game asks for it first anyway. Page 2 also holds **anti-aliased chart lines** (off by default; smooths bearing lines, coast and plot at some CPU cost on the uConsole). And **spoken crew reports** (off by default): the crew says torpedo in the water, new contact with bearing, breaking-up noises, torpedo away, hit, action stations, patrol aircraft on station and the mission result aloud, bearings digit by digit. The uConsole speaks through an installed `espeak-ng` (`sudo apt install espeak-ng`) and stays silent without it; Remote Crew browsers have their own switch under Settings (the browser's speech synthesis, in the browser's language). With the uConsole on the submarine the submarine's crew reports instead (see the reference chapter).
|
||||
- `F10`: options - language, fullscreen, audio, large text, tooltips, frame rate (30 or 60 FPS; 30 saves CPU on the uConsole and is the default), event log / telemetry as status ticker (default, more room for the station) or docked band, and the **realism level** for the next mission: **Beginner** (operator assistance on: automatic line labels, blade-rate and catalogue/emitter candidates; the computer opponent attacks less eagerly, waits for a better firing solution and, as the frigate, classifies and launches its helicopter 1.5 times slower; score 75 %), **Standard** (default: raw data and manual analysis, the calibrated opponent; score 100 %) or **Realistic** (no assistance; the opponent attacks more eagerly, fires on a rougher solution and reacts 30 % faster as the frigate; score 125 %). The level only tunes the computer opponent, never a human on the other side, and a running mission keeps the level it started with (the row then says "from the next mission"). The end panel shows the level with its score factor; saves keep it. Page 2 (`PgDn`/`Tab`): which side the uConsole plays, frigate (default) or hostile submarine; only in the main menu, never saved. A new game asks for it first anyway. Page 2 also holds **anti-aliased chart lines** (off by default; smooths bearing lines, coast and plot at some CPU cost on the uConsole). And **spoken crew reports** (off by default): the crew says torpedo in the water, new contact with bearing, breaking-up noises, torpedo away, hit, action stations, patrol aircraft on station and the mission result aloud, bearings digit by digit. The uConsole speaks through an installed `espeak-ng` (`sudo apt install espeak-ng`) and stays silent without it; Remote Crew browsers have their own switch under Settings (the browser's speech synthesis, in the browser's language). With the uConsole on the submarine the submarine's crew reports instead (see the reference chapter).
|
||||
- `F9`: Commander / Remote Crew - lets browser clients on the LAN take stations. A free station is taken at once with all of its rights (including direct fire and live sonar audio where the station has them); a station a crewmate holds is requested, and the host can hand it over. The host can revoke a station or single rights at any time, and can make up to two browsers read-only observers (roster key `O`): they watch any station of either unit without holding it, cannot command, and get the SimLog with a debrief timeline and JSON export. On a Windows PC the program `U-Jagd-Windows.exe` starts the game with Remote Crew already on (crew or solo mode) and shows the browser address, join code and QR code; its Language box switches the starter, the game and the crew pages between English and Deutsch and is saved in the settings. `--remote-crew` does the same from the command line (see the README). The crew pages open in the host's saved language (`F10` options on the uConsole); the English/Deutsch button in the browser's status bar switches that browser alone. The crew page is built for Chrome or Chromium (also Edge) on a desktop PC; another browser shows a hint above the pairing code, and a page that cannot start there says so instead of loading forever. After a host update an open browser page reloads itself once, so it always runs the web client that matches the host.
|
||||
|
||||
## Phone lookout and periscope {#qs-phone}
|
||||
|
||||
@@ -44,7 +44,7 @@ Die x-Achse ist die Frequenz (0-300 Hz), die Zeit läuft nach unten. Die Klassen
|
||||
- Der Spektrumstreifen über dem Wasserfall schreibt die Frequenz über jede deutliche Linie (zwischen den Klassen interpoliert; mit `Leertaste` die gehaltene Hüllkurve). Wo sich Werte überdecken würden, behält die stärkere Linie ihre Beschriftung. Der Remote-Crew-Browser beschriftet seine Spektren genauso.
|
||||
- `F` wählt das Analyseband: FULL 0-300, LOW 4-80, SHAFT 8-55, MID 20-120 Hz. `Strg+Z` / `Strg+X` setzen die untere / obere Bandkante auf den Cursor für jeden Band-, Tief- oder Hochpass; `Umschalt+N` legt einen zusätzlichen Notch auf die Cursorfrequenz.
|
||||
- `Q` wählt die Integrationszeit: 2 s (die FFT des Empfängers), 8, 16 oder 64 s. Längere Integration mittelt aufeinanderfolgende Spektren, sodass ein schwacher stehender Ton aus dem Rauschen tritt; eine wandernde Linie verschmiert dabei. `Umschalt+Q` öffnet den Nonius: 20 Hz um den Cursor in der nativen 0,5-Hz-Auflösung.
|
||||
- Die Detailspalte liest den Pegel am Cursor. Automatisch beschriftet der Streifen Linien nur mit Bedienerassistenz Training (`F10`).
|
||||
- Die Detailspalte liest den Pegel am Cursor. Automatisch beschriftet der Streifen Linien nur auf der Realismusstufe Einsteiger (`F10`).
|
||||
|
||||
### DEMON {#sonar-demon}
|
||||
|
||||
@@ -60,11 +60,11 @@ DEMON demoduliert die Hüllkurve des Breitbandrauschens im Horchstrahl. Schraube
|
||||
Welle Blatt 2. Harmonische
|
||||
```
|
||||
|
||||
Die Anzeige zeigt gemessene Modulation, keine Identität. Nach einer Peilungsänderung einige Sekunden horchen, bevor Sie urteilen. Blätter selbst zählen: den Cursor (`Z`/`X`, 0,5 Hz) auf die Wellenlinie setzen und `K` drücken, dann auf die Blattlinie und erneut `K`; die Spalte zeigt Blätter = Blattfrequenz / Wellenfrequenz (mit der Abweichung von einer ganzen Zahl) und die Wellendrehzahl. Ein drittes `K` löscht beide Marken. Das Ergebnis mit den Referenzen im Kontaktanalysator (`F8`) vergleichen. Mit Bedienerassistenz Training (`F10`) beschriftet das Sonar zusätzlich Modulationslinien, schlägt Drehzahlen für 3-7 Blätter vor und rankt Katalogkandidaten.
|
||||
Die Anzeige zeigt gemessene Modulation, keine Identität. Nach einer Peilungsänderung einige Sekunden horchen, bevor Sie urteilen. Blätter selbst zählen: den Cursor (`Z`/`X`, 0,5 Hz) auf die Wellenlinie setzen und `K` drücken, dann auf die Blattlinie und erneut `K`; die Spalte zeigt Blätter = Blattfrequenz / Wellenfrequenz (mit der Abweichung von einer ganzen Zahl) und die Wellendrehzahl. Ein drittes `K` löscht beide Marken. Das Ergebnis mit den Referenzen im Kontaktanalysator (`F8`) vergleichen. Auf der Realismusstufe Einsteiger (`F10`) beschriftet das Sonar zusätzlich Modulationslinien, schlägt Drehzahlen für 3-7 Blätter vor und rankt Katalogkandidaten.
|
||||
|
||||
### TMA, Umwelt und Aktiv {#sonar-tma-env}
|
||||
|
||||
- **TMA** machen Sie selbst. Die Seite zeichnet die Peilungen des gewählten Kontakts über der Zeit. Stellen Sie eine Hypothese auf: `Z`/`X` Kurs (`Umschalt`: 1 Grad), `Strg+Z`/`Strg+X` Fahrt, `Q`/`Umschalt+Q` Entfernung auf der neuesten Peilung (`Strg`: 0,2 sm). Die bernsteinfarbene Kurve zeigt die Peilungen, die diese Hypothese vorhersagt, die Punkte am Fuß die Residuen (gemessen minus vorhergesagt). Gute Hypothesen lassen die Residuen um null streuen; ein falscher Kurs, eine falsche Fahrt oder Entfernung hinterlässt einen Trend. Die Spalte zeigt RMS der Residuen, den systematischen Trend nach Mittelung, die Passung und die Beobachtbarkeit. Die Entfernung ist erst nach einer eigenen Kursänderung beobachtbar (mindestens 6 Grad, besser 30-60); ohne sie verweigert `K`. `K` übernimmt die Hypothese als TMA-Fix des Kontakts; er wird auf Kurs und Fahrt mitgekoppelt und veraltet nach 120 s, also verfeinern und erneut übernehmen, wenn Peilungen hinzukommen. Verrauschte Peilungen ergeben auch bei guter Passung eine große Entfernungsunsicherheit. Tiefe schätzt TMA nicht. Mit Bedienerassistenz Training (`F10`) wird ein automatischer Solver-Vorschlag (er braucht mindestens 4 Peilungen über 180 s) als dünne Linie gezeichnet, und `Umschalt+K` kopiert ihn in die Hypothese. Sonobojen-Peilungen gehen mit der Boje als Beobachter in den Track ein. `Umschalt+T` wechselt die TMA-Methode: HYPOTHESE (oben), EKELUND (die Entfernung aus den Peilraten zweier eigener Schläge um eine Kursänderung von mindestens 30°, je 90 s; `Umschalt+K` übernimmt sie in die Hypothese, `K` nimmt dann wie üblich an) oder DOT-STACK (Residuenzeilen bei 0,6-, 1,0- und 1,6-facher Hypothesenentfernung: die flache Zeile ist die Entfernung, die die Peilungen stützen).
|
||||
- **TMA** machen Sie selbst. Die Seite zeichnet die Peilungen des gewählten Kontakts über der Zeit. Stellen Sie eine Hypothese auf: `Z`/`X` Kurs (`Umschalt`: 1 Grad), `Strg+Z`/`Strg+X` Fahrt, `Q`/`Umschalt+Q` Entfernung auf der neuesten Peilung (`Strg`: 0,2 sm). Die bernsteinfarbene Kurve zeigt die Peilungen, die diese Hypothese vorhersagt, die Punkte am Fuß die Residuen (gemessen minus vorhergesagt). Gute Hypothesen lassen die Residuen um null streuen; ein falscher Kurs, eine falsche Fahrt oder Entfernung hinterlässt einen Trend. Die Spalte zeigt RMS der Residuen, den systematischen Trend nach Mittelung, die Passung und die Beobachtbarkeit. Die Entfernung ist erst nach einer eigenen Kursänderung beobachtbar (mindestens 6 Grad, besser 30-60); ohne sie verweigert `K`. `K` übernimmt die Hypothese als TMA-Fix des Kontakts; er wird auf Kurs und Fahrt mitgekoppelt und veraltet nach 120 s, also verfeinern und erneut übernehmen, wenn Peilungen hinzukommen. Verrauschte Peilungen ergeben auch bei guter Passung eine große Entfernungsunsicherheit. Tiefe schätzt TMA nicht. Auf der Realismusstufe Einsteiger (`F10`) wird ein automatischer Solver-Vorschlag (er braucht mindestens 4 Peilungen über 180 s) als dünne Linie gezeichnet, und `Umschalt+K` kopiert ihn in die Hypothese. Sonobojen-Peilungen gehen mit der Boje als Beobachter in den Track ein. `Umschalt+T` wechselt die TMA-Methode: HYPOTHESE (oben), EKELUND (die Entfernung aus den Peilraten zweier eigener Schläge um eine Kursänderung von mindestens 30°, je 90 s; `Umschalt+K` übernimmt sie in die Hypothese, `K` nimmt dann wie üblich an) oder DOT-STACK (Residuenzeilen bei 0,6-, 1,0- und 1,6-facher Hypothesenentfernung: die flache Zeile ist die Entfernung, die die Peilungen stützen).
|
||||
- **UMWELT / FUSION** zeigt den Bathythermographen (`E`, 60 s Abklingzeit): gemessene Schichttiefe, Schallgeschwindigkeitsprofil und Konvergenzzonen, dazu den Vergleich HMS/TAS. Peilungen innerhalb 5 Grad bestätigen sich; ab 9 Grad Abweichung wird ein möglicher Geisterkontakt markiert. Die Schicht ist nicht fest: Nachmittagssonne macht sie flacher (etwa 8 m), starker Wind mischt sie über Stunden tiefer, und interne Wellen verschieben sie um einige Meter. Den BT nach einigen Stunden oder einem Wetterwechsel wiederholen. Das gemessene Profil ist die echte temperaturabhängige Schallgeschwindigkeit (Mackenzie-Gleichung) und fällt deshalb unterhalb der Schicht ab. Mit der Maus über dem Profil lesen Sie die genaue Tiefe, die dortige Schallgeschwindigkeit und ob die Tiefe über oder unter der Schicht liegt (uConsole und Web). Im Web-Client beschriftet die Grafik zusätzlich Schicht, Meeresgrund und das Schallgeschwindigkeitsminimum. Die Konvergenzzonen darin stammen aus dem gemessenen Profil selbst: aus der Strahlverfolgung dieses Profils über dem kartierten Bodentyp in der Tiefe des Arrays, sie ändern sich also mit Schicht, Tiefe und Boden (keine im Flachwasser).
|
||||
- **ACTIVE** listet die Echos der letzten 120 s: Peilung, Entfernung und Tiefe (+/-12 m). Ein Ping-Fix veraltet nach 120 s. `W` wählt den Puls: **CW** (1-s-Ton) misst die Entfernung grob (etwa 0,1-0,3 sm), trennt aber über den Doppler ein bewegtes Ziel vom Nachhall des Meeresbodens; **LFM** (100-Hz-Sweep) misst die Entfernung auf wenige Meter und gewinnt 20 dB gegen Rauschen, ein langsames oder stehendes Ziel bleibt aber im Nachhall. Die Echostärke hängt vom Aspekt (breitseits etwa 15 dB stärker als von vorn) und der Größe des Ziels ab. Felsgrund hallt viel stärker nach als Schlick; kartierte Wracks liefern echte Echos ohne zugehörigen Kontakt ("nicht zugeordnetes Echo").
|
||||
- **Das Echo hören:** Jede Rückkehr ist hörbar, sobald sie eintrifft, nach ihrer echten Laufzeit hin und zurück (etwa 2,5 s je Seemeile Entfernung), für das Schiffssonar ebenso wie für das Tauchsonar des Helikopters. Ein CW-Echo ist ein weicher Ton auf der Trägerfrequenz, ein LFM-Echo ein kurzer Sweep; maßgeblich ist der Puls, mit dem gepingt wurde. Ein starkes Echo hebt sich deutlich ab, ein schwaches steigt kaum aus dem Nachhallrauschen. Im Remote-Crew-Browser klingt das Echo über den allgemeinen Ton (laut oder leise). Das aktive Ping eines U-Boots kommt umgekehrt nach seiner einfachen Laufzeit an (etwa 1,2 s je Seemeile): Erst dann gibt die Fregatte ihren tiefen Warnton, spielt das Ping selbst und meldet es im Log mit der nach Gehör gemessenen Peilung (ganze Grad, etwa ±2° ungenau); eine Entfernung liefert ein fremdes Ping nie. **Richtungshören:** Mit Stereoton (Kopfhörer) kommen Echos, Detonationen und das Ping eines U-Boots aus der Peilung, aus der sie gehört wurden: links für Backbord, rechts für Steuerbord vom Bug des Schiffs aus, mittig recht voraus und achteraus (voraus und achteraus klingen gleich). Das eigene Ping, Starts und Geschützfeuer bleiben mittig. Der uConsole und der Remote-Crew-Browser setzen sie gleich.
|
||||
|
||||
@@ -43,7 +43,7 @@ The x axis is frequency (0-300 Hz), time runs downwards. Bins are 1 Hz below 40
|
||||
- The spectrum strip above the waterfall prints the frequency over every prominent line (interpolated between bins; with `Space` the held envelope). Where values would overlap, the stronger line keeps its label. The Remote Crew browser labels its spectra the same way.
|
||||
- `F` selects the analysed band: FULL 0-300, LOW 4-80, SHAFT 8-55, MID 20-120 Hz. `Ctrl+Z` / `Ctrl+X` set the low / high band edge at the cursor for any band-, low- or high-pass; `Shift+N` puts an extra notch on the cursor frequency.
|
||||
- `Q` selects the integration time: 2 s (the receiver's own FFT), 8, 16 or 64 s. Longer integration averages successive spectra so a weak steady tonal rises out of the noise, but a moving line smears. `Shift+Q` opens the vernier: 20 Hz around the cursor at the native 0.5 Hz resolution.
|
||||
- The detail rail reads the level at the cursor. The strip labels lines automatically only with operator assistance set to training (`F10`).
|
||||
- The detail rail reads the level at the cursor. The strip labels lines automatically only at the Beginner realism level (`F10`).
|
||||
|
||||
### DEMON {#sonar-demon}
|
||||
|
||||
@@ -59,11 +59,11 @@ DEMON demodulates the broadband noise envelope of the listening beam. Propeller
|
||||
shaft blade 2nd harmonic
|
||||
```
|
||||
|
||||
The display shows measured modulation, not identity. After changing the bearing listen for at least a few seconds before judging. Count blades yourself: move the cursor (`Z`/`X`, 0.5 Hz) onto the shaft line and press `K`, then onto the blade line and press `K` again; the rail shows blades = blade rate / shaft rate (with the deviation from a whole number) and the shaft RPM. A third `K` clears both marks. Compare the result with the references in the contact analyser (`F8`). With operator assistance set to training (`F10`) the sonar also labels modulation lines, proposes RPM for 3-7 blades and ranks catalogue candidates.
|
||||
The display shows measured modulation, not identity. After changing the bearing listen for at least a few seconds before judging. Count blades yourself: move the cursor (`Z`/`X`, 0.5 Hz) onto the shaft line and press `K`, then onto the blade line and press `K` again; the rail shows blades = blade rate / shaft rate (with the deviation from a whole number) and the shaft RPM. A third `K` clears both marks. Compare the result with the references in the contact analyser (`F8`). At the Beginner realism level (`F10`) the sonar also labels modulation lines, proposes RPM for 3-7 blades and ranks catalogue candidates.
|
||||
|
||||
### TMA, environment and active {#sonar-tma-env}
|
||||
|
||||
- **TMA** is yours. The page plots the bearings of the selected contact over time. Build a hypothesis: `Z`/`X` course (`Shift`: 1 degree), `Ctrl+Z`/`Ctrl+X` speed, `Q`/`Shift+Q` range on the newest bearing (`Ctrl`: 0.2 NM). The amber curve shows the bearings that hypothesis predicts, the dots at the foot the residuals (measured minus predicted). Good hypotheses leave residuals scattered around zero; a wrong course, speed or range leaves a trend. The rail shows the residual RMS, the systematic trend after averaging, the fit and the observability. Range is only observable after an own course change (at least 6 degrees, better 30-60): without one, `K` refuses. `K` accepts the hypothesis as the contact's TMA fix; it is dead-reckoned on its course and speed and ages out after 120 s, so refine and re-accept as bearings come in. Noisy bearings give a large range uncertainty even when the fit is good. TMA does not estimate depth. With operator assistance set to training (`F10`) an automatic solver proposal (it needs at least 4 bearings over 180 s) is drawn as a thin line and `Shift+K` copies it into the hypothesis. Sonobuoy bearings enter the track with the buoy as observer. `Shift+T` switches the TMA method: HYPOTHESIS (above), EKELUND (the range from the bearing rates of two own legs about one course change of 30 degrees or more, 90 s each; `Shift+K` copies it into the hypothesis, `K` then accepts as usual) or DOT STACK (residual rows at 0.6, 1.0 and 1.6 times the hypothesis range: the flat row is the range the bearings support).
|
||||
- **TMA** is yours. The page plots the bearings of the selected contact over time. Build a hypothesis: `Z`/`X` course (`Shift`: 1 degree), `Ctrl+Z`/`Ctrl+X` speed, `Q`/`Shift+Q` range on the newest bearing (`Ctrl`: 0.2 NM). The amber curve shows the bearings that hypothesis predicts, the dots at the foot the residuals (measured minus predicted). Good hypotheses leave residuals scattered around zero; a wrong course, speed or range leaves a trend. The rail shows the residual RMS, the systematic trend after averaging, the fit and the observability. Range is only observable after an own course change (at least 6 degrees, better 30-60): without one, `K` refuses. `K` accepts the hypothesis as the contact's TMA fix; it is dead-reckoned on its course and speed and ages out after 120 s, so refine and re-accept as bearings come in. Noisy bearings give a large range uncertainty even when the fit is good. TMA does not estimate depth. At the Beginner realism level (`F10`) an automatic solver proposal (it needs at least 4 bearings over 180 s) is drawn as a thin line and `Shift+K` copies it into the hypothesis. Sonobuoy bearings enter the track with the buoy as observer. `Shift+T` switches the TMA method: HYPOTHESIS (above), EKELUND (the range from the bearing rates of two own legs about one course change of 30 degrees or more, 90 s each; `Shift+K` copies it into the hypothesis, `K` then accepts as usual) or DOT STACK (residual rows at 0.6, 1.0 and 1.6 times the hypothesis range: the flat row is the range the bearings support).
|
||||
- **UMWELT / FUSION** shows the bathythermograph (`E`, 60 s cooldown): measured layer depth, sound-speed profile and convergence-zone bands, plus the HMS/TAS comparison. Bearings within 5 degrees confirm each other; 9 degrees or more apart are flagged as a possible ghost contact. The layer is not fixed: afternoon sun makes it shallower (about 8 m), strong wind mixes it deeper over hours, and internal waves move it a few metres. Repeat the BT after a few hours or a weather change. The measured profile is the real temperature-driven sound speed (Mackenzie equation), so it drops below the layer. Point the mouse at the profile to read the exact depth, the sound speed there and whether that depth lies above or below the layer (uConsole and web). In the web client the plot also labels the layer, the seabed and the sound-speed minimum.
|
||||
- **ACTIVE** lists echoes of the last 120 s: bearing, range and depth (+/-12 m). A ping fix ages out after 120 s. `W` selects the pulse: **CW** (1 s tone) gives coarse range (about 0.1-0.3 NM) but its Doppler separates a moving target from seabed reverberation; **LFM** (100 Hz sweep) measures range to a few metres and gains 20 dB against noise, but a slow or stationary target stays inside the reverberation. The echo strength depends on the target's aspect (broadside about 15 dB stronger than bow-on) and size. Rocky ground reverberates far more than mud; charted wrecks return real echoes that no contact owns ("unassociated echo").
|
||||
- **Hearing the echo:** every return is audible when it arrives, after its real two-way travel time (about 2.5 s per nautical mile of range), for the ship's sonar and the helicopter's dipping sonar alike. A CW echo is a soft tone on the carrier, an LFM echo a short sweep; the pulse is the one the ping was sent with. A strong echo stands out clearly, a faint one barely rises out of the reverberation hiss. In the Remote Crew browser the echo plays with the general sound (loud or faint). A submarine's active ping is heard the other way round, after its one-way travel time (about 1.2 s per nautical mile): only then does the frigate sound its low warning tone, play the ping itself and log it with the bearing measured by ear (whole degrees, about ±2° off); a ping never gives its range. **Directional hearing:** with stereo sound (headphones), echoes, detonations and a submarine's ping come from the bearing they were heard on: left for port, right for starboard of the ship's head, centred dead ahead and astern (ahead and astern sound the same). The ship's own ping, launches and gunfire stay centred. The uConsole and the Remote Crew browser place them alike.
|
||||
|
||||
@@ -22,7 +22,7 @@ Seite 1 listet die Erfassungen; Seite 2 zeigt die Belege für die gewählte Erfa
|
||||
|
||||
- Die Peilgenauigkeit beträgt etwa +/-3 Grad. Erfassungen sind Peilungen, keine Positionen.
|
||||
- Ein drehendes Suchradar trifft die ESM-Antenne einmal je Umlauf mit der Hauptkeule; seine Nebenkeulen sind nur aus der Nähe hörbar. Die Belegseite zeigt den Spitzenpegel, eine Entfernungsschätzung unter Annahme der Leistungsklasse des besten Kandidaten (ein falscher Kandidat ergibt eine falsche Entfernung) und die gemessene Antennenumlaufzeit.
|
||||
- Standardmäßig (Bedienerassistenz aus, `F10`) zeigt die Belegseite nur die gemessenen Parameter und eine Bibliotheksabfrage: jeder Sender, dessen veröffentlichter Frequenz- (und PRF-)Bereich die Messung enthält, nach Namen sortiert, ohne Bewertung. Radartyp, Bedrohung und Entfernungsschätzung beurteilen Sie dann selbst; `C` schaltet die Bibliothek in Namensreihenfolge durch. Mit Assistenz Training werden Kandidaten nach Frequenz, PRF und Modulation mit Bewertung gerankt und Radartyp, Bedrohung und Entfernungsschätzung ausgefüllt. Ein Gleichstand ist keine Identifizierung.
|
||||
- Standardmäßig (Realismusstufe Standard oder Realistisch, `F10`) zeigt die Belegseite nur die gemessenen Parameter und eine Bibliotheksabfrage: jeder Sender, dessen veröffentlichter Frequenz- (und PRF-)Bereich die Messung enthält, nach Namen sortiert, ohne Bewertung. Radartyp, Bedrohung und Entfernungsschätzung beurteilen Sie dann selbst; `C` schaltet die Bibliothek in Namensreihenfolge durch. Auf der Stufe Einsteiger werden Kandidaten nach Frequenz, PRF und Modulation mit Bewertung gerankt und Radartyp, Bedrohung und Entfernungsschätzung ausgefüllt. Ein Gleichstand ist keine Identifizierung.
|
||||
- Die Korrelation mit Radar- oder Sonartracks nutzt vereinbare Zeit, Peilung und beobachtete Position, nie verborgene Identität.
|
||||
- Die Senderbibliothek enthält den Suchkopf des Seezielflugkörpers (9,0-9,5 GHz, PRF 1,8-3,2 kHz, Puls-Doppler). Er sendet nur auf den letzten 18 sm und erst, wenn der Tiefflieger über dem Radarhorizont ist, und er passt ebenso gut zum Feuerleitradar eines Angriffsflugzeugs: Peilungsverlauf und Luftlage entscheiden.
|
||||
- ESM läuft aus der OPZ-Abteilung: eine zerstörte OPZ legt es lahm.
|
||||
|
||||
@@ -22,7 +22,7 @@ Page 1 lists intercepts; page 2 shows the evidence for the selected intercept (f
|
||||
|
||||
- Bearing accuracy is about +/-3 degrees. Intercepts are bearings, not positions.
|
||||
- A rotating search radar reaches the ESM antenna with its main beam once per revolution; its side lobes are heard only close in. The evidence page shows the peak signal level, a range estimate that assumes the power class of the best candidate (a wrong candidate gives a wrong range) and the measured antenna scan period.
|
||||
- By default (operator assistance off, `F10`) the evidence page shows only the measured parameters and a library lookup: every emitter whose published frequency (and PRF) range contains the measurement, in name order, without score. Radar type, threat and range estimate are then yours to judge; `C` cycles the library in name order. With assistance set to training, candidates are ranked by frequency, PRF and modulation with a score, and radar type, threat and range estimate are filled in. A tie is not an identification.
|
||||
- By default (realism level Standard or Realistic, `F10`) the evidence page shows only the measured parameters and a library lookup: every emitter whose published frequency (and PRF) range contains the measurement, in name order, without score. Radar type, threat and range estimate are then yours to judge; `C` cycles the library in name order. At the Beginner level, candidates are ranked by frequency, PRF and modulation with a score, and radar type, threat and range estimate are filled in. A tie is not an identification.
|
||||
- Correlation with radar or sonar tracks uses compatible time, bearing and observed position, never hidden identity.
|
||||
- The emitter library includes the anti-ship missile seeker (9.0-9.5 GHz, PRF 1.8-3.2 kHz, pulse-Doppler). It radiates only in the last 18 NM and only once the sea-skimmer is above the radar horizon, and it matches an attack aircraft's fire-control radar just as well: the bearing trend and the air picture decide.
|
||||
- ESM runs from the operations compartment: a destroyed operations room disables it.
|
||||
|
||||
@@ -133,7 +133,7 @@ Die Statuszeile unten zeigt das neueste Ereignis und die wichtigste Telemetrie;
|
||||
- **Fehler melden** (Hauptmenü): schreibt `~/.u-jagd/bug-report.txt` (Version, Plattform und die neuesten Zeilen aus `~/.u-jagd/crash.log`, Ihr Benutzername aus Pfaden entfernt) und zeigt einen QR-Code, der am Handy ein neues GitHub-Issue mit Version und Plattform öffnet; dort die Datei anhängen. `Enter` öffnet das Issue mit Log in einem Browser, falls das Gerät einen hat, `Esc` geht zurück. Nach einem abgestürzten Start wählt das Hauptmenü diesen Eintrag vor und weist darauf hin. Gesendet wird erst, wenn Sie das Issue mit Ihrem eigenen GitHub-Konto abschicken. Der Windows-Starter („Fehler melden“) und das Einstellungsmenü im Browser haben denselben Link.
|
||||
- `S` / `L`: Speichern / Laden (Plätze 1-5). Spielstände sind exakt und deterministisch: ein geladenes Spiel läuft identisch weiter.
|
||||
- **Autosave:** Eine laufende Mission wird alle 5 Minuten und beim Beenden oder Verlassen ins Hauptmenü nach `~/.u-jagd/autosave.json` gespeichert, neben den fünf Plätzen. Das Hauptmenü beginnt dann mit **Einsatz fortsetzen**, das sie exakt weiterführt; nach einem Absturz ist es der letzte 5-Minuten-Stand. Eine beendete Mission (Sieg, Niederlage oder Schiff gesunken) und jede neue Mission löschen den Autosave. Der Web-Host (`--web-host`) speichert nicht automatisch.
|
||||
- `F10`: Optionen - Sprache, Vollbild, Audio, große Schrift, Tooltips, Bildrate (30 oder 60 FPS; 30 spart Rechenleistung auf der uConsole und ist voreingestellt), Ereignislog/Telemetrie als Statuszeile (Standard, mehr Platz für die Station) oder feste Leiste, Bedienerassistenz aus (Standard: Rohdaten und manuelle Analyse) oder Training (automatische Linienbeschriftung, Blattfrequenz- und Katalog-/Senderkandidaten). Seite 2 (`Bild ab`/`Tab`): welche Seite der uConsole spielt, Fregatte (Standard) oder feindliches U-Boot; nur im Hauptmenü, nie gespeichert. Ein neues Spiel fragt ohnehin zuerst danach. Auf Seite 2 liegen auch die **geglätteten Kartenlinien** (standardmäßig aus; glättet Peilstriche, Küste und Plot, kostet auf der uConsole etwas Rechenzeit). Dazu die **gesprochenen Crew-Meldungen** (standardmäßig aus): die Crew meldet Torpedo im Wasser, neuen Kontakt mit Peilung, Sinkgeräusche, Torpedo los, Treffer, Gefechtsstationen, Seefernaufklärer auf Station und das Missionsende laut, Peilungen Ziffer für Ziffer. Die uConsole spricht über ein installiertes `espeak-ng` (`sudo apt install espeak-ng`) und bleibt ohne es stumm; Remote-Crew-Browser haben einen eigenen Schalter unter Einstellungen (Sprachausgabe des Browsers, in dessen Sprache). Spielt die uConsole das U-Boot, meldet stattdessen dessen Crew (siehe Kapitel Referenz).
|
||||
- `F10`: Optionen - Sprache, Vollbild, Audio, große Schrift, Tooltips, Bildrate (30 oder 60 FPS; 30 spart Rechenleistung auf der uConsole und ist voreingestellt), Ereignislog/Telemetrie als Statuszeile (Standard, mehr Platz für die Station) oder feste Leiste, und die **Realismusstufe** der nächsten Mission: **Einsteiger** (Bedienerassistenz an: automatische Linienbeschriftung, Blattfrequenz- und Katalog-/Senderkandidaten; der Computergegner greift zögerlicher an, wartet auf eine bessere Schusslösung und klassifiziert und startet als Fregatte seinen Hubschrauber 1,5-mal langsamer; Punkte 75 %), **Standard** (voreingestellt: Rohdaten und manuelle Analyse, der kalibrierte Gegner; Punkte 100 %) oder **Realistisch** (keine Assistenz; der Gegner greift entschlossener an, schießt auf eine gröbere Lösung und reagiert als Fregatte 30 % schneller; Punkte 125 %). Die Stufe stimmt nur den Computergegner ab, nie einen Menschen auf der anderen Seite, und eine laufende Mission behält die Stufe, mit der sie begann (die Zeile sagt dann "ab der nächsten Mission"). Das Endpanel zeigt die Stufe mit ihrem Punktefaktor; Spielstände behalten sie. Seite 2 (`Bild ab`/`Tab`): welche Seite der uConsole spielt, Fregatte (Standard) oder feindliches U-Boot; nur im Hauptmenü, nie gespeichert. Ein neues Spiel fragt ohnehin zuerst danach. Auf Seite 2 liegen auch die **geglätteten Kartenlinien** (standardmäßig aus; glättet Peilstriche, Küste und Plot, kostet auf der uConsole etwas Rechenzeit). Dazu die **gesprochenen Crew-Meldungen** (standardmäßig aus): die Crew meldet Torpedo im Wasser, neuen Kontakt mit Peilung, Sinkgeräusche, Torpedo los, Treffer, Gefechtsstationen, Seefernaufklärer auf Station und das Missionsende laut, Peilungen Ziffer für Ziffer. Die uConsole spricht über ein installiertes `espeak-ng` (`sudo apt install espeak-ng`) und bleibt ohne es stumm; Remote-Crew-Browser haben einen eigenen Schalter unter Einstellungen (Sprachausgabe des Browsers, in dessen Sprache). Spielt die uConsole das U-Boot, meldet stattdessen dessen Crew (siehe Kapitel Referenz).
|
||||
- `F9`: Commander / Remote Crew - Browser im LAN können Stationen übernehmen. Eine freie Station wird sofort mit allen ihren Rechten übernommen (auch Direktfeuer und Sonar-Liveaudio, wo die Station sie hat); eine Station, die ein Crewmitglied hält, wird angefragt, und der Host kann sie übergeben. Der Host kann jederzeit eine Station oder einzelne Rechte entziehen und bis zu zwei Browser zu reinen Beobachtern machen (Roster-Taste `O`): sie sehen jede Station beider Einheiten, ohne sie zu halten, können nichts befehlen und erhalten das SimLog mit Zeitstrahl zur Nachbesprechung und JSON-Export. Auf einem Windows-PC startet das Programm `U-Jagd-Windows.exe` das Spiel mit bereits eingeschalteter Remote Crew (Besatzungs- oder Solomodus) und zeigt Browser-Adresse, Beitrittscode und QR-Code; sein Feld Sprache stellt Starter, Spiel und Crew-Seiten zwischen English und Deutsch um und wird in den Einstellungen gespeichert. `--remote-crew` macht dasselbe über die Kommandozeile (siehe README). Die Crew-Seiten öffnen in der gespeicherten Sprache des Hosts (`F10`-Optionen auf der uConsole); der Knopf English/Deutsch in der Statusleiste des Browsers stellt nur diesen Browser um. Die Crew-Seite ist für Chrome oder Chromium (auch Edge) auf einem Desktop-PC gebaut; ein anderer Browser zeigt über dem Kopplungscode einen Hinweis, und eine Seite, die dort nicht starten kann, sagt das, statt endlos zu laden. Nach einem Update des Hosts lädt sich eine offene Browserseite einmal selbst neu und läuft so immer mit dem passenden Web-Client.
|
||||
|
||||
### Handy-Ausguck und Sehrohr
|
||||
@@ -293,7 +293,7 @@ Die x-Achse ist die Frequenz (0-300 Hz), die Zeit läuft nach unten. Die Klassen
|
||||
- Der Spektrumstreifen über dem Wasserfall schreibt die Frequenz über jede deutliche Linie (zwischen den Klassen interpoliert; mit `Leertaste` die gehaltene Hüllkurve). Wo sich Werte überdecken würden, behält die stärkere Linie ihre Beschriftung. Der Remote-Crew-Browser beschriftet seine Spektren genauso.
|
||||
- `F` wählt das Analyseband: FULL 0-300, LOW 4-80, SHAFT 8-55, MID 20-120 Hz. `Strg+Z` / `Strg+X` setzen die untere / obere Bandkante auf den Cursor für jeden Band-, Tief- oder Hochpass; `Umschalt+N` legt einen zusätzlichen Notch auf die Cursorfrequenz.
|
||||
- `Q` wählt die Integrationszeit: 2 s (die FFT des Empfängers), 8, 16 oder 64 s. Längere Integration mittelt aufeinanderfolgende Spektren, sodass ein schwacher stehender Ton aus dem Rauschen tritt; eine wandernde Linie verschmiert dabei. `Umschalt+Q` öffnet den Nonius: 20 Hz um den Cursor in der nativen 0,5-Hz-Auflösung.
|
||||
- Die Detailspalte liest den Pegel am Cursor. Automatisch beschriftet der Streifen Linien nur mit Bedienerassistenz Training (`F10`).
|
||||
- Die Detailspalte liest den Pegel am Cursor. Automatisch beschriftet der Streifen Linien nur auf der Realismusstufe Einsteiger (`F10`).
|
||||
|
||||
#### DEMON
|
||||
|
||||
@@ -309,11 +309,11 @@ DEMON demoduliert die Hüllkurve des Breitbandrauschens im Horchstrahl. Schraube
|
||||
Welle Blatt 2. Harmonische
|
||||
```
|
||||
|
||||
Die Anzeige zeigt gemessene Modulation, keine Identität. Nach einer Peilungsänderung einige Sekunden horchen, bevor Sie urteilen. Blätter selbst zählen: den Cursor (`Z`/`X`, 0,5 Hz) auf die Wellenlinie setzen und `K` drücken, dann auf die Blattlinie und erneut `K`; die Spalte zeigt Blätter = Blattfrequenz / Wellenfrequenz (mit der Abweichung von einer ganzen Zahl) und die Wellendrehzahl. Ein drittes `K` löscht beide Marken. Das Ergebnis mit den Referenzen im Kontaktanalysator (`F8`) vergleichen. Mit Bedienerassistenz Training (`F10`) beschriftet das Sonar zusätzlich Modulationslinien, schlägt Drehzahlen für 3-7 Blätter vor und rankt Katalogkandidaten.
|
||||
Die Anzeige zeigt gemessene Modulation, keine Identität. Nach einer Peilungsänderung einige Sekunden horchen, bevor Sie urteilen. Blätter selbst zählen: den Cursor (`Z`/`X`, 0,5 Hz) auf die Wellenlinie setzen und `K` drücken, dann auf die Blattlinie und erneut `K`; die Spalte zeigt Blätter = Blattfrequenz / Wellenfrequenz (mit der Abweichung von einer ganzen Zahl) und die Wellendrehzahl. Ein drittes `K` löscht beide Marken. Das Ergebnis mit den Referenzen im Kontaktanalysator (`F8`) vergleichen. Auf der Realismusstufe Einsteiger (`F10`) beschriftet das Sonar zusätzlich Modulationslinien, schlägt Drehzahlen für 3-7 Blätter vor und rankt Katalogkandidaten.
|
||||
|
||||
#### TMA, Umwelt und Aktiv
|
||||
|
||||
- **TMA** machen Sie selbst. Die Seite zeichnet die Peilungen des gewählten Kontakts über der Zeit. Stellen Sie eine Hypothese auf: `Z`/`X` Kurs (`Umschalt`: 1 Grad), `Strg+Z`/`Strg+X` Fahrt, `Q`/`Umschalt+Q` Entfernung auf der neuesten Peilung (`Strg`: 0,2 sm). Die bernsteinfarbene Kurve zeigt die Peilungen, die diese Hypothese vorhersagt, die Punkte am Fuß die Residuen (gemessen minus vorhergesagt). Gute Hypothesen lassen die Residuen um null streuen; ein falscher Kurs, eine falsche Fahrt oder Entfernung hinterlässt einen Trend. Die Spalte zeigt RMS der Residuen, den systematischen Trend nach Mittelung, die Passung und die Beobachtbarkeit. Die Entfernung ist erst nach einer eigenen Kursänderung beobachtbar (mindestens 6 Grad, besser 30-60); ohne sie verweigert `K`. `K` übernimmt die Hypothese als TMA-Fix des Kontakts; er wird auf Kurs und Fahrt mitgekoppelt und veraltet nach 120 s, also verfeinern und erneut übernehmen, wenn Peilungen hinzukommen. Verrauschte Peilungen ergeben auch bei guter Passung eine große Entfernungsunsicherheit. Tiefe schätzt TMA nicht. Mit Bedienerassistenz Training (`F10`) wird ein automatischer Solver-Vorschlag (er braucht mindestens 4 Peilungen über 180 s) als dünne Linie gezeichnet, und `Umschalt+K` kopiert ihn in die Hypothese. Sonobojen-Peilungen gehen mit der Boje als Beobachter in den Track ein. `Umschalt+T` wechselt die TMA-Methode: HYPOTHESE (oben), EKELUND (die Entfernung aus den Peilraten zweier eigener Schläge um eine Kursänderung von mindestens 30°, je 90 s; `Umschalt+K` übernimmt sie in die Hypothese, `K` nimmt dann wie üblich an) oder DOT-STACK (Residuenzeilen bei 0,6-, 1,0- und 1,6-facher Hypothesenentfernung: die flache Zeile ist die Entfernung, die die Peilungen stützen).
|
||||
- **TMA** machen Sie selbst. Die Seite zeichnet die Peilungen des gewählten Kontakts über der Zeit. Stellen Sie eine Hypothese auf: `Z`/`X` Kurs (`Umschalt`: 1 Grad), `Strg+Z`/`Strg+X` Fahrt, `Q`/`Umschalt+Q` Entfernung auf der neuesten Peilung (`Strg`: 0,2 sm). Die bernsteinfarbene Kurve zeigt die Peilungen, die diese Hypothese vorhersagt, die Punkte am Fuß die Residuen (gemessen minus vorhergesagt). Gute Hypothesen lassen die Residuen um null streuen; ein falscher Kurs, eine falsche Fahrt oder Entfernung hinterlässt einen Trend. Die Spalte zeigt RMS der Residuen, den systematischen Trend nach Mittelung, die Passung und die Beobachtbarkeit. Die Entfernung ist erst nach einer eigenen Kursänderung beobachtbar (mindestens 6 Grad, besser 30-60); ohne sie verweigert `K`. `K` übernimmt die Hypothese als TMA-Fix des Kontakts; er wird auf Kurs und Fahrt mitgekoppelt und veraltet nach 120 s, also verfeinern und erneut übernehmen, wenn Peilungen hinzukommen. Verrauschte Peilungen ergeben auch bei guter Passung eine große Entfernungsunsicherheit. Tiefe schätzt TMA nicht. Auf der Realismusstufe Einsteiger (`F10`) wird ein automatischer Solver-Vorschlag (er braucht mindestens 4 Peilungen über 180 s) als dünne Linie gezeichnet, und `Umschalt+K` kopiert ihn in die Hypothese. Sonobojen-Peilungen gehen mit der Boje als Beobachter in den Track ein. `Umschalt+T` wechselt die TMA-Methode: HYPOTHESE (oben), EKELUND (die Entfernung aus den Peilraten zweier eigener Schläge um eine Kursänderung von mindestens 30°, je 90 s; `Umschalt+K` übernimmt sie in die Hypothese, `K` nimmt dann wie üblich an) oder DOT-STACK (Residuenzeilen bei 0,6-, 1,0- und 1,6-facher Hypothesenentfernung: die flache Zeile ist die Entfernung, die die Peilungen stützen).
|
||||
- **UMWELT / FUSION** zeigt den Bathythermographen (`E`, 60 s Abklingzeit): gemessene Schichttiefe, Schallgeschwindigkeitsprofil und Konvergenzzonen, dazu den Vergleich HMS/TAS. Peilungen innerhalb 5 Grad bestätigen sich; ab 9 Grad Abweichung wird ein möglicher Geisterkontakt markiert. Die Schicht ist nicht fest: Nachmittagssonne macht sie flacher (etwa 8 m), starker Wind mischt sie über Stunden tiefer, und interne Wellen verschieben sie um einige Meter. Den BT nach einigen Stunden oder einem Wetterwechsel wiederholen. Das gemessene Profil ist die echte temperaturabhängige Schallgeschwindigkeit (Mackenzie-Gleichung) und fällt deshalb unterhalb der Schicht ab. Mit der Maus über dem Profil lesen Sie die genaue Tiefe, die dortige Schallgeschwindigkeit und ob die Tiefe über oder unter der Schicht liegt (uConsole und Web). Im Web-Client beschriftet die Grafik zusätzlich Schicht, Meeresgrund und das Schallgeschwindigkeitsminimum. Die Konvergenzzonen darin stammen aus dem gemessenen Profil selbst: aus der Strahlverfolgung dieses Profils über dem kartierten Bodentyp in der Tiefe des Arrays, sie ändern sich also mit Schicht, Tiefe und Boden (keine im Flachwasser).
|
||||
- **ACTIVE** listet die Echos der letzten 120 s: Peilung, Entfernung und Tiefe (+/-12 m). Ein Ping-Fix veraltet nach 120 s. `W` wählt den Puls: **CW** (1-s-Ton) misst die Entfernung grob (etwa 0,1-0,3 sm), trennt aber über den Doppler ein bewegtes Ziel vom Nachhall des Meeresbodens; **LFM** (100-Hz-Sweep) misst die Entfernung auf wenige Meter und gewinnt 20 dB gegen Rauschen, ein langsames oder stehendes Ziel bleibt aber im Nachhall. Die Echostärke hängt vom Aspekt (breitseits etwa 15 dB stärker als von vorn) und der Größe des Ziels ab. Felsgrund hallt viel stärker nach als Schlick; kartierte Wracks liefern echte Echos ohne zugehörigen Kontakt ("nicht zugeordnetes Echo").
|
||||
- **Das Echo hören:** Jede Rückkehr ist hörbar, sobald sie eintrifft, nach ihrer echten Laufzeit hin und zurück (etwa 2,5 s je Seemeile Entfernung), für das Schiffssonar ebenso wie für das Tauchsonar des Helikopters. Ein CW-Echo ist ein weicher Ton auf der Trägerfrequenz, ein LFM-Echo ein kurzer Sweep; maßgeblich ist der Puls, mit dem gepingt wurde. Ein starkes Echo hebt sich deutlich ab, ein schwaches steigt kaum aus dem Nachhallrauschen. Im Remote-Crew-Browser klingt das Echo über den allgemeinen Ton (laut oder leise). Das aktive Ping eines U-Boots kommt umgekehrt nach seiner einfachen Laufzeit an (etwa 1,2 s je Seemeile): Erst dann gibt die Fregatte ihren tiefen Warnton, spielt das Ping selbst und meldet es im Log mit der nach Gehör gemessenen Peilung (ganze Grad, etwa ±2° ungenau); eine Entfernung liefert ein fremdes Ping nie. **Richtungshören:** Mit Stereoton (Kopfhörer) kommen Echos, Detonationen und das Ping eines U-Boots aus der Peilung, aus der sie gehört wurden: links für Backbord, rechts für Steuerbord vom Bug des Schiffs aus, mittig recht voraus und achteraus (voraus und achteraus klingen gleich). Das eigene Ping, Starts und Geschützfeuer bleiben mittig. Der uConsole und der Remote-Crew-Browser setzen sie gleich.
|
||||
@@ -992,7 +992,7 @@ Seite 1 listet die Erfassungen; Seite 2 zeigt die Belege für die gewählte Erfa
|
||||
|
||||
- Die Peilgenauigkeit beträgt etwa +/-3 Grad. Erfassungen sind Peilungen, keine Positionen.
|
||||
- Ein drehendes Suchradar trifft die ESM-Antenne einmal je Umlauf mit der Hauptkeule; seine Nebenkeulen sind nur aus der Nähe hörbar. Die Belegseite zeigt den Spitzenpegel, eine Entfernungsschätzung unter Annahme der Leistungsklasse des besten Kandidaten (ein falscher Kandidat ergibt eine falsche Entfernung) und die gemessene Antennenumlaufzeit.
|
||||
- Standardmäßig (Bedienerassistenz aus, `F10`) zeigt die Belegseite nur die gemessenen Parameter und eine Bibliotheksabfrage: jeder Sender, dessen veröffentlichter Frequenz- (und PRF-)Bereich die Messung enthält, nach Namen sortiert, ohne Bewertung. Radartyp, Bedrohung und Entfernungsschätzung beurteilen Sie dann selbst; `C` schaltet die Bibliothek in Namensreihenfolge durch. Mit Assistenz Training werden Kandidaten nach Frequenz, PRF und Modulation mit Bewertung gerankt und Radartyp, Bedrohung und Entfernungsschätzung ausgefüllt. Ein Gleichstand ist keine Identifizierung.
|
||||
- Standardmäßig (Realismusstufe Standard oder Realistisch, `F10`) zeigt die Belegseite nur die gemessenen Parameter und eine Bibliotheksabfrage: jeder Sender, dessen veröffentlichter Frequenz- (und PRF-)Bereich die Messung enthält, nach Namen sortiert, ohne Bewertung. Radartyp, Bedrohung und Entfernungsschätzung beurteilen Sie dann selbst; `C` schaltet die Bibliothek in Namensreihenfolge durch. Auf der Stufe Einsteiger werden Kandidaten nach Frequenz, PRF und Modulation mit Bewertung gerankt und Radartyp, Bedrohung und Entfernungsschätzung ausgefüllt. Ein Gleichstand ist keine Identifizierung.
|
||||
- Die Korrelation mit Radar- oder Sonartracks nutzt vereinbare Zeit, Peilung und beobachtete Position, nie verborgene Identität.
|
||||
- Die Senderbibliothek enthält den Suchkopf des Seezielflugkörpers (9,0-9,5 GHz, PRF 1,8-3,2 kHz, Puls-Doppler). Er sendet nur auf den letzten 18 sm und erst, wenn der Tiefflieger über dem Radarhorizont ist, und er passt ebenso gut zum Feuerleitradar eines Angriffsflugzeugs: Peilungsverlauf und Luftlage entscheiden.
|
||||
- ESM läuft aus der OPZ-Abteilung: eine zerstörte OPZ legt es lahm.
|
||||
|
||||
@@ -133,7 +133,7 @@ The bottom status ticker shows the newest event and key telemetry; `F11` opens t
|
||||
- **Report a bug** (main menu): writes `~/.u-jagd/bug-report.txt` (version, platform and the newest lines of `~/.u-jagd/crash.log`, with your user name removed from paths) and shows a QR code that opens a new GitHub issue on a phone with version and platform filled in; attach the file there. `Enter` opens the issue with the log in a browser if the device has one, `Esc` goes back. After a crashed start the main menu selects this entry and says so. Nothing is sent until you submit the issue with your own GitHub account. The Windows starter ("Report a bug") and the browser settings menu have the same link.
|
||||
- `S` / `L`: save / load (slots 1-5). Saves are exact and deterministic: a loaded game continues identically.
|
||||
- **Autosave:** a running mission is saved every 5 minutes and when you quit or leave it for the main menu, to `~/.u-jagd/autosave.json` beside the five slots. The main menu then starts with **Continue mission**, which resumes it exactly; after a crash it holds the last 5-minute save. A mission that ends (won, lost or ship sunk) and any new mission delete the autosave. The web host (`--web-host`) does not autosave.
|
||||
- `F10`: options - language, fullscreen, audio, large text, tooltips, frame rate (30 or 60 FPS; 30 saves CPU on the uConsole and is the default), event log / telemetry as status ticker (default, more room for the station) or docked band, operator assistance off (default: raw data and manual analysis) or training (automatic line labels, blade-rate and catalogue/emitter candidates). Page 2 (`PgDn`/`Tab`): which side the uConsole plays, frigate (default) or hostile submarine; only in the main menu, never saved. A new game asks for it first anyway. Page 2 also holds **anti-aliased chart lines** (off by default; smooths bearing lines, coast and plot at some CPU cost on the uConsole). And **spoken crew reports** (off by default): the crew says torpedo in the water, new contact with bearing, breaking-up noises, torpedo away, hit, action stations, patrol aircraft on station and the mission result aloud, bearings digit by digit. The uConsole speaks through an installed `espeak-ng` (`sudo apt install espeak-ng`) and stays silent without it; Remote Crew browsers have their own switch under Settings (the browser's speech synthesis, in the browser's language). With the uConsole on the submarine the submarine's crew reports instead (see the reference chapter).
|
||||
- `F10`: options - language, fullscreen, audio, large text, tooltips, frame rate (30 or 60 FPS; 30 saves CPU on the uConsole and is the default), event log / telemetry as status ticker (default, more room for the station) or docked band, and the **realism level** for the next mission: **Beginner** (operator assistance on: automatic line labels, blade-rate and catalogue/emitter candidates; the computer opponent attacks less eagerly, waits for a better firing solution and, as the frigate, classifies and launches its helicopter 1.5 times slower; score 75 %), **Standard** (default: raw data and manual analysis, the calibrated opponent; score 100 %) or **Realistic** (no assistance; the opponent attacks more eagerly, fires on a rougher solution and reacts 30 % faster as the frigate; score 125 %). The level only tunes the computer opponent, never a human on the other side, and a running mission keeps the level it started with (the row then says "from the next mission"). The end panel shows the level with its score factor; saves keep it. Page 2 (`PgDn`/`Tab`): which side the uConsole plays, frigate (default) or hostile submarine; only in the main menu, never saved. A new game asks for it first anyway. Page 2 also holds **anti-aliased chart lines** (off by default; smooths bearing lines, coast and plot at some CPU cost on the uConsole). And **spoken crew reports** (off by default): the crew says torpedo in the water, new contact with bearing, breaking-up noises, torpedo away, hit, action stations, patrol aircraft on station and the mission result aloud, bearings digit by digit. The uConsole speaks through an installed `espeak-ng` (`sudo apt install espeak-ng`) and stays silent without it; Remote Crew browsers have their own switch under Settings (the browser's speech synthesis, in the browser's language). With the uConsole on the submarine the submarine's crew reports instead (see the reference chapter).
|
||||
- `F9`: Commander / Remote Crew - lets browser clients on the LAN take stations. A free station is taken at once with all of its rights (including direct fire and live sonar audio where the station has them); a station a crewmate holds is requested, and the host can hand it over. The host can revoke a station or single rights at any time, and can make up to two browsers read-only observers (roster key `O`): they watch any station of either unit without holding it, cannot command, and get the SimLog with a debrief timeline and JSON export. On a Windows PC the program `U-Jagd-Windows.exe` starts the game with Remote Crew already on (crew or solo mode) and shows the browser address, join code and QR code; its Language box switches the starter, the game and the crew pages between English and Deutsch and is saved in the settings. `--remote-crew` does the same from the command line (see the README). The crew pages open in the host's saved language (`F10` options on the uConsole); the English/Deutsch button in the browser's status bar switches that browser alone. The crew page is built for Chrome or Chromium (also Edge) on a desktop PC; another browser shows a hint above the pairing code, and a page that cannot start there says so instead of loading forever. After a host update an open browser page reloads itself once, so it always runs the web client that matches the host.
|
||||
|
||||
### Phone lookout and periscope
|
||||
@@ -292,7 +292,7 @@ The x axis is frequency (0-300 Hz), time runs downwards. Bins are 1 Hz below 40
|
||||
- The spectrum strip above the waterfall prints the frequency over every prominent line (interpolated between bins; with `Space` the held envelope). Where values would overlap, the stronger line keeps its label. The Remote Crew browser labels its spectra the same way.
|
||||
- `F` selects the analysed band: FULL 0-300, LOW 4-80, SHAFT 8-55, MID 20-120 Hz. `Ctrl+Z` / `Ctrl+X` set the low / high band edge at the cursor for any band-, low- or high-pass; `Shift+N` puts an extra notch on the cursor frequency.
|
||||
- `Q` selects the integration time: 2 s (the receiver's own FFT), 8, 16 or 64 s. Longer integration averages successive spectra so a weak steady tonal rises out of the noise, but a moving line smears. `Shift+Q` opens the vernier: 20 Hz around the cursor at the native 0.5 Hz resolution.
|
||||
- The detail rail reads the level at the cursor. The strip labels lines automatically only with operator assistance set to training (`F10`).
|
||||
- The detail rail reads the level at the cursor. The strip labels lines automatically only at the Beginner realism level (`F10`).
|
||||
|
||||
#### DEMON
|
||||
|
||||
@@ -308,11 +308,11 @@ DEMON demodulates the broadband noise envelope of the listening beam. Propeller
|
||||
shaft blade 2nd harmonic
|
||||
```
|
||||
|
||||
The display shows measured modulation, not identity. After changing the bearing listen for at least a few seconds before judging. Count blades yourself: move the cursor (`Z`/`X`, 0.5 Hz) onto the shaft line and press `K`, then onto the blade line and press `K` again; the rail shows blades = blade rate / shaft rate (with the deviation from a whole number) and the shaft RPM. A third `K` clears both marks. Compare the result with the references in the contact analyser (`F8`). With operator assistance set to training (`F10`) the sonar also labels modulation lines, proposes RPM for 3-7 blades and ranks catalogue candidates.
|
||||
The display shows measured modulation, not identity. After changing the bearing listen for at least a few seconds before judging. Count blades yourself: move the cursor (`Z`/`X`, 0.5 Hz) onto the shaft line and press `K`, then onto the blade line and press `K` again; the rail shows blades = blade rate / shaft rate (with the deviation from a whole number) and the shaft RPM. A third `K` clears both marks. Compare the result with the references in the contact analyser (`F8`). At the Beginner realism level (`F10`) the sonar also labels modulation lines, proposes RPM for 3-7 blades and ranks catalogue candidates.
|
||||
|
||||
#### TMA, environment and active
|
||||
|
||||
- **TMA** is yours. The page plots the bearings of the selected contact over time. Build a hypothesis: `Z`/`X` course (`Shift`: 1 degree), `Ctrl+Z`/`Ctrl+X` speed, `Q`/`Shift+Q` range on the newest bearing (`Ctrl`: 0.2 NM). The amber curve shows the bearings that hypothesis predicts, the dots at the foot the residuals (measured minus predicted). Good hypotheses leave residuals scattered around zero; a wrong course, speed or range leaves a trend. The rail shows the residual RMS, the systematic trend after averaging, the fit and the observability. Range is only observable after an own course change (at least 6 degrees, better 30-60): without one, `K` refuses. `K` accepts the hypothesis as the contact's TMA fix; it is dead-reckoned on its course and speed and ages out after 120 s, so refine and re-accept as bearings come in. Noisy bearings give a large range uncertainty even when the fit is good. TMA does not estimate depth. With operator assistance set to training (`F10`) an automatic solver proposal (it needs at least 4 bearings over 180 s) is drawn as a thin line and `Shift+K` copies it into the hypothesis. Sonobuoy bearings enter the track with the buoy as observer. `Shift+T` switches the TMA method: HYPOTHESIS (above), EKELUND (the range from the bearing rates of two own legs about one course change of 30 degrees or more, 90 s each; `Shift+K` copies it into the hypothesis, `K` then accepts as usual) or DOT STACK (residual rows at 0.6, 1.0 and 1.6 times the hypothesis range: the flat row is the range the bearings support).
|
||||
- **TMA** is yours. The page plots the bearings of the selected contact over time. Build a hypothesis: `Z`/`X` course (`Shift`: 1 degree), `Ctrl+Z`/`Ctrl+X` speed, `Q`/`Shift+Q` range on the newest bearing (`Ctrl`: 0.2 NM). The amber curve shows the bearings that hypothesis predicts, the dots at the foot the residuals (measured minus predicted). Good hypotheses leave residuals scattered around zero; a wrong course, speed or range leaves a trend. The rail shows the residual RMS, the systematic trend after averaging, the fit and the observability. Range is only observable after an own course change (at least 6 degrees, better 30-60): without one, `K` refuses. `K` accepts the hypothesis as the contact's TMA fix; it is dead-reckoned on its course and speed and ages out after 120 s, so refine and re-accept as bearings come in. Noisy bearings give a large range uncertainty even when the fit is good. TMA does not estimate depth. At the Beginner realism level (`F10`) an automatic solver proposal (it needs at least 4 bearings over 180 s) is drawn as a thin line and `Shift+K` copies it into the hypothesis. Sonobuoy bearings enter the track with the buoy as observer. `Shift+T` switches the TMA method: HYPOTHESIS (above), EKELUND (the range from the bearing rates of two own legs about one course change of 30 degrees or more, 90 s each; `Shift+K` copies it into the hypothesis, `K` then accepts as usual) or DOT STACK (residual rows at 0.6, 1.0 and 1.6 times the hypothesis range: the flat row is the range the bearings support).
|
||||
- **UMWELT / FUSION** shows the bathythermograph (`E`, 60 s cooldown): measured layer depth, sound-speed profile and convergence-zone bands, plus the HMS/TAS comparison. Bearings within 5 degrees confirm each other; 9 degrees or more apart are flagged as a possible ghost contact. The layer is not fixed: afternoon sun makes it shallower (about 8 m), strong wind mixes it deeper over hours, and internal waves move it a few metres. Repeat the BT after a few hours or a weather change. The measured profile is the real temperature-driven sound speed (Mackenzie equation), so it drops below the layer. Point the mouse at the profile to read the exact depth, the sound speed there and whether that depth lies above or below the layer (uConsole and web). In the web client the plot also labels the layer, the seabed and the sound-speed minimum.
|
||||
- **ACTIVE** lists echoes of the last 120 s: bearing, range and depth (+/-12 m). A ping fix ages out after 120 s. `W` selects the pulse: **CW** (1 s tone) gives coarse range (about 0.1-0.3 NM) but its Doppler separates a moving target from seabed reverberation; **LFM** (100 Hz sweep) measures range to a few metres and gains 20 dB against noise, but a slow or stationary target stays inside the reverberation. The echo strength depends on the target's aspect (broadside about 15 dB stronger than bow-on) and size. Rocky ground reverberates far more than mud; charted wrecks return real echoes that no contact owns ("unassociated echo").
|
||||
- **Hearing the echo:** every return is audible when it arrives, after its real two-way travel time (about 2.5 s per nautical mile of range), for the ship's sonar and the helicopter's dipping sonar alike. A CW echo is a soft tone on the carrier, an LFM echo a short sweep; the pulse is the one the ping was sent with. A strong echo stands out clearly, a faint one barely rises out of the reverberation hiss. In the Remote Crew browser the echo plays with the general sound (loud or faint). A submarine's active ping is heard the other way round, after its one-way travel time (about 1.2 s per nautical mile): only then does the frigate sound its low warning tone, play the ping itself and log it with the bearing measured by ear (whole degrees, about ±2° off); a ping never gives its range. **Directional hearing:** with stereo sound (headphones), echoes, detonations and a submarine's ping come from the bearing they were heard on: left for port, right for starboard of the ship's head, centred dead ahead and astern (ahead and astern sound the same). The ship's own ping, launches and gunfire stay centred. The uConsole and the Remote Crew browser place them alike.
|
||||
@@ -991,7 +991,7 @@ Page 1 lists intercepts; page 2 shows the evidence for the selected intercept (f
|
||||
|
||||
- Bearing accuracy is about +/-3 degrees. Intercepts are bearings, not positions.
|
||||
- A rotating search radar reaches the ESM antenna with its main beam once per revolution; its side lobes are heard only close in. The evidence page shows the peak signal level, a range estimate that assumes the power class of the best candidate (a wrong candidate gives a wrong range) and the measured antenna scan period.
|
||||
- By default (operator assistance off, `F10`) the evidence page shows only the measured parameters and a library lookup: every emitter whose published frequency (and PRF) range contains the measurement, in name order, without score. Radar type, threat and range estimate are then yours to judge; `C` cycles the library in name order. With assistance set to training, candidates are ranked by frequency, PRF and modulation with a score, and radar type, threat and range estimate are filled in. A tie is not an identification.
|
||||
- By default (realism level Standard or Realistic, `F10`) the evidence page shows only the measured parameters and a library lookup: every emitter whose published frequency (and PRF) range contains the measurement, in name order, without score. Radar type, threat and range estimate are then yours to judge; `C` cycles the library in name order. At the Beginner level, candidates are ranked by frequency, PRF and modulation with a score, and radar type, threat and range estimate are filled in. A tie is not an identification.
|
||||
- Correlation with radar or sonar tracks uses compatible time, bearing and observed position, never hidden identity.
|
||||
- The emitter library includes the anti-ship missile seeker (9.0-9.5 GHz, PRF 1.8-3.2 kHz, pulse-Doppler). It radiates only in the last 18 NM and only once the sea-skimmer is above the radar horizon, and it matches an attack aircraft's fire-control radar just as well: the bearing trend and the air picture decide.
|
||||
- ESM runs from the operations compartment: a destroyed operations room disables it.
|
||||
|
||||
+31
-3
@@ -953,6 +953,33 @@ DIFFICULTY_FIELDS = {
|
||||
}
|
||||
DIFFICULTY_FIELD_ORDER = tuple(DIFFICULTY_FIELDS)
|
||||
DEFAULT_DIFFICULTY = {name: spec[4] for name, spec in DIFFICULTY_FIELDS.items()}
|
||||
# Realism levels (preference ``level``, saved per mission as ``level``).
|
||||
# The level tunes only the computer opponent and the displays, never a human
|
||||
# on the other side: an AI submarine attacks more or less eagerly and waits
|
||||
# for a better or worse firing solution, and the AI frigate (when the
|
||||
# uConsole commands the submarine) classifies and calls its helicopter
|
||||
# slower or faster. Beginner also turns the operator assistance on,
|
||||
# Realistic turns it off. The mission score is multiplied by the factor.
|
||||
LEVELS = ("beginner", "standard", "realistic")
|
||||
LEVEL_DEFAULT = "standard"
|
||||
LEVEL_SCORE_FACTOR = {"beginner": 0.75, "standard": 1.0, "realistic": 1.25}
|
||||
# Multipliers on the mission's difficulty values (clamped to their bounds).
|
||||
LEVEL_ENEMY = {
|
||||
"beginner": {"enemy_attack_mult": 0.6, "enemy_solution_threshold": 0.75},
|
||||
"standard": {},
|
||||
"realistic": {"enemy_attack_mult": 1.3, "enemy_solution_threshold": 1.25},
|
||||
}
|
||||
# Multiplier on the AI frigate's mean classification and helicopter times.
|
||||
LEVEL_HUNTER_DELAY = {"beginner": 1.5, "standard": 1.0, "realistic": 0.7}
|
||||
|
||||
def apply_level(difficulty: dict, level: str) -> dict:
|
||||
"""The difficulty values with a realism level's enemy multipliers."""
|
||||
result = dict(difficulty)
|
||||
for name, factor in LEVEL_ENEMY.get(level, {}).items():
|
||||
kind, low, high = DIFFICULTY_FIELDS[name][:3]
|
||||
result[name] = kind(clamp(result[name] * factor, low, high))
|
||||
return result
|
||||
|
||||
# Fester Pool für die Bonus-"zweites U-Boot"-Ziehung (2:1 Richtung AIP,
|
||||
# entspricht dem bisherigen "harte"/"hardcore"-Pool).
|
||||
SECOND_SUB_POOL = ("aip_modern", "ssn", "aip_modern")
|
||||
@@ -970,9 +997,6 @@ SCORE_AMMO_BONUS = 200 # pro ungenutztem Torpedo (Sieg)
|
||||
SCORE_CIVIL_BONUS = 500 # keine zivilen Verluste (Sieg)
|
||||
SCORE_TIME_BONUS_MAX = 500 # Zeitbonus, anteilig nach verbleibender Zeit
|
||||
|
||||
# Radio tasking (``src/core/tasking.py``): HQ orders and incidents in the
|
||||
# built-in scenarios. The first offer comes after 15-25 minutes, the next
|
||||
# every 25-45 minutes, never more than two tasks open at once.
|
||||
# Incidents at sea (src/core/incidents.py): schedule and the four kinds.
|
||||
INCIDENT_FIRST_S = (1200.0, 2400.0)
|
||||
INCIDENT_INTERVAL_S = (1800.0, 3000.0)
|
||||
@@ -993,6 +1017,10 @@ INCIDENT_DARK_S = 7200.0
|
||||
INCIDENT_WHALES_RANGE_NM = (3.0, 6.0)
|
||||
INCIDENT_WHALES_COUNT = (2, 4)
|
||||
INCIDENT_WHALES_S = 3600.0
|
||||
|
||||
# Radio tasking (``src/core/tasking.py``): HQ orders and incidents in the
|
||||
# built-in scenarios. The first offer comes after 15-25 minutes, the next
|
||||
# every 25-45 minutes, never more than two tasks open at once.
|
||||
TASK_FIRST_OFFER_S = (900.0, 1500.0)
|
||||
TASK_INTERVAL_S = (1500.0, 2700.0)
|
||||
TASK_MAX_OFFERS = 6
|
||||
|
||||
+9
-5
@@ -106,7 +106,7 @@ class Game(PicturesMixin, OperatorMixin, DrawMixin, MissionBridgeMixin, EventMix
|
||||
# Options overlay rows in display order; the last two open sub-menus.
|
||||
_OPTION_ROWS = ("language", "fullscreen", "audio", "large_text", "tooltips",
|
||||
"simlog", "night_mode", "high_contrast", "frame_rate",
|
||||
"bottom_panel", "operator_assist", "live_traffic", "commander")
|
||||
"bottom_panel", "level", "live_traffic", "commander")
|
||||
# Second options page: game setup. The local side is per launch and never
|
||||
# persisted (the frigate is always the default).
|
||||
_OPTION_ROWS_SETUP = ("local_side", "aa_lines", "speech")
|
||||
@@ -200,7 +200,7 @@ class Game(PicturesMixin, OperatorMixin, DrawMixin, MissionBridgeMixin, EventMix
|
||||
self._radio_acc = 0.0
|
||||
self._slow_acc = 0.0
|
||||
self._apply_text_size()
|
||||
self.level = "custom"
|
||||
self.level = config.LEVEL_DEFAULT
|
||||
self.menu_difficulty = (dict(difficulty) if difficulty
|
||||
and _valid_difficulty_dict(difficulty)
|
||||
else dict(config.DEFAULT_DIFFICULTY))
|
||||
@@ -392,7 +392,11 @@ class Game(PicturesMixin, OperatorMixin, DrawMixin, MissionBridgeMixin, EventMix
|
||||
else self.menu_difficulty),
|
||||
# A campaign leg brings its carried torpedo stock.
|
||||
**(difficulty_override or {})}
|
||||
self.level = "custom"
|
||||
# The realism level of this mission (preference, saved per mission).
|
||||
self.level = self._preferred_level()
|
||||
self._difficulty_base = tuple(self.difficulty[name]
|
||||
for name in config.DIFFICULTY_FIELD_ORDER)
|
||||
self.difficulty = config.apply_level(self.difficulty, self.level)
|
||||
|
||||
if reference_sector is not None:
|
||||
# A mission's reference world: the named real sector, not seed % 128.
|
||||
@@ -778,8 +782,8 @@ class Game(PicturesMixin, OperatorMixin, DrawMixin, MissionBridgeMixin, EventMix
|
||||
# may be consumed by menu start; loads replace its world/sonar identity.
|
||||
self._prepared_menu_mission = (
|
||||
seed, self.scenario_key, self.world_mode,
|
||||
tuple(self.difficulty[name] for name in config.DIFFICULTY_FIELD_ORDER),
|
||||
self.hq_intel_mode(), id(self.world), id(self.sonar)) if self.in_menu else None
|
||||
self._difficulty_base, self.hq_intel_mode(), self.level,
|
||||
id(self.world), id(self.sonar)) if self.in_menu else None
|
||||
|
||||
def flash(self, text: object, seconds: float = 3.0) -> None:
|
||||
if (getattr(self, "local_side", "frigate") == "uboot"
|
||||
|
||||
+15
-3
@@ -958,9 +958,7 @@ class DrawMixin:
|
||||
self.tr("option.frame_rate", fps=self.frame_rate()),
|
||||
self.tr("option.bottom_panel") + ": "
|
||||
+ self.tr("option.bottom_panel." + self.bottom_panel_mode()),
|
||||
self.tr("option.operator_assist") + ": "
|
||||
+ self.tr("option.operator_assist." + ("training" if self.operator_assist()
|
||||
else "off")),
|
||||
self._level_option_text(),
|
||||
self.tr("option.live_traffic"),
|
||||
self.tr("commander.local.option"),
|
||||
)
|
||||
@@ -975,6 +973,16 @@ class DrawMixin:
|
||||
292, 650, 696, 46, config.COLOR_TEXT_DIM, size=18,
|
||||
align="center")
|
||||
|
||||
def _level_option_text(self) -> str:
|
||||
"""The realism level row; in a mission with another level it says
|
||||
that the choice applies from the next mission."""
|
||||
chosen = self._preferred_level()
|
||||
text = self.tr("option.level", level=self.tr("level." + chosen),
|
||||
factor=round(config.LEVEL_SCORE_FACTOR[chosen] * 100))
|
||||
if not self.in_menu and not self.game_over and self.level != chosen:
|
||||
text = self.tr("option.level_next", level=self.tr("level." + chosen))
|
||||
return text
|
||||
|
||||
def _draw_options_setup_page(self) -> None:
|
||||
row = self._options_row_rects()[0]
|
||||
locked = self.local_side_locked()
|
||||
@@ -1335,6 +1343,10 @@ class DrawMixin:
|
||||
self._sonar_audio_sequence = -1
|
||||
elif name in ("large_text", "high_contrast", "aa_lines"):
|
||||
self._apply_text_size()
|
||||
elif name == "level":
|
||||
# Beginner brings the operator assistance, the others drop it.
|
||||
self.preferences = replace(self.preferences, operator_assist=(
|
||||
"training" if value == "beginner" else "off"))
|
||||
elif name == "tooltips":
|
||||
self.tooltips_enabled = bool(value)
|
||||
self.pinned_tooltip = None
|
||||
|
||||
@@ -177,8 +177,11 @@ class EventMixin:
|
||||
choices = config.FPS_CHOICES
|
||||
step = -1 if key == pygame.K_LEFT else 1
|
||||
value = choices[(choices.index(self.frame_rate()) + step) % len(choices)]
|
||||
elif name == "operator_assist":
|
||||
value = ("off" if self.operator_assist() else "training")
|
||||
elif name == "level":
|
||||
levels = config.LEVELS
|
||||
step = -1 if key == pygame.K_LEFT else 1
|
||||
value = levels[(levels.index(self._preferred_level()) + step)
|
||||
% len(levels)]
|
||||
elif name == "bottom_panel":
|
||||
choices = layout.BOTTOM_PANEL_MODES
|
||||
value = choices[(choices.index(self.bottom_panel_mode()) + 1)
|
||||
|
||||
@@ -824,9 +824,23 @@ class OperatorMixin:
|
||||
estimate[0])
|
||||
|
||||
def operator_assist(self) -> bool:
|
||||
"""Training aids (auto peaks, blade-rate/catalog ranking, ESM IDs) on?"""
|
||||
"""Training aids (auto peaks, blade-rate/catalog ranking, ESM IDs) on?
|
||||
|
||||
The mission's realism level decides: Beginner always, Realistic
|
||||
never, Standard as the preference says."""
|
||||
level = getattr(self, "level", config.LEVEL_DEFAULT)
|
||||
if level != config.LEVEL_DEFAULT:
|
||||
return level == "beginner"
|
||||
return getattr(self.preferences, "operator_assist", "off") == "training"
|
||||
|
||||
def _preferred_level(self) -> str:
|
||||
"""The realism level the next mission starts with (preference)."""
|
||||
level = getattr(self.preferences, "level", config.LEVEL_DEFAULT)
|
||||
return level if level in config.LEVELS else config.LEVEL_DEFAULT
|
||||
|
||||
def level_score_factor(self) -> float:
|
||||
return config.LEVEL_SCORE_FACTOR.get(self.level, 1.0)
|
||||
|
||||
def set_sonar_cursor(self, page, frequency_hz):
|
||||
if page not in ("lofar", "demon"):
|
||||
return "invalid_value"
|
||||
|
||||
@@ -1393,6 +1393,9 @@ class SimMixin:
|
||||
self.score += bonus + config.SCORE_AMMO_BONUS * self.torpedo_count
|
||||
if not self.incident:
|
||||
self.score += config.SCORE_CIVIL_BONUS
|
||||
# The realism level scales the mission's score (Beginner less,
|
||||
# Realistic more).
|
||||
self.score = int(round(self.score * self.level_score_factor()))
|
||||
self.announce(message("runtime.mission.won" if win
|
||||
else "runtime.mission.lost"), "mission", 10.0)
|
||||
boat = self._opfor
|
||||
|
||||
+9
-2
@@ -137,7 +137,13 @@ def _recognised(game, contact) -> bool:
|
||||
"""The operator takes ``CLASSIFY_MEAN_S`` on average to recognise the
|
||||
sound: a stateless draw per cadence tick and contact."""
|
||||
tick = int(math.floor(game.sim_t / CADENCE_S))
|
||||
return detrand.u01(game.seed, "hunter.classify", contact.id, tick) < CADENCE_S / CLASSIFY_MEAN_S
|
||||
return (detrand.u01(game.seed, "hunter.classify", contact.id, tick)
|
||||
< CADENCE_S / (CLASSIFY_MEAN_S * _level_delay(game)))
|
||||
|
||||
|
||||
def _level_delay(game) -> float:
|
||||
"""The realism level stretches or shortens the crew's reaction times."""
|
||||
return config.LEVEL_HUNTER_DELAY.get(getattr(game, "level", config.LEVEL_DEFAULT), 1.0)
|
||||
|
||||
|
||||
def classify(game) -> bool:
|
||||
@@ -432,7 +438,8 @@ def helicopter(game, found) -> str:
|
||||
return "monitoring"
|
||||
if helo.state == "HANGAR":
|
||||
tick = int(math.floor(game.sim_t / CADENCE_S))
|
||||
if detrand.u01(game.seed, "hunter.helo", tick) >= CADENCE_S / HELO_READY_MEAN_S:
|
||||
if (detrand.u01(game.seed, "hunter.helo", tick)
|
||||
>= CADENCE_S / (HELO_READY_MEAN_S * _level_delay(game))):
|
||||
return "monitoring" # the deck readies the helicopter
|
||||
# The hunters fly with the search radar on (as before its switch).
|
||||
helo.radar_on = True
|
||||
|
||||
@@ -364,7 +364,8 @@ class MissionBridgeMixin:
|
||||
prepared = (self.seed, self.scenario_key, self.world_mode,
|
||||
tuple(candidate_difficulty[name]
|
||||
for name in config.DIFFICULTY_FIELD_ORDER),
|
||||
self.hq_intel_mode(), id(self.world), id(self.sonar))
|
||||
self.hq_intel_mode(), self._preferred_level(),
|
||||
id(self.world), id(self.sonar))
|
||||
reuse = (self.in_menu and self._prepared_menu_mission == prepared
|
||||
and self.sim_t == 0.0 and self.mission_time == 0.0
|
||||
and self.custom_mission_definition is None
|
||||
@@ -443,7 +444,9 @@ class MissionBridgeMixin:
|
||||
def _mission_started_notice(self):
|
||||
return message("runtime.mission.started",
|
||||
name=self.mission_name_display(),
|
||||
level=self.mission_level_display(),
|
||||
level=message("level." + self.level
|
||||
if self.level in config.LEVELS
|
||||
else "level." + config.LEVEL_DEFAULT),
|
||||
objective=self.mission_objective_display())
|
||||
|
||||
def _initial_threat_notice(self):
|
||||
@@ -515,7 +518,9 @@ class MissionBridgeMixin:
|
||||
return message(keys[self.mission.type_key])
|
||||
|
||||
def mission_level_display(self):
|
||||
return message("level.custom")
|
||||
level = self.level if self.level in config.LEVELS else config.LEVEL_DEFAULT
|
||||
return message("level.display", level=self.tr("level." + level),
|
||||
factor=round(config.LEVEL_SCORE_FACTOR[level] * 100))
|
||||
|
||||
def mission_description_display(self):
|
||||
if self.custom_mission_definition is not None:
|
||||
|
||||
+10
-1
@@ -8,7 +8,7 @@ import tempfile
|
||||
from dataclasses import asdict, dataclass, field, replace
|
||||
from pathlib import Path
|
||||
|
||||
from src.core.config import BOTTOM_PANEL_MODES, FPS_CHOICES, FPS_DEFAULT
|
||||
from src.core.config import BOTTOM_PANEL_MODES, FPS_CHOICES, FPS_DEFAULT, LEVELS
|
||||
from src.core.i18n import SUPPORTED_LANGUAGES, detect_system_language
|
||||
|
||||
_MAX_CREDENTIAL_LEN = 256
|
||||
@@ -38,6 +38,10 @@ class Preferences:
|
||||
# "training" adds automatic peak labels, blade-rate/catalog ranking and
|
||||
# ESM emitter candidates. Display only, never simulation state.
|
||||
operator_assist: str = "off"
|
||||
# Realism level of the next mission (``config.LEVELS``): Beginner turns
|
||||
# the assistance on and softens the computer opponent, Realistic turns
|
||||
# it off and sharpens the opponent; the score is scaled to match.
|
||||
level: str = "standard"
|
||||
live_ais_enabled: bool = False
|
||||
live_adsb_enabled: bool = False
|
||||
aisstream_api_key: str = ""
|
||||
@@ -92,6 +96,11 @@ def load_preferences(path: str | os.PathLike[str] | None = None) -> Preferences:
|
||||
assist = payload.get("operator_assist", defaults.operator_assist)
|
||||
values["operator_assist"] = (assist if assist in ("off", "training")
|
||||
else defaults.operator_assist)
|
||||
level = payload.get("level")
|
||||
if level not in LEVELS:
|
||||
# Settings from before the levels: assistance meant the beginner.
|
||||
level = "beginner" if values["operator_assist"] == "training" else defaults.level
|
||||
values["level"] = level
|
||||
for name in ("aisstream_api_key", "opensky_credentials"):
|
||||
value = payload.get(name, getattr(defaults, name))
|
||||
values[name] = value.strip()[:_MAX_CREDENTIAL_LEN] \
|
||||
|
||||
@@ -467,9 +467,9 @@ def valid_save_document(data, runtime_catalog=None) -> bool:
|
||||
or not 0 <= torpedo_inventory["count"] <= torpedo_inventory["total"] <= 100
|
||||
or not bounded(torpedo_inventory["depth"], 0, 10000)):
|
||||
return False
|
||||
# "level" is a cosmetic label now; the real custom-difficulty values
|
||||
# The mission's realism level; the difficulty values it already scaled
|
||||
# live in mission_runtime["difficulty"] (checked just below).
|
||||
if type(data.get("level")) is not str or not 1 <= len(data["level"]) <= 64:
|
||||
if data.get("level") not in config.LEVELS:
|
||||
return False
|
||||
runtime_mission = data.get("mission_runtime")
|
||||
if not isinstance(runtime_mission, dict):
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ This module is deliberately dependency-free because setuptools imports the
|
||||
version while building the project.
|
||||
"""
|
||||
|
||||
APP_VERSION = "1.3.87"
|
||||
APP_VERSION = "1.3.88"
|
||||
SAVE_VERSION = 34
|
||||
SAVE_SCHEMA = "u-jagd-save-v34"
|
||||
SPLASH_TEXT = (
|
||||
|
||||
@@ -0,0 +1,130 @@
|
||||
"""Realism levels: Beginner, Standard, Realistic tune the computer opponent,
|
||||
the operator assistance and the mission score, and stay with the mission."""
|
||||
|
||||
import copy
|
||||
import json
|
||||
from dataclasses import replace
|
||||
|
||||
import pygame
|
||||
import pytest
|
||||
|
||||
from src.core import config, hunter
|
||||
from src.core.game import Game
|
||||
from src.core.preferences import load_preferences
|
||||
|
||||
|
||||
def _game(level="standard", seed=6101, scenario="s1_patrouille"):
|
||||
game = Game(seed=seed, start_menu=False, audio_enabled=False)
|
||||
game.preferences = replace(game.preferences, level=level)
|
||||
game.reset(seed, scenario if scenario in config.SCENARIOS else None)
|
||||
return game
|
||||
|
||||
|
||||
def test_apply_level_scales_only_the_opponent_and_clamps():
|
||||
base = dict(config.DEFAULT_DIFFICULTY)
|
||||
assert config.apply_level(base, "standard") == base
|
||||
easy = config.apply_level(base, "beginner")
|
||||
hard = config.apply_level(base, "realistic")
|
||||
assert easy["enemy_attack_mult"] < base["enemy_attack_mult"] < hard["enemy_attack_mult"]
|
||||
assert (easy["enemy_solution_threshold"] < base["enemy_solution_threshold"]
|
||||
< hard["enemy_solution_threshold"])
|
||||
# Everything the player owns (torpedoes, repairs, noise) is untouched.
|
||||
for name in ("quiet_mult", "torpedo_count", "repair_mult", "time_limit_s"):
|
||||
assert easy[name] == hard[name] == base[name]
|
||||
high = dict(base, enemy_attack_mult=2.0, enemy_solution_threshold=0.4)
|
||||
capped = config.apply_level(high, "realistic")
|
||||
assert capped["enemy_attack_mult"] == 2.0
|
||||
assert capped["enemy_solution_threshold"] == 0.4
|
||||
|
||||
|
||||
@pytest.mark.parametrize("level", config.LEVELS)
|
||||
def test_mission_takes_the_preferred_level_and_scales_its_subs(level):
|
||||
game = _game(level)
|
||||
assert game.level == level
|
||||
expected = config.apply_level(
|
||||
{**config.DEFAULT_DIFFICULTY,
|
||||
**(config.SCENARIOS[game.scenario_key]["difficulty"] or game.menu_difficulty)},
|
||||
level)
|
||||
assert game.difficulty == expected
|
||||
assert game.operator_assist() == (level == "beginner")
|
||||
# Changing the preference mid-mission keeps the mission's level.
|
||||
game.preferences = replace(game.preferences, level="realistic" if level != "realistic"
|
||||
else "beginner")
|
||||
assert game.level == level
|
||||
|
||||
|
||||
def test_standard_follows_the_assist_preference():
|
||||
game = _game("standard")
|
||||
assert not game.operator_assist()
|
||||
game.preferences = replace(game.preferences, operator_assist="training")
|
||||
assert game.operator_assist()
|
||||
game.level = "realistic"
|
||||
assert not game.operator_assist()
|
||||
|
||||
|
||||
def test_score_factor_on_the_mission_end():
|
||||
scores = {}
|
||||
for level in config.LEVELS:
|
||||
game = _game(level)
|
||||
game.score = 1000
|
||||
game._end_mission(False, "test")
|
||||
scores[level] = game.score
|
||||
assert scores == {"beginner": 750, "standard": 1000, "realistic": 1250}
|
||||
|
||||
|
||||
def test_level_survives_save_and_load_and_is_validated():
|
||||
game = _game("realistic")
|
||||
state = json.loads(json.dumps(game.save_state()))
|
||||
assert state["level"] == "realistic"
|
||||
twin = _game("beginner", seed=1)
|
||||
assert twin._load_save_data(copy.deepcopy(state))
|
||||
assert twin.level == "realistic"
|
||||
assert twin.difficulty == game.difficulty
|
||||
assert not twin.operator_assist()
|
||||
for bad in ("custom", "", 3, None):
|
||||
broken = copy.deepcopy(state)
|
||||
broken["level"] = bad
|
||||
assert not twin._load_save_data(broken)
|
||||
assert twin.level == "realistic"
|
||||
|
||||
|
||||
def test_hunter_reaction_times_follow_the_level():
|
||||
game = _game("beginner")
|
||||
assert hunter._level_delay(game) == config.LEVEL_HUNTER_DELAY["beginner"] > 1.0
|
||||
game.level = "realistic"
|
||||
assert hunter._level_delay(game) < 1.0
|
||||
game.level = "standard"
|
||||
assert hunter._level_delay(game) == 1.0
|
||||
|
||||
|
||||
def test_preferences_file_levels(tmp_path):
|
||||
path = tmp_path / "settings.json"
|
||||
path.write_text(json.dumps({"level": "realistic"}), encoding="utf-8")
|
||||
assert load_preferences(path).level == "realistic"
|
||||
# Settings from before the levels: training assistance meant a beginner.
|
||||
path.write_text(json.dumps({"operator_assist": "training"}), encoding="utf-8")
|
||||
assert load_preferences(path).level == "beginner"
|
||||
path.write_text(json.dumps({"level": "godmode"}), encoding="utf-8")
|
||||
assert load_preferences(path).level == "standard"
|
||||
|
||||
|
||||
def test_options_row_cycles_the_level_and_sets_the_assistance(monkeypatch):
|
||||
game = _game("standard")
|
||||
monkeypatch.setattr("src.core.game_draw.save_preferences", lambda prefs: None)
|
||||
game.options_open = True
|
||||
game.options_page = 0
|
||||
game.options_sel = game._OPTION_ROWS.index("level")
|
||||
game._handle_administration_key(pygame.K_RIGHT)
|
||||
assert game.preferences.level == "realistic"
|
||||
assert game.preferences.operator_assist == "off"
|
||||
game._handle_administration_key(pygame.K_RIGHT)
|
||||
assert game.preferences.level == "beginner"
|
||||
assert game.preferences.operator_assist == "training"
|
||||
# The running mission keeps its level; the row says so.
|
||||
assert game.level == "standard"
|
||||
game.in_menu = False
|
||||
simple = game.tr("option.level", level=game.tr("level.beginner"), factor=75)
|
||||
text = game._level_option_text()
|
||||
assert text == game.tr("option.level_next", level=game.tr("level.beginner"))
|
||||
game.level = "beginner"
|
||||
assert game._level_option_text() == simple
|
||||
@@ -86,7 +86,7 @@ def test_source_and_wheel_contain_editor_templates(tmp_path):
|
||||
(ROOT / "data/contact_analysis" / name).read_bytes()
|
||||
assert any(name.endswith(".dist-info/licenses/THIRD_PARTY_NOTICES.md")
|
||||
for name in wheel_names)
|
||||
assert any(name.endswith("-1.3.87.dist-info/METADATA") for name in wheel_names)
|
||||
assert any(name.endswith("-1.3.88.dist-info/METADATA") for name in wheel_names)
|
||||
|
||||
source = next(tmp_path.glob("u_jagd-*.tar.gz"))
|
||||
with tarfile.open(source) as archive:
|
||||
@@ -139,7 +139,7 @@ def test_source_and_wheel_contain_editor_templates(tmp_path):
|
||||
[sys.executable, "-c",
|
||||
"from importlib import resources; "
|
||||
"assert resources.files('data.editor_templates').joinpath('mission.json').is_file(); "
|
||||
"from src.core.version import APP_VERSION; assert APP_VERSION == '1.3.87'; "
|
||||
"from src.core.version import APP_VERSION; assert APP_VERSION == '1.3.88'; "
|
||||
"from src.commander.server import CommanderServer; "
|
||||
"server=CommanderServer(); server.start('127.0.0.1',0); server.stop(); "
|
||||
"from src.core import manual; page=manual.html_page('de'); assert 'station-sonar' in page; "
|
||||
|
||||
@@ -14,9 +14,9 @@ from src.world.real_coast import sector_for_seed
|
||||
|
||||
|
||||
def test_release_version_and_exact_splash_text():
|
||||
assert APP_VERSION == "1.3.87"
|
||||
assert APP_VERSION == "1.3.88"
|
||||
assert SPLASH_TEXT == (
|
||||
"Anti Sub Marine Warfare on uConsole by Dominik Bornhäußer Version 1.3.87"
|
||||
"Anti Sub Marine Warfare on uConsole by Dominik Bornhäußer Version 1.3.88"
|
||||
)
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user