diff --git a/art_collector.gd b/art_collector.gd index 95d910e..f35659b 100644 --- a/art_collector.gd +++ b/art_collector.gd @@ -7,9 +7,10 @@ func _ready() -> void: func normal_paddle(): $ArtCollectorAnimations.play("NormalPaddle") $NormalPaddleSound.play() + $PaddleSuccess.play() await $ArtCollectorAnimations.animation_finished $ArtCollectorAnimations.play("Idle") - + func critical_paddle(): $ArtCollectorAnimations.play("CriticalPaddle") diff --git a/art_collector.tscn b/art_collector.tscn index 84307cf..aee9920 100644 --- a/art_collector.tscn +++ b/art_collector.tscn @@ -1,8 +1,9 @@ -[gd_scene load_steps=48 format=3 uid="uid://dnuvh3k5qxs63"] +[gd_scene load_steps=49 format=3 uid="uid://dnuvh3k5qxs63"] [ext_resource type="Script" uid="uid://bbi0th2aq426c" path="res://art_collector.gd" id="1_dsoqt"] [ext_resource type="Texture2D" uid="uid://clrqm1hxhq7ru" path="res://assets/character/collector.png" id="1_y6o5m"] [ext_resource type="AudioStream" uid="uid://b6wb4yjtofbhn" path="res://assets/character/paddle-final.wav" id="3_erevg"] +[ext_resource type="AudioStream" uid="uid://b7qyt2h17kjea" path="res://assets/gavel/audio/ask-bet.wav" id="4_1ghdj"] [sub_resource type="AtlasTexture" id="AtlasTexture_5k0jt"] atlas = ExtResource("1_y6o5m") @@ -357,3 +358,7 @@ autoplay = "Idle" [node name="NormalPaddleSound" type="AudioStreamPlayer" parent="."] stream = ExtResource("3_erevg") +volume_db = 5.0 + +[node name="PaddleSuccess" type="AudioStreamPlayer" parent="."] +stream = ExtResource("4_1ghdj") diff --git a/assets/numpad/ask-bet-final.wav b/assets/numpad/ask-bet-final.wav new file mode 100644 index 0000000..7ab8a6b Binary files /dev/null and b/assets/numpad/ask-bet-final.wav differ diff --git a/assets/numpad/ask-bet-final.wav.import b/assets/numpad/ask-bet-final.wav.import new file mode 100644 index 0000000..f2870cb --- /dev/null +++ b/assets/numpad/ask-bet-final.wav.import @@ -0,0 +1,24 @@ +[remap] + +importer="wav" +type="AudioStreamWAV" +uid="uid://bq5yl788b424g" +path="res://.godot/imported/ask-bet-final.wav-a14c56b5c504914f5825f4a4cab70d4a.sample" + +[deps] + +source_file="res://assets/numpad/ask-bet-final.wav" +dest_files=["res://.godot/imported/ask-bet-final.wav-a14c56b5c504914f5825f4a4cab70d4a.sample"] + +[params] + +force/8_bit=false +force/mono=false +force/max_rate=false +force/max_rate_hz=44100 +edit/trim=false +edit/normalize=false +edit/loop_mode=0 +edit/loop_begin=0 +edit/loop_end=-1 +compress/mode=2 diff --git a/audience_manager.gd b/audience_manager.gd index c6dddaf..47b05ca 100644 --- a/audience_manager.gd +++ b/audience_manager.gd @@ -1,6 +1,6 @@ class_name AudienceManager extends Node2D -@export var desk: Desk +@export var desk: Desk @export var timer: Timer @export var game_manager: GameManager @export var bark_buttons: BarkButtons @@ -46,7 +46,7 @@ func raise_paddle(): print("play norm paddle") bark_critical = false ask_accepted.emit() - + func _handle_auctioneer_bark(): if timer.time_left >= think_min_time: @@ -57,13 +57,13 @@ func _handle_auctioneer_bark(): func _handle_bid_delay_timeout(): if game_manager.state == game_manager.bidding_state.ASKING: - if randf_range(1.2, 5.3) >= bid_threshold: + if randf_range(1.2, 5.3) >= bid_threshold: raise_paddle() timer.stop() func _handle_ask_proposed(amount): current_ask = amount - + if randf() <= think_chance: timer.stop() var ask_duration: float = randf_range(min_audience_think_time, max_audience_think_time) diff --git a/desk.tscn b/desk.tscn index 5dd1f21..ff7aba2 100644 --- a/desk.tscn +++ b/desk.tscn @@ -52,7 +52,7 @@ [ext_resource type="Texture2D" uid="uid://bwhf5712gd67h" path="res://assets/numpad/ask.png" id="27_unpof"] [ext_resource type="Texture2D" uid="uid://cxwxmqnnbyl3s" path="res://assets/numpad/ask-depressed.png" id="28_4l1rv"] [ext_resource type="AudioStream" uid="uid://bvto7ghmy8j0o" path="res://assets/gavel/audio/invalid-bet.wav" id="31_v5y5a"] -[ext_resource type="AudioStream" uid="uid://b7qyt2h17kjea" path="res://assets/gavel/audio/ask-bet.wav" id="32_dnpqj"] +[ext_resource type="AudioStream" uid="uid://bq5yl788b424g" path="res://assets/numpad/ask-bet-final.wav" id="53_mq8ri"] [sub_resource type="SpriteFrames" id="SpriteFrames_g470s"] animations = [{ @@ -303,7 +303,7 @@ one_shot = true stream = ExtResource("31_v5y5a") [node name="SuccessSoundPlayer" type="AudioStreamPlayer2D" parent="Numpad"] -stream = ExtResource("32_dnpqj") +stream = ExtResource("53_mq8ri") [node name="ProgressBar" type="ProgressBar" parent="."] layout_mode = 0