From 9ab6f6e2093038a7f79c6321fda8ad44bd99347b Mon Sep 17 00:00:00 2001 From: Zoey Kitt Date: Sat, 16 Nov 2024 17:09:11 -0600 Subject: Haha bonk I think --- scenes/stockticker/stonks.gd | 1 + 1 file changed, 1 insertion(+) (limited to 'scenes/stockticker/stonks.gd') diff --git a/scenes/stockticker/stonks.gd b/scenes/stockticker/stonks.gd index 1279382..cb556f4 100644 --- a/scenes/stockticker/stonks.gd +++ b/scenes/stockticker/stonks.gd @@ -135,6 +135,7 @@ func _on_timer_timeout() -> void: new_price = Big.new(0) shares = 0 shares_label.text = "Shares\nHeld:%d" % shares + $AudioStreamPlayer.play() if len(price_history) >= MAX_PRICES: price_history.pop_front() -- cgit v1.2.3 From 98c0e0e97e0f01a28ad55873da44e3aa586c3424 Mon Sep 17 00:00:00 2001 From: Zoey Kitt Date: Sat, 16 Nov 2024 17:18:21 -0600 Subject: Make stonk window shake upon bankruptcy --- scenes/stockticker/stonks.gd | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'scenes/stockticker/stonks.gd') diff --git a/scenes/stockticker/stonks.gd b/scenes/stockticker/stonks.gd index cb556f4..5cb0ab4 100644 --- a/scenes/stockticker/stonks.gd +++ b/scenes/stockticker/stonks.gd @@ -20,7 +20,7 @@ var darksouls_text: Label var price_history = [] var base_pos_mult = 0.5 # no size limit -var base_neg_mult = 0.5 # probably keep this below 1 +var base_neg_mult = 100.5 # probably keep this below 1 var hype_mult = 1.0 var hype_decr = 0.1 @@ -71,6 +71,7 @@ func draw_stonks(minval: Big, maxval: Big) -> void: var pos = Vector2(x_pos, y_pos) stonks.add_point(pos, index) index += 1 + func get_min_price() -> Big: var minval = Big.new(-1) @@ -136,6 +137,7 @@ func _on_timer_timeout() -> void: shares = 0 shares_label.text = "Shares\nHeld:%d" % shares $AudioStreamPlayer.play() + $ShakePivot.shake() if len(price_history) >= MAX_PRICES: price_history.pop_front() -- cgit v1.2.3