Busfahrt: Neustart-Button + Onboarding-Doppelung abgesichert

- ggs-quick-intro: open() entfernt vorab alle vorhandenen Overlays (nie 2x).
- Busfahrt: Neustart-Button (btn-reset, location.reload mit Rueckfrage).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-08-25 16:54:34 +02:00
parent 8f89613eee
commit 496fc59c7b
2 changed files with 6 additions and 1 deletions
+5 -1
View File
@@ -158,7 +158,11 @@
function open() {
if (!_config) return;
close();
// Sicherheitsnetz: alle evtl. schon vorhandenen Overlays entfernen (nie doppelt)
var olds = document.querySelectorAll('.ggs-qi-back');
for (var i = 0; i < olds.length; i++) olds[i].remove();
_back = null;
document.removeEventListener('keydown', onKey);
_page = 1;
render();
}
+1
View File
@@ -625,6 +625,7 @@
</div>
<button class="bf-toggle active" id="audio-toggle" onclick="toggleAudio()" title="Ton (SFX) ein/aus" aria-label="Ton umschalten">🔊</button>
<button class="bf-toggle" id="btn-info" onclick="if(window.GGS_TUTORIAL&&typeof window.GGS_TUTORIAL.replay==='function')window.GGS_TUTORIAL.replay();" title="Anleitung nochmal zeigen" aria-label="Anleitung"></button>
<button class="bf-toggle" id="btn-reset" onclick="if(confirm('Fahrt neu starten? Dein bisheriger Fortschritt geht verloren.'))location.reload()" title="Neu starten" aria-label="Neu starten">🔄</button>
<button class="bf-toggle" id="black-map-toggle" onclick="toggleBlackMap()" title="Beschriftung ein/aus" aria-label="Beschriftung umschalten"><svg class="ic" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"><path d="M12.6 4H18a2 2 0 0 1 2 2v5.4a2 2 0 0 1-.6 1.4l-6.6 6.6a2 2 0 0 1-2.8 0l-4.4-4.4a2 2 0 0 1 0-2.8L11.2 4.6a2 2 0 0 1 1.4-.6z"/><circle cx="15.7" cy="8.3" r="1.4"/></svg></button>
</div>
</div>