button make sound now :)

This commit is contained in:
Luna 2021-10-04 11:47:40 -04:00
parent dd16a0debc
commit c49c2fa8c4

View File

@ -104,6 +104,10 @@ impl Action<Scenes, ScreenError, GameContext> for NextLevelScreen {
Ok(ActionFlag::SwitchState(Scenes::InGameScene))
}
else if self.is_level_select_pressed {
context
.flag_send
.send(Some(ControlFlag::SoundTrigger("button-press".to_string())))
.unwrap();
Ok(ActionFlag::SwitchState(Scenes::LevelSelectScreen))
}else {
Ok(ActionFlag::Continue)