Skip to content

Commit

Permalink
Add win fanfare and power up sound
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicfreeston committed May 14, 2023
1 parent 9eaad80 commit c8a9980
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion mygame/app/main.rb
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,9 @@ def update

if geometry.find_intersect_rect player, state.power_ups
player.vel.y += controls_settings.bounce_up_speed
audio[:powerup] ||= {
input: "sound/powerup.wav"
}
end
player.bounce_at = state.tick_count

Expand Down Expand Up @@ -308,7 +311,7 @@ def update
# win
if player.intersect_rect? state.goal
audio[:win] = {
input: "sound/win.wav"
input: "sound/fanfare.ogg"
}
@next_scene = IntroScene.new WIN_TEXTS
end
Expand Down
Binary file added mygame/sound/fanfare.ogg
Binary file not shown.
Binary file added mygame/sound/powerup.wav
Binary file not shown.

0 comments on commit c8a9980

Please sign in to comment.