2024-09-19 19:03:06 -06:00
|
|
|
extends Control
|
|
|
|
|
|
|
|
|
2024-10-03 06:45:13 -06:00
|
|
|
@onready var styling: Control = $Styling
|
|
|
|
|
|
|
|
|
2024-09-19 19:03:06 -06:00
|
|
|
func _on_exit_button_pressed() -> void:
|
|
|
|
get_tree().quit()
|
|
|
|
|
|
|
|
|
|
|
|
func _on_test_button_pressed() -> void:
|
|
|
|
var rand_difficulty = NPC.npcDifficulties.values().pick_random()
|
2024-10-01 14:13:54 -06:00
|
|
|
var rand_tier = NPC.npcTiers.values().pick_random()
|
2024-10-11 19:26:49 -06:00
|
|
|
var anNPC = NPC.new()
|
2024-10-01 14:13:54 -06:00
|
|
|
%TestNMEMaxHealthVal.text = str(anNPC.maxHealth)
|
|
|
|
#TestEMaxHealthVal.label_settings = LabelSettings.new()
|
|
|
|
%TestNMEName.text = str(NPC.npcDifficulties.find_key(anNPC.npcDifficulty))
|
|
|
|
%TestNMETierVal.text = str(NPC.npcTiers.find_key(anNPC.npcTier))
|
2024-10-03 06:45:13 -06:00
|
|
|
# style the name label based on the difficulty
|
|
|
|
styling.format_label_difficulty(%TestNMEName, anNPC.npcDifficulty)
|
2024-09-19 19:03:06 -06:00
|
|
|
#anNPC.position = Vector2(64, 64)
|
|
|
|
#add_child(anNPC)
|