From 1a6dd05f13d7afb312332c9636436cadcf01639b Mon Sep 17 00:00:00 2001 From: jacob janzen <53062115+JacobJanzen@users.noreply.github.com> Date: Sat, 16 Nov 2024 11:43:41 -0600 Subject: Stonks for real this time (#2) * start labels * stonks * stonks for real this time --- scenes/stockticker/buy_n_sell.gd | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 scenes/stockticker/buy_n_sell.gd (limited to 'scenes/stockticker/buy_n_sell.gd') diff --git a/scenes/stockticker/buy_n_sell.gd b/scenes/stockticker/buy_n_sell.gd deleted file mode 100644 index be0e777..0000000 --- a/scenes/stockticker/buy_n_sell.gd +++ /dev/null @@ -1,25 +0,0 @@ -extends Node2D - -var stonks = 0 - -# Called when the node enters the scene tree for the first time. -func _ready() -> void: - var label = $"Shares Held Label" - label.text = "Shares\nHeld:%d" % stonks - -# Called every frame. 'delta' is the elapsed time since the previous frame. -func _process(delta: float) -> void: - pass - - -func _on_buy_button_button_up() -> void: - if stonks < 100: - stonks += 1 - var label = $"Shares Held Label" - label.text = "Shares\nHeld:%d" % stonks - -func _on_sell_button_button_up() -> void: - if stonks > 0: - stonks -= 1 - var label = $"Shares Held Label" - label.text = "Shares\nHeld:%d" % stonks -- cgit v1.2.3