diff --git a/project/demos/ability_test_ui/abilities/ability_000.gd b/project/demos/ability_test_ui/abilities/ability_000.gd index c075ee2..939e7dd 100644 --- a/project/demos/ability_test_ui/abilities/ability_000.gd +++ b/project/demos/ability_test_ui/abilities/ability_000.gd @@ -1 +1 @@ -extends Ability +class_name TestAbilityScript extends Ability diff --git a/project/demos/ability_test_ui/abilities/test_ability_resource.tres b/project/demos/ability_test_ui/abilities/test_ability_resource.tres new file mode 100644 index 0000000..93189a0 --- /dev/null +++ b/project/demos/ability_test_ui/abilities/test_ability_resource.tres @@ -0,0 +1,5 @@ +[gd_resource type="Ability" format=3 uid="uid://bt7jgvhdfhsqc"] + +[resource] +ability_name = &"test_ability_resource" +tags_added_on_activation = PackedStringArray("enemy.ai.combat.chasing", "enemy.ai.combat.low_health", "enemy.ai.combat.panic") diff --git a/project/demos/ability_test_ui/main.gd b/project/demos/ability_test_ui/main.gd index e07a0bf..231ac63 100644 --- a/project/demos/ability_test_ui/main.gd +++ b/project/demos/ability_test_ui/main.gd @@ -1 +1,2 @@ extends Control + diff --git a/project/demos/ability_test_ui/main.tscn b/project/demos/ability_test_ui/main.tscn index 56c9691..68c7b1e 100644 --- a/project/demos/ability_test_ui/main.tscn +++ b/project/demos/ability_test_ui/main.tscn @@ -1,9 +1,11 @@ -[gd_scene load_steps=3 format=3 uid="uid://ye6lunjs1ns2"] +[gd_scene load_steps=5 format=3 uid="uid://ye6lunjs1ns2"] [ext_resource type="Script" path="res://demos/ability_test_ui/main.gd" id="1_8w5uo"] +[ext_resource type="Ability" uid="uid://bt7jgvhdfhsqc" path="res://demos/ability_test_ui/abilities/test_ability_resource.tres" id="2_fs4wh"] +[ext_resource type="Script" path="res://demos/ability_test_ui/abilities/ability_000.gd" id="3_nqgh0"] -[sub_resource type="Ability" id="Ability_o615e"] -tags_added_on_activation = PackedStringArray("enemy.ai.combat.chasing", "enemy.ai.combat.low_health", "enemy.ai.combat.panic") +[sub_resource type="Ability" id="Ability_qsw14"] +script = ExtResource("3_nqgh0") [node name="Main" type="Control"] layout_mode = 3 @@ -15,4 +17,4 @@ grow_vertical = 2 script = ExtResource("1_8w5uo") [node name="AbilityContainer" type="AbilityContainer" parent="."] -abilities = Array[Ability]([SubResource("Ability_o615e")]) +abilities = Array[Ability]([ExtResource("2_fs4wh"), SubResource("Ability_qsw14")]) diff --git a/src/editor_plugin/main_scene/ggs_main_scene.cpp b/src/editor_plugin/main_scene/ggs_main_scene.cpp index 8c3ce73..5a801d7 100644 --- a/src/editor_plugin/main_scene/ggs_main_scene.cpp +++ b/src/editor_plugin/main_scene/ggs_main_scene.cpp @@ -26,11 +26,13 @@ void MainScene::_ready() tab_container->add_child(tag_manager_panel); tab_container->add_child(attributes_panel); - tab_container->add_child(ability_panel); + // commented. Will come with a visual ability designer in the future. + // tab_container->add_child(ability_panel); tag_manager_panel->set_name(tag_manager_panel->tr("Tag Manager")); attributes_panel->set_name(attributes_panel->tr("Attributes")); - ability_panel->set_name(ability_panel->tr("Ability")); + // commented. Will come with a visual ability designer in the future. + // ability_panel->set_name(ability_panel->tr("Ability")); AttributeMainScene *attribute_main_scene = memnew(AttributeMainScene); TagMainScene *tag_main_scene = memnew(TagMainScene);