Allow input to fall through flashing messages

This is for parity with the original game
This commit is contained in:
Alex Page 2022-02-03 19:19:00 -05:00
parent 550713aaf8
commit 094d8e8617
2 changed files with 66 additions and 57 deletions

View file

@ -38,6 +38,7 @@ pub struct SoundEffects {
pub slow_hit: SoundSamples,
pub medium_hit: SoundSamples,
pub fast_hit: SoundSamples,
pub pause: SoundSamples,
rng: RandomNumberGenerator,
}
@ -153,6 +154,19 @@ impl SoundEffects {
duration: Duration::from_millis(25),
}],
}),
pause: sound_output.render_sound_effect(&SoundEffect {
sounds: {
let mut sounds = vec![Sound {
sound_type: SoundType::Tone(500),
duration: Duration::from_millis(100),
}];
sounds.extend((100..=200).rev().step_by(10).map(|x| Sound {
sound_type: SoundType::Tone(x),
duration: Duration::from_millis(20),
}));
sounds
},
}),
rng: RandomNumberGenerator::new(),
}
}