diff options
author | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-01-28 18:06:21 +0200 |
---|---|---|
committer | Henrique Alves <henrique.alves@itsjungle.xyz> | 2024-01-28 18:06:25 +0200 |
commit | 44b7184234b90eb687edff350ace7cadcc4c2b17 (patch) | |
tree | 5c721e70608f8ecf87a69e576cd7313dc62115d0 | |
parent | dbf0f0770a8795d2820c0f9d416393d4dff0340d (diff) | |
download | gamejam-ggj-2024-44b7184234b90eb687edff350ace7cadcc4c2b17.tar.gz gamejam-ggj-2024-44b7184234b90eb687edff350ace7cadcc4c2b17.tar.bz2 gamejam-ggj-2024-44b7184234b90eb687edff350ace7cadcc4c2b17.zip |
Add sounds
-rw-r--r-- | game/main.gd | 30 | ||||
-rw-r--r-- | game/main.tscn | 42 | ||||
-rw-r--r-- | game/menu.tscn | 7 | ||||
-rw-r--r-- | game/microgames/baseball_kiss/baseball_kiss.gd | 2 | ||||
-rw-r--r-- | game/microgames/baseball_kiss/baseball_kiss.tscn | 7 | ||||
-rw-r--r-- | game/microgames/find_window/find_window.gd | 2 | ||||
-rw-r--r-- | game/microgames/find_window/find_window.tscn | 9 | ||||
-rw-r--r-- | game/microgames/flowers_delivery/flowers_delivery.gd | 1 | ||||
-rw-r--r-- | game/microgames/flowers_delivery/flowers_delivery.tscn | 6 | ||||
-rw-r--r-- | game/shared/assets/GGJ_mainmenu.ogg.import | 2 |
10 files changed, 95 insertions, 13 deletions
diff --git a/game/main.gd b/game/main.gd index 7e32d1e..666a6ff 100644 --- a/game/main.gd +++ b/game/main.gd @@ -22,6 +22,8 @@ var lives = 4 func _ready() -> void: randomize() + _set_speed(1) + %AudioMusic.play() MICROGAMES.shuffle() @@ -44,12 +46,16 @@ func _ready() -> void: await transition.play_result_animation(_won_last_microgame) - if not _won_last_microgame: + if _won_last_microgame: + %AudioCheer.play() + else: + %AudioCrowdBooMicrogame.play() await get_tree().create_timer(0.5).timeout transition.lose_life() lives -= 1 if lives == 0: + %AudioCrowdBooLives.play() await get_tree().create_timer(0.5).timeout %FadeAnimationPlayer.play_backwards("fade_in") await %FadeAnimationPlayer.animation_finished @@ -70,13 +76,17 @@ func _ready() -> void: Session.shown_types[_current_microgame.microgame_control] = true var instruction_resource = instruction_popup.get_instruction(_current_microgame.microgame_control) + + %AudioMusic.playing = false + %AudioBeforeMinigame.play() await transition.show_instruction(instruction_resource) %MicrogameInstructionLabel.show_instruction(_current_microgame.instructions) - + await transition.microgame_fade_in() %MicrogameTvTimer.play() + %AudioMinigame.play() _current_microgame.process_mode = Node.PROCESS_MODE_INHERIT _won_last_microgame = await _current_microgame.finished @@ -86,7 +96,19 @@ func _ready() -> void: %MicrogameTvTimer.finish() await get_tree().create_timer(0.5).timeout - + %AudioMusic.playing = true _starting = false _microgame_count += 1 - Engine.time_scale = 1 + (_microgame_count * 0.05) + _set_speed(1 + (_microgame_count * 0.05)) + %AudioMinigame.stop() + %AudioMinigame.seek(0) + + +func _set_speed(speed): + Engine.time_scale = speed + %AudioMusic.pitch_scale = speed + %AudioCrowdBooMicrogame.pitch_scale = speed + %AudioCheer.pitch_scale = speed + %AudioCrowdBooLives.pitch_scale = speed + %AudioBeforeMinigame.pitch_scale = speed + %AudioMinigame.pitch_scale = 0.2 + speed diff --git a/game/main.tscn b/game/main.tscn index 67984ff..91c541c 100644 --- a/game/main.tscn +++ b/game/main.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=36 format=3 uid="uid://culqaacu08vye"] +[gd_scene load_steps=43 format=3 uid="uid://culqaacu08vye"] [ext_resource type="Script" path="res://game/main.gd" id="1_i86db"] [ext_resource type="PackedScene" uid="uid://u3g8s4kck61t" path="res://game/transition/transition.tscn" id="2_xhsf2"] @@ -14,12 +14,19 @@ [ext_resource type="Texture2D" uid="uid://n0sv45rq3u1d" path="res://game/shared/timer/5.png" id="9_yhgor"] [ext_resource type="Texture2D" uid="uid://cfur1citqmkd1" path="res://game/shared/timer/4.png" id="10_v6xue"] [ext_resource type="Texture2D" uid="uid://bt58qlhtr7b4d" path="res://game/shared/timer/3.png" id="11_gpmug"] +[ext_resource type="Texture2D" uid="uid://d02a8362doj7y" path="res://game/shared/tutorial/assets/Img_background_instrucoes.png" id="11_v5fki"] [ext_resource type="Texture2D" uid="uid://bu3mgglucxpjs" path="res://game/shared/timer/2.png" id="12_igwy3"] [ext_resource type="Texture2D" uid="uid://vme6xl77c48e" path="res://game/shared/timer/1.png" id="13_mb5n2"] [ext_resource type="Texture2D" uid="uid://d1dtbc4srhlpl" path="res://game/shared/timer/Img_timer_1.png" id="14_e5s51"] [ext_resource type="PackedScene" uid="uid://bqbngfstmish5" path="res://game/shared/explosion/explosion.tscn" id="15_macy5"] [ext_resource type="FontFile" uid="uid://den305djdhip6" path="res://game/shared/assets/SingleDay-Regular.ttf" id="19_vtcb7"] [ext_resource type="Script" path="res://game/MicrogameInstructionLabel.gd" id="20_375k7"] +[ext_resource type="AudioStream" uid="uid://dgypuqc63dc42" path="res://game/shared/assets/GGJ_mainmenu.ogg" id="21_jt87d"] +[ext_resource type="AudioStream" uid="uid://1h8sp7gicxnf" path="res://game/shared/assets/239595__xtrgamr__crowdbooing_01.wav" id="22_8v0p5"] +[ext_resource type="AudioStream" uid="uid://cf2a4lljx4ewn" path="res://game/shared/assets/432874__xtrgamr__lfs_yaycheer.wav" id="23_1d5ic"] +[ext_resource type="AudioStream" uid="uid://bhxutp70ragb0" path="res://game/shared/assets/GGJ_losegame.wav" id="24_bvjjt"] +[ext_resource type="AudioStream" uid="uid://ddiw5ip0kw3ji" path="res://game/shared/assets/GGJ_beforeminigame.wav" id="25_pwjmx"] +[ext_resource type="AudioStream" uid="uid://6es5it5d7hj4" path="res://game/shared/assets/GGJ_minigamebg.wav" id="26_bxqka"] [sub_resource type="Animation" id="Animation_q2678"] length = 0.001 @@ -86,9 +93,13 @@ label_2 = "To train holding hands with your loved one" [sub_resource type="LabelSettings" id="LabelSettings_wskk0"] font_size = 64 +outline_size = 10 +outline_color = Color(0, 0, 0, 1) [sub_resource type="LabelSettings" id="LabelSettings_wx7qq"] font_size = 32 +outline_size = 10 +outline_color = Color(0, 0, 0, 1) [sub_resource type="Animation" id="Animation_s35sg"] length = 0.001 @@ -325,14 +336,14 @@ grow_vertical = 2 script = ExtResource("3_lei0q") instructions = Array[ExtResource("4_30kv1")]([SubResource("Resource_o6d01"), SubResource("Resource_sjq73"), SubResource("Resource_40y54")]) -[node name="ColorRect" type="ColorRect" parent="ForegroundLayer/InstructionPopup"] +[node name="ColorRect" type="TextureRect" parent="ForegroundLayer/InstructionPopup"] layout_mode = 1 anchors_preset = 15 anchor_right = 1.0 anchor_bottom = 1.0 grow_horizontal = 2 grow_vertical = 2 -color = Color(0.701961, 0.564706, 0.968627, 1) +texture = ExtResource("11_v5fki") [node name="TextureZoeira" type="TextureRect" parent="ForegroundLayer/InstructionPopup"] unique_name_in_owner = true @@ -437,3 +448,28 @@ label_settings = SubResource("LabelSettings_83xq3") horizontal_alignment = 1 vertical_alignment = 1 script = ExtResource("20_375k7") + +[node name="AudioMusic" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("21_jt87d") +volume_db = -10.0 + +[node name="AudioCrowdBooMicrogame" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("22_8v0p5") + +[node name="AudioCheer" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("23_1d5ic") + +[node name="AudioCrowdBooLives" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("24_bvjjt") + +[node name="AudioBeforeMinigame" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("25_pwjmx") + +[node name="AudioMinigame" type="AudioStreamPlayer" parent="."] +unique_name_in_owner = true +stream = ExtResource("26_bxqka") diff --git a/game/menu.tscn b/game/menu.tscn index 9764478..0b17dfb 100644 --- a/game/menu.tscn +++ b/game/menu.tscn @@ -1,6 +1,7 @@ -[gd_scene load_steps=5 format=3 uid="uid://bvjimat8d7liw"] +[gd_scene load_steps=6 format=3 uid="uid://bvjimat8d7liw"] [ext_resource type="Script" path="res://game/menu.gd" id="1_24jgf"] +[ext_resource type="AudioStream" uid="uid://dgypuqc63dc42" path="res://game/shared/assets/GGJ_mainmenu.ogg" id="2_w8s3m"] [sub_resource type="Animation" id="Animation_amao6"] length = 0.001 @@ -75,3 +76,7 @@ color = Color(0, 0, 0, 1) libraries = { "": SubResource("AnimationLibrary_n3va2") } + +[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."] +stream = ExtResource("2_w8s3m") +autoplay = true diff --git a/game/microgames/baseball_kiss/baseball_kiss.gd b/game/microgames/baseball_kiss/baseball_kiss.gd index ba03388..8c03fc3 100644 --- a/game/microgames/baseball_kiss/baseball_kiss.gd +++ b/game/microgames/baseball_kiss/baseball_kiss.gd @@ -35,3 +35,5 @@ func _on_hand_collision_area_shape_entered(area_rid, area, area_shape_index, loc $BreCharacter.play("win") kiss.queue_free() finished.emit(true) + $Victory.pitch_scale = Engine.time_scale + $Victory.play() diff --git a/game/microgames/baseball_kiss/baseball_kiss.tscn b/game/microgames/baseball_kiss/baseball_kiss.tscn index 9d6abd7..fdf1e32 100644 --- a/game/microgames/baseball_kiss/baseball_kiss.tscn +++ b/game/microgames/baseball_kiss/baseball_kiss.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=22 format=3 uid="uid://h4y7kn003ao1"] +[gd_scene load_steps=23 format=3 uid="uid://h4y7kn003ao1"] [ext_resource type="Script" path="res://game/microgames/baseball_kiss/baseball_kiss.gd" id="1_urxm5"] [ext_resource type="Texture2D" uid="uid://1mnstkvhabph" path="res://game/microgames/baseball_kiss/assets/Img_background_windows.png" id="2_odjhy"] @@ -11,6 +11,7 @@ [ext_resource type="Texture2D" uid="uid://di8c7rl1lm62b" path="res://game/microgames/baseball_kiss/assets/Img_kiss.png" id="6_j2h3k"] [ext_resource type="Texture2D" uid="uid://cym248ma3nprt" path="res://game/microgames/baseball_kiss/assets/Img_bre_3.png" id="6_j64wj"] [ext_resource type="Texture2D" uid="uid://b4mybwt5qhyfv" path="res://game/microgames/baseball_kiss/assets/Img_pepe_2.png" id="7_nvi3g"] +[ext_resource type="AudioStream" uid="uid://di7ei7o6rvkum" path="res://game/microgames/baseball_kiss/assets/GGJ_WinBaseball.wav" id="12_hw2sk"] [sub_resource type="SpriteFrames" id="SpriteFrames_yf7ev"] animations = [{ @@ -213,4 +214,8 @@ texture = ExtResource("6_j2h3k") position = Vector2(1.44458, -1.86267) shape = SubResource("RectangleShape2D_53xmk") +[node name="Victory" type="AudioStreamPlayer" parent="."] +process_mode = 3 +stream = ExtResource("12_hw2sk") + [connection signal="area_shape_entered" from="PepeCharacter/HandCollision" to="." method="_on_hand_collision_area_shape_entered"] diff --git a/game/microgames/find_window/find_window.gd b/game/microgames/find_window/find_window.gd index b409d48..1ee1cc9 100644 --- a/game/microgames/find_window/find_window.gd +++ b/game/microgames/find_window/find_window.gd @@ -17,3 +17,5 @@ func _on_send_button_button_down(): %TextBoxMessage.hide() %ChatMessage.show() finished.emit(true) + $Victory.pitch_scale = Engine.time_scale + $Victory.play() diff --git a/game/microgames/find_window/find_window.tscn b/game/microgames/find_window/find_window.tscn index bea4c96..1fb3522 100644 --- a/game/microgames/find_window/find_window.tscn +++ b/game/microgames/find_window/find_window.tscn @@ -1,10 +1,11 @@ -[gd_scene load_steps=7 format=3 uid="uid://cfitfl87k1wu2"] +[gd_scene load_steps=8 format=3 uid="uid://cfitfl87k1wu2"] [ext_resource type="Script" path="res://game/microgames/find_window/find_window.gd" id="1_167ws"] [ext_resource type="Texture2D" uid="uid://j0btxfrk2q8k" path="res://game/microgames/find_window/assets/Img_background_windows.png" id="1_w06df"] [ext_resource type="Texture2D" uid="uid://7h0hokgsxon4" path="res://game/microgames/find_window/assets/Img_MSN_namoradinha.png" id="3_ekh6x"] [ext_resource type="Script" path="res://game/microgames/find_window/msn_girlfriend.gd" id="4_ithnb"] -[ext_resource type="PackedScene" uid="uid://dxo3khe6emukf" path="res://game/microgames/find_window/msn_regular.tscn" id="4_t7t3v"] +[ext_resource type="PackedScene" path="res://game/microgames/find_window/msn_regular.tscn" id="4_t7t3v"] +[ext_resource type="AudioStream" uid="uid://cwb7oyqr6ix7o" path="res://game/microgames/find_window/assets/GGJ_msnvictory.wav" id="6_1udmc"] [sub_resource type="LabelSettings" id="LabelSettings_csx47"] font_color = Color(0.443137, 0.443137, 0.443137, 1) @@ -105,4 +106,8 @@ offset_bottom = 620.0 [node name="Timer" type="Timer" parent="."] +[node name="Victory" type="AudioStreamPlayer" parent="."] +process_mode = 3 +stream = ExtResource("6_1udmc") + [connection signal="button_down" from="AllWindows/ImgMsnNamoradinha/SendButton" to="." method="_on_send_button_button_down"] diff --git a/game/microgames/flowers_delivery/flowers_delivery.gd b/game/microgames/flowers_delivery/flowers_delivery.gd index 648b77f..b9dbdef 100644 --- a/game/microgames/flowers_delivery/flowers_delivery.gd +++ b/game/microgames/flowers_delivery/flowers_delivery.gd @@ -8,3 +8,4 @@ func _microgame_ready() -> void: func _on_died(): finished.emit(false) + $Lose.play() diff --git a/game/microgames/flowers_delivery/flowers_delivery.tscn b/game/microgames/flowers_delivery/flowers_delivery.tscn index 5b6d052..1794c1a 100644 --- a/game/microgames/flowers_delivery/flowers_delivery.tscn +++ b/game/microgames/flowers_delivery/flowers_delivery.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=16 format=3 uid="uid://cxxawcp2cuijl"] +[gd_scene load_steps=17 format=3 uid="uid://cxxawcp2cuijl"] [ext_resource type="Texture2D" uid="uid://dbohkvl4ryqbk" path="res://game/microgames/flowers_delivery/assets/girlfriend.png" id="1_isthg"] [ext_resource type="Script" path="res://game/microgames/flowers_delivery/flowers_delivery.gd" id="1_jhoh1"] @@ -7,6 +7,7 @@ [ext_resource type="Texture2D" uid="uid://dfd2176us2w7g" path="res://game/microgames/flowers_delivery/assets/player2.png" id="3_pyt0j"] [ext_resource type="Texture2D" uid="uid://bjs5knhxc6vvi" path="res://game/microgames/flowers_delivery/assets/dodge.png" id="4_snyja"] [ext_resource type="Texture2D" uid="uid://dv1e2uv1xcoxs" path="res://game/shared/assets/blank.png" id="6_omk1m"] +[ext_resource type="AudioStream" uid="uid://el3oki6pjf3j" path="res://game/microgames/flowers_delivery/assets/527291__wolfdoctor__stick-wacking-slowed-down.wav" id="8_df7lp"] [sub_resource type="SpriteFrames" id="SpriteFrames_fhfcp"] animations = [{ @@ -107,3 +108,6 @@ mesh = SubResource("BoxMesh_xy5s1") [node name="WorldEnvironment" type="WorldEnvironment" parent="."] environment = SubResource("Environment_lochx") + +[node name="Lose" type="AudioStreamPlayer" parent="."] +stream = ExtResource("8_df7lp") diff --git a/game/shared/assets/GGJ_mainmenu.ogg.import b/game/shared/assets/GGJ_mainmenu.ogg.import index 901b4a9..583a670 100644 --- a/game/shared/assets/GGJ_mainmenu.ogg.import +++ b/game/shared/assets/GGJ_mainmenu.ogg.import @@ -12,7 +12,7 @@ dest_files=["res://.godot/imported/GGJ_mainmenu.ogg-ecca82e798c7988f25ab2130991b [params] -loop=false +loop=true loop_offset=0 bpm=0 beat_count=0 |