From c8ae63405f594d5fca1518283c68e719602a55d8 Mon Sep 17 00:00:00 2001 From: Zoey Kitt Date: Sat, 16 Nov 2024 14:03:25 -0600 Subject: Oh my god it's gameplay --- scenes/main.gd | 4 ++++ scenes/main.tscn | 1 + 2 files changed, 5 insertions(+) diff --git a/scenes/main.gd b/scenes/main.gd index 53da549..c984f43 100644 --- a/scenes/main.gd +++ b/scenes/main.gd @@ -41,3 +41,7 @@ func _on_microgame_win(window: MicrogameWindow): func _on_stock_ticker_buy(amount: Variant) -> void: net_worth = net_worth.minus(amount) + + +func _on_stock_ticker_sell(amount: Variant) -> void: + net_worth = net_worth.plus(amount) diff --git a/scenes/main.tscn b/scenes/main.tscn index 7156bd7..c2c58b1 100644 --- a/scenes/main.tscn +++ b/scenes/main.tscn @@ -33,3 +33,4 @@ size = Vector2i(1280, 720) [connection signal="timeout" from="Microgame spawn timer" to="." method="_on_microgame_spawn_timer_timeout"] [connection signal="buy" from="Window/Stock ticker" to="." method="_on_stock_ticker_buy"] +[connection signal="sell" from="Window/Stock ticker" to="." method="_on_stock_ticker_sell"] -- cgit v1.2.3