Crediti dal titolo e dalla fine, con la dedica al Lele in testa; le idee di Yuri e Francesco
I crediti stanno in story.credits (un ruolo, i nomi): Yuri Baldi per idee e consigli, Francesco Bacci per storia e aneddoti di San Piero. In piccolo, la nota che Monkey Island è un marchio di Lucasfilm citato solo nella dedica. In docs/IDEE.md chi ci aiuta, il gioco in due parti con i giochi del paese dopo la storia (Yuri) e il Maestro Bacci. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UdeKd62opy9PKgpQXtVctF
This commit is contained in:
+11
@@ -68,6 +68,16 @@ function nextIntro() {
|
||||
$('intro').addEventListener('click', e => { if (e.target !== $('skip-intro')) nextIntro(); });
|
||||
$('skip-intro').addEventListener('click', () => { introLine = story.intro.length; nextIntro(); });
|
||||
|
||||
// --- Crediti: costruiti da story.credits; si aprono dal titolo e dalla fine, Chiudi o Esc tornano indietro.
|
||||
$('credits-list').replaceChildren(...(story.credits ?? []).flatMap(({ role, names }) => {
|
||||
const dt = document.createElement('dt'), dd = document.createElement('dd');
|
||||
dt.textContent = role;
|
||||
dd.textContent = names.join(' · ');
|
||||
return [dt, dd];
|
||||
}));
|
||||
for (const b of document.querySelectorAll('.open-credits')) b.addEventListener('click', () => { $('credits').hidden = false; });
|
||||
$('close-credits').addEventListener('click', () => { $('credits').hidden = true; });
|
||||
|
||||
function showTitle() {
|
||||
running = false;
|
||||
const saved = storage && readSave(storage);
|
||||
@@ -159,6 +169,7 @@ function updateChoices() {
|
||||
|
||||
window.addEventListener('keydown', e => {
|
||||
if (e.target === $('volume')) return;
|
||||
if (!$('credits').hidden) { if (e.key === 'Escape') $('credits').hidden = true; return; }
|
||||
if (!$('intro').hidden && [' ', 'Enter'].includes(e.key)) { e.preventDefault(); nextIntro(); return; }
|
||||
if (e.key === 'm' || e.key === 'M') { music.toggle(); saveAudio(); showSound(); return; }
|
||||
if (!running) return;
|
||||
|
||||
Reference in New Issue
Block a user