|
|
|
@ -4,9 +4,10 @@ signal condensedCupcake1()
|
|
|
|
|
|
|
|
|
|
#Cupcake Values
|
|
|
|
|
var ccVanNum: int = 0
|
|
|
|
|
var ccVanValue: int = 1
|
|
|
|
|
var ccChocNum: int = 0
|
|
|
|
|
|
|
|
|
|
#Cupcake Prices
|
|
|
|
|
#Cupcake Upgrade Prices
|
|
|
|
|
var ccVanPrice: int = 10
|
|
|
|
|
var ccVanPrice2: int = 15
|
|
|
|
|
var ccVanPrice3: int = 15
|
|
|
|
@ -22,6 +23,7 @@ var ccChocolate
|
|
|
|
|
var ccchoc
|
|
|
|
|
|
|
|
|
|
#Other
|
|
|
|
|
@onready var timer = get_node("Cupcake Spawn Timer")
|
|
|
|
|
var horseAttached = true
|
|
|
|
|
var horse_instance
|
|
|
|
|
var mouse_position = Vector2.ZERO
|
|
|
|
@ -70,7 +72,6 @@ func collectCupcakes():
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func _on_timeout():
|
|
|
|
|
var timer = get_node("Cupcake Spawn Timer")
|
|
|
|
|
spawnCupcakes()
|
|
|
|
|
collectCupcakes()
|
|
|
|
|
timer.start
|
|
|
|
@ -81,7 +82,7 @@ func _on_play_area_body_exited(body):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func _on_cupcake_cc_van_collected():
|
|
|
|
|
ccVanNum += 1
|
|
|
|
|
ccVanNum += ccVanValue
|
|
|
|
|
ccCount -= 1
|
|
|
|
|
collectCupcakes()
|
|
|
|
|
|
|
|
|
@ -90,21 +91,23 @@ func _on_upgrades_one_more_cupcake():
|
|
|
|
|
if ccVanNum >= ccVanPrice:
|
|
|
|
|
ccSpawnRate += 1
|
|
|
|
|
ccVanNum -= ccVanPrice
|
|
|
|
|
ccVanPrice = ccVanPrice * 2
|
|
|
|
|
$Upgrades/Control/ScrollContainer/VanGrid/VanUp1/Price.text = str(ccVanPrice)
|
|
|
|
|
ccVanPrice = ccVanPrice * PI
|
|
|
|
|
$Upgrades/Control/ScrollContainer/VanGrid/VanUp1/Price.text = str(ccVanPrice)
|
|
|
|
|
collectCupcakes()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func _on_upgrades_faster_cupcake():
|
|
|
|
|
pass # Replace with function body.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func _on_upgrades_condensed_cupcake():
|
|
|
|
|
pass
|
|
|
|
|
if ccVanNum >= ccVanPrice2:
|
|
|
|
|
ccVanNum -= ccVanPrice2
|
|
|
|
|
ccVanPrice2 = ccVanPrice2 * PI
|
|
|
|
|
timer.wait_time = timer.wait_time - (timer.wait_time * 0.01)
|
|
|
|
|
$Upgrades/Control/ScrollContainer/VanGrid/VanUp2/Price.text = str(ccVanPrice2)
|
|
|
|
|
collectCupcakes()
|
|
|
|
|
|
|
|
|
|
func _on_upgrades_condensed_cupcake_1():
|
|
|
|
|
if ccVanNum >= ccVanPrice3:
|
|
|
|
|
ccVanNum -= ccVanPrice3
|
|
|
|
|
ccVanPrice2 = ccVanPrice3 * 2
|
|
|
|
|
emit_signal("condensedCupcakes1")
|
|
|
|
|
$Upgrades/Control/ScrollContainer/VanGrid/VanUp3/Price.text = str(ccVanPrice3)
|
|
|
|
|
ccVanPrice3 = ccVanPrice3 * PI
|
|
|
|
|
ccVanValue += 1
|
|
|
|
|
$Upgrades/Control/ScrollContainer/VanGrid/VanUp3/Price.text = str(ccVanPrice3)
|
|
|
|
|
collectCupcakes()
|
|
|
|
|