diff --git a/DungeonShooting_Godot/prefab/ui/MapEditor.tscn b/DungeonShooting_Godot/prefab/ui/MapEditor.tscn
index 945a117..a324d75 100644
--- a/DungeonShooting_Godot/prefab/ui/MapEditor.tscn
+++ b/DungeonShooting_Godot/prefab/ui/MapEditor.tscn
@@ -57,6 +57,9 @@
[node name="Draw" type="Node2D" parent="Bg/HSplitContainer/Left/MapView/SubViewport/TileMap"]
z_index = 100
+[node name="CanvasLayer" type="CanvasLayer" parent="Bg/HSplitContainer/Left/MapView/SubViewport"]
+layer = 2
+
[node name="Right" type="Panel" parent="Bg/HSplitContainer"]
custom_minimum_size = Vector2(300, 0)
layout_mode = 2
diff --git a/DungeonShooting_Godot/prefab/ui/MapEditorTools.tscn b/DungeonShooting_Godot/prefab/ui/MapEditorTools.tscn
new file mode 100644
index 0000000..e85f8cc
--- /dev/null
+++ b/DungeonShooting_Godot/prefab/ui/MapEditorTools.tscn
@@ -0,0 +1,49 @@
+[gd_scene load_steps=3 format=3 uid="uid://b4u66mxndxbrg"]
+
+[ext_resource type="Script" path="res://src/game/ui/mapEditorTools/MapEditorToolsPanel.cs" id="1_mqp1c"]
+[ext_resource type="Texture2D" uid="uid://uhhfgdhpk7i4" path="res://icon.png" id="2_rwvbg"]
+
+[node name="MapEditorTools" type="Control"]
+layout_mode = 3
+anchors_preset = 15
+anchor_right = 1.0
+anchor_bottom = 1.0
+grow_horizontal = 2
+grow_vertical = 2
+script = ExtResource("1_mqp1c")
+
+[node name="HBoxContainer" type="HBoxContainer" parent="."]
+layout_mode = 1
+anchors_preset = 1
+anchor_left = 1.0
+anchor_right = 1.0
+offset_left = -288.0
+offset_top = 19.0
+offset_right = -20.0
+offset_bottom = 83.0
+grow_horizontal = 0
+mouse_filter = 0
+
+[node name="TextureButton" type="TextureButton" parent="HBoxContainer"]
+layout_mode = 2
+texture_normal = ExtResource("2_rwvbg")
+texture_pressed = ExtResource("2_rwvbg")
+texture_hover = ExtResource("2_rwvbg")
+
+[node name="TextureButton2" type="TextureButton" parent="HBoxContainer"]
+layout_mode = 2
+texture_normal = ExtResource("2_rwvbg")
+texture_pressed = ExtResource("2_rwvbg")
+texture_hover = ExtResource("2_rwvbg")
+
+[node name="TextureButton3" type="TextureButton" parent="HBoxContainer"]
+layout_mode = 2
+texture_normal = ExtResource("2_rwvbg")
+texture_pressed = ExtResource("2_rwvbg")
+texture_hover = ExtResource("2_rwvbg")
+
+[node name="TextureButton4" type="TextureButton" parent="HBoxContainer"]
+layout_mode = 2
+texture_normal = ExtResource("2_rwvbg")
+texture_pressed = ExtResource("2_rwvbg")
+texture_hover = ExtResource("2_rwvbg")
diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import
index b20c9a6..c36be94 100644
--- a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import
+++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import
@@ -3,15 +3,15 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://chd2vtesap5cf"
-path="res://.godot/imported/enemy0001.png-1247a3ddf8a1a163d812cad12c4340fd.ctex"
+path="res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex"
metadata={
"vram_texture": false
}
[deps]
-source_file="res://resource/sprite/role/enemy0001/enemy0001.png"
-dest_files=["res://.godot/imported/enemy0001.png-1247a3ddf8a1a163d812cad12c4340fd.ctex"]
+source_file="res://resource/sprite/role/enemy0001/Enemy0001.png"
+dest_files=["res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex"]
[params]
diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import
index 56388a2..d563acf 100644
--- a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import
+++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import
@@ -3,15 +3,15 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://d2f55lu60x64i"
-path="res://.godot/imported/enemy0001_Debris.png-297a2fb6680cb862a9a085cf58f8268c.ctex"
+path="res://.godot/imported/Enemy0001_Debris.png-ac416dc79cd3c1217b27e1ef1fbe0d0b.ctex"
metadata={
"vram_texture": false
}
[deps]
-source_file="res://resource/sprite/role/enemy0001/enemy0001_Debris.png"
-dest_files=["res://.godot/imported/enemy0001_Debris.png-297a2fb6680cb862a9a085cf58f8268c.ctex"]
+source_file="res://resource/sprite/role/enemy0001/Enemy0001_Debris.png"
+dest_files=["res://.godot/imported/Enemy0001_Debris.png-ac416dc79cd3c1217b27e1ef1fbe0d0b.ctex"]
[params]
diff --git a/DungeonShooting_Godot/resource/theme/mainTheme.tres b/DungeonShooting_Godot/resource/theme/mainTheme.tres
index 0627eb5..3cf5a71 100644
--- a/DungeonShooting_Godot/resource/theme/mainTheme.tres
+++ b/DungeonShooting_Godot/resource/theme/mainTheme.tres
@@ -352,7 +352,7 @@
[sub_resource type="ImageTexture" id="58"]
-[sub_resource type="Image" id="Image_2ril5"]
+[sub_resource type="Image" id="Image_2evuq"]
data = {
"data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 1, 255, 255, 255, 39, 255, 255, 255, 67, 255, 255, 255, 67, 255, 255, 255, 39, 255, 255, 255, 1, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 39, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 39, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 66, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 66, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 66, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 66, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 39, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 75, 255, 255, 255, 39, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 1, 255, 255, 255, 39, 255, 255, 255, 67, 255, 255, 255, 67, 255, 255, 255, 39, 255, 255, 255, 1, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
"format": "RGBA8",
@@ -362,7 +362,7 @@
}
[sub_resource type="ImageTexture" id="60"]
-image = SubResource("Image_2ril5")
+image = SubResource("Image_2evuq")
[sub_resource type="StyleBoxTexture" id="61"]
content_margin_left = 2.0
@@ -372,7 +372,7 @@
texture = SubResource("60")
region_rect = Rect2(0, 0, 12, 12)
-[sub_resource type="Image" id="Image_05i4u"]
+[sub_resource type="Image" id="Image_rgwcq"]
data = {
"data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 247, 247, 247, 0, 248, 248, 248, 0, 248, 248, 248, 0, 247, 247, 247, 0, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 191, 191, 191, 4, 247, 247, 247, 98, 248, 248, 248, 167, 248, 248, 248, 167, 247, 247, 247, 98, 191, 191, 191, 4, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 247, 247, 247, 0, 247, 247, 247, 97, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 247, 247, 247, 97, 247, 247, 247, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 248, 248, 248, 0, 248, 248, 248, 164, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 164, 248, 248, 248, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 248, 248, 248, 0, 248, 248, 248, 164, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 164, 248, 248, 248, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 247, 247, 247, 0, 247, 247, 247, 97, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 248, 248, 248, 186, 247, 247, 247, 97, 247, 247, 247, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 191, 191, 191, 4, 247, 247, 247, 98, 248, 248, 248, 167, 248, 248, 248, 167, 247, 247, 247, 98, 191, 191, 191, 4, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 191, 191, 191, 0, 247, 247, 247, 0, 248, 248, 248, 0, 248, 248, 248, 0, 247, 247, 247, 0, 191, 191, 191, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
"format": "RGBA8",
@@ -382,7 +382,7 @@
}
[sub_resource type="ImageTexture" id="63"]
-image = SubResource("Image_05i4u")
+image = SubResource("Image_rgwcq")
[sub_resource type="StyleBoxTexture" id="64"]
content_margin_left = 2.0
@@ -392,7 +392,7 @@
texture = SubResource("63")
region_rect = Rect2(0, 0, 12, 12)
-[sub_resource type="Image" id="Image_xvqdk"]
+[sub_resource type="Image" id="Image_rsy3d"]
data = {
"data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 127, 127, 127, 4, 173, 173, 173, 97, 173, 173, 173, 166, 173, 173, 173, 166, 173, 173, 173, 97, 127, 127, 127, 4, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172, 172, 172, 0, 172, 172, 172, 96, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 172, 172, 172, 96, 172, 172, 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, 173, 173, 0, 173, 173, 173, 163, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 163, 173, 173, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, 173, 173, 0, 173, 173, 173, 163, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 163, 173, 173, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172, 172, 172, 0, 172, 172, 172, 96, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 173, 173, 173, 185, 172, 172, 172, 96, 172, 172, 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 127, 127, 127, 4, 173, 173, 173, 97, 173, 173, 173, 166, 173, 173, 173, 166, 173, 173, 173, 97, 127, 127, 127, 4, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, 127, 127, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 173, 173, 173, 0, 127, 127, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
"format": "RGBA8",
@@ -402,7 +402,7 @@
}
[sub_resource type="ImageTexture" id="66"]
-image = SubResource("Image_xvqdk")
+image = SubResource("Image_rsy3d")
[sub_resource type="StyleBoxTexture" id="67"]
content_margin_left = 2.0
@@ -412,7 +412,7 @@
texture = SubResource("66")
region_rect = Rect2(0, 0, 12, 12)
-[sub_resource type="Image" id="Image_306kn"]
+[sub_resource type="Image" id="Image_flfsw"]
data = {
"data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 4, 255, 255, 255, 16, 255, 255, 255, 16, 255, 255, 255, 4, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 16, 255, 255, 255, 21, 255, 255, 255, 21, 255, 255, 255, 16, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 16, 255, 255, 255, 21, 255, 255, 255, 21, 255, 255, 255, 16, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 4, 255, 255, 255, 16, 255, 255, 255, 16, 255, 255, 255, 4, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
"format": "RGBA8",
@@ -422,7 +422,7 @@
}
[sub_resource type="ImageTexture" id="69"]
-image = SubResource("Image_306kn")
+image = SubResource("Image_flfsw")
[sub_resource type="StyleBoxTexture" id="70"]
content_margin_left = 0.0
@@ -446,7 +446,7 @@
content_margin_right = 4.0
content_margin_bottom = 4.0
-[sub_resource type="Image" id="Image_7wlgg"]
+[sub_resource type="Image" id="Image_5lwa8"]
data = {
"data": PackedByteArray(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 228, 255, 255, 255, 188, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 228, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 18, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 187, 255, 255, 255, 17, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 187, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 18, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 17, 255, 255, 255, 17, 255, 255, 255, 186, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 190, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 185, 255, 255, 255, 229, 255, 255, 255, 189, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 191, 255, 255, 255, 229, 255, 255, 255, 229, 255, 255, 255, 190, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 187, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 187, 255, 255, 255, 229, 255, 255, 255, 188, 255, 255, 255, 18, 255, 255, 255, 19, 255, 255, 255, 188, 255, 255, 255, 229, 255, 255, 255, 186, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 17, 255, 255, 255, 185, 255, 255, 255, 229, 255, 255, 255, 189, 255, 255, 255, 19, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 189, 255, 255, 255, 229, 255, 255, 255, 185, 255, 255, 255, 17, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 76, 255, 255, 255, 229, 255, 255, 255, 190, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 190, 255, 255, 255, 229, 255, 255, 255, 76, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 77, 255, 255, 255, 19, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 19, 255, 255, 255, 77, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
"format": "RGBA8",
@@ -456,7 +456,7 @@
}
[sub_resource type="ImageTexture" id="56"]
-image = SubResource("Image_7wlgg")
+image = SubResource("Image_5lwa8")
[sub_resource type="StyleBoxFlat" id="57"]
content_margin_left = 6.0
diff --git a/DungeonShooting_Godot/src/framework/generator/UiGenerator.cs b/DungeonShooting_Godot/src/framework/generator/UiGenerator.cs
index 46889c6..10f5671 100644
--- a/DungeonShooting_Godot/src/framework/generator/UiGenerator.cs
+++ b/DungeonShooting_Godot/src/framework/generator/UiGenerator.cs
@@ -179,11 +179,11 @@
return retraction + $"/// \n" +
retraction + $"/// 类型: , 路径: {parent}{uiNodeInfo.OriginName}\n" +
retraction + $"/// \n" +
- retraction + $"public class {uiNodeInfo.ClassName} : IUiNode<{uiNodeInfo.NodeTypeName}, {uiNodeInfo.ClassName}>\n" +
+ retraction + $"public class {uiNodeInfo.ClassName} : UiNode<{uiNodeInfo.UiRootName}, {uiNodeInfo.NodeTypeName}, {uiNodeInfo.ClassName}>\n" +
retraction + $"{{\n" +
GeneratePropertyListClassCode("Instance.", parent, uiNodeInfo, retraction + " ") +
- retraction + $" public {uiNodeInfo.ClassName}({uiNodeInfo.NodeTypeName} node) : base(node) {{ }}\n" +
- retraction + $" public override {uiNodeInfo.ClassName} Clone() => new (({uiNodeInfo.NodeTypeName})Instance.Duplicate());\n" +
+ retraction + $" public {uiNodeInfo.ClassName}({uiNodeInfo.UiRootName} uiPanel, {uiNodeInfo.NodeTypeName} node) : base(uiPanel, node) {{ }}\n" +
+ retraction + $" public override {uiNodeInfo.ClassName} Clone() => new (UiPanel, ({uiNodeInfo.NodeTypeName})Instance.Duplicate());\n" +
retraction + $"}}\n\n";
}
@@ -204,6 +204,15 @@
private static string GeneratePropertyCode(string target, string parent, UiNodeInfo uiNodeInfo, string retraction)
{
+ string uiPanel;
+ if (string.IsNullOrEmpty(target))
+ {
+ uiPanel = "this";
+ }
+ else
+ {
+ uiPanel = "UiPanel";
+ }
return retraction + $"/// \n" +
retraction + $"/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: {parent}{uiNodeInfo.OriginName}\n" +
retraction + $"/// \n" +
@@ -211,7 +220,7 @@
retraction + $"{{\n" +
retraction + $" get\n" +
retraction + $" {{\n" +
- retraction + $" if (_{uiNodeInfo.Name} == null) _{uiNodeInfo.Name} = new {uiNodeInfo.ClassName}({target}GetNodeOrNull<{uiNodeInfo.NodeTypeName}>(\"{uiNodeInfo.OriginName}\"));\n" +
+ retraction + $" if (_{uiNodeInfo.Name} == null) _{uiNodeInfo.Name} = new {uiNodeInfo.ClassName}({uiPanel}, {target}GetNodeOrNull<{uiNodeInfo.NodeTypeName}>(\"{uiNodeInfo.OriginName}\"));\n" +
retraction + $" return _{uiNodeInfo.Name};\n" +
retraction + $" }}\n" +
retraction + $"}}\n" +
diff --git a/DungeonShooting_Godot/src/framework/ui/IUiNode.cs b/DungeonShooting_Godot/src/framework/ui/IUiNode.cs
deleted file mode 100644
index 7e20a13..0000000
--- a/DungeonShooting_Godot/src/framework/ui/IUiNode.cs
+++ /dev/null
@@ -1,47 +0,0 @@
-
-using Godot;
-
-///
-/// Ui节点代码接口
-///
-/// Godot中的节点类型
-/// 克隆该对象返回的类型
-public abstract class IUiNode : IClone where TNodeType : Node
-{
- ///
- /// Godot节点实例
- ///
- public TNodeType Instance { get; }
- ///
- /// 克隆当前对象, 并返回新的对象,
- /// 注意: 如果子节点改名或者移动层级, 那么有可能对导致属性中的子节点无法访问
- ///
- public abstract TCloneType Clone();
-
- public IUiNode(TNodeType node)
- {
- Instance = node;
- }
-
- ///
- /// 嵌套打开子ui
- ///
- public UiBase OpenNestedUi(string uiName)
- {
- var packedScene = ResourceManager.Load("res://" + GameConfig.UiPrefabDir + uiName + ".tscn");
- var uiBase = packedScene.Instantiate();
- Instance.AddChild(uiBase);
-
- uiBase.OnCreateUi();
- uiBase.ShowUi();
- return uiBase;
- }
-
- ///
- /// 嵌套打开子ui
- ///
- public T OpenNestedUi(string uiName) where T : UiBase
- {
- return (T)OpenNestedUi(uiName);
- }
-}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/src/framework/ui/UiBase.cs b/DungeonShooting_Godot/src/framework/ui/UiBase.cs
index 01bc2a8..15115e6 100644
--- a/DungeonShooting_Godot/src/framework/ui/UiBase.cs
+++ b/DungeonShooting_Godot/src/framework/ui/UiBase.cs
@@ -44,7 +44,11 @@
//开启的协程
private List _coroutineList;
-
+ //嵌套打开的Ui列表
+ private HashSet _nestedUiSet;
+ //所属父级Ui, UiNode.RecordNestedUi() 嵌套打开的 Ui 将被赋予此值
+ private UiBase _targetUi;
+
public UiBase(string uiName)
{
UiName = uiName;
@@ -96,6 +100,15 @@
IsOpen = true;
Visible = true;
OnShowUi();
+
+ //子Ui调用显示
+ if (_nestedUiSet != null)
+ {
+ foreach (var uiBase in _nestedUiSet)
+ {
+ uiBase.ShowUi();
+ }
+ }
}
///
@@ -111,6 +124,15 @@
IsOpen = false;
Visible = false;
OnHideUi();
+
+ //子Ui调用隐藏
+ if (_nestedUiSet != null)
+ {
+ foreach (var uiBase in _nestedUiSet)
+ {
+ uiBase.HideUi();
+ }
+ }
}
///
@@ -127,6 +149,16 @@
HideUi();
IsDisposed = true;
OnDisposeUi();
+
+ //子Ui调用销毁
+ if (_nestedUiSet != null)
+ {
+ foreach (var uiBase in _nestedUiSet)
+ {
+ uiBase.DisposeUi();
+ }
+ }
+
QueueFree();
}
@@ -143,6 +175,46 @@
}
///
+ /// 记录嵌套打开/关闭的UI
+ ///
+ public void RecordNestedUi(UiBase uiBase, UiManager.RecordType type)
+ {
+ if (type == UiManager.RecordType.Open)
+ {
+ if (uiBase._targetUi != null && uiBase._targetUi != this)
+ {
+ GD.PrintErr($"子Ui:'{uiBase.UiName}'已经被其他Ui:'{uiBase._targetUi.UiName}'嵌套打开!");
+ uiBase._targetUi.RecordNestedUi(uiBase, UiManager.RecordType.Close);
+ }
+ if (_nestedUiSet == null)
+ {
+ _nestedUiSet = new HashSet();
+ }
+
+ uiBase._targetUi = this;
+ _nestedUiSet.Add(uiBase);
+ }
+ else
+ {
+ if (uiBase._targetUi == this)
+ {
+ uiBase._targetUi = null;
+ }
+ else
+ {
+ GD.PrintErr($"当前Ui:'{UiName}'没有嵌套打开子Ui:'{uiBase.UiName}'!");
+ return;
+ }
+
+ if (_nestedUiSet == null)
+ {
+ return;
+ }
+ _nestedUiSet.Remove(uiBase);
+ }
+ }
+
+ ///
/// 开启一个协程, 返回协程 id, 协程是在普通帧执行的, 支持: 协程嵌套, WaitForSeconds, WaitForFixedProcess, Task, SignalAwaiter
///
public long StartCoroutine(IEnumerator able)
diff --git a/DungeonShooting_Godot/src/framework/ui/UiNode.cs b/DungeonShooting_Godot/src/framework/ui/UiNode.cs
new file mode 100644
index 0000000..bfa30e2
--- /dev/null
+++ b/DungeonShooting_Godot/src/framework/ui/UiNode.cs
@@ -0,0 +1,75 @@
+
+using Godot;
+
+///
+/// Ui节点父类, 无泛型无属性
+///
+public abstract class UiNode
+{
+}
+
+///
+/// Ui节点父类
+///
+/// 所属Ui面板类型
+/// Godot中的节点类型
+/// 克隆该对象返回的类型
+public abstract class UiNode
+ : UiNode, IUiCellNode, IClone
+ where TUi : UiBase
+ where TNodeType : Node
+ where TCloneType : IUiCellNode
+{
+ ///
+ /// 当前Ui节点所属的Ui面板对象
+ ///
+ public TUi UiPanel { get; }
+ ///
+ /// Godot节点实例
+ ///
+ public TNodeType Instance { get; }
+ ///
+ /// 克隆当前对象, 并返回新的对象,
+ /// 注意: 如果子节点改名或者移动层级, 那么有可能对导致属性中的子节点无法访问
+ ///
+ public abstract TCloneType Clone();
+
+ public UiNode(TUi uiPanel, TNodeType node)
+ {
+ UiPanel = uiPanel;
+ Instance = node;
+ }
+
+ ///
+ /// 嵌套打开子ui
+ ///
+ public UiBase OpenNestedUi(string uiName)
+ {
+ var packedScene = ResourceManager.Load("res://" + GameConfig.UiPrefabDir + uiName + ".tscn");
+ var uiBase = packedScene.Instantiate();
+ Instance.AddChild(uiBase);
+ UiPanel.RecordNestedUi(uiBase, UiManager.RecordType.Open);
+
+ uiBase.OnCreateUi();
+ uiBase.ShowUi();
+ return uiBase;
+ }
+
+ ///
+ /// 嵌套打开子ui
+ ///
+ public T OpenNestedUi(string uiName) where T : UiBase
+ {
+ return (T)OpenNestedUi(uiName);
+ }
+
+ public Node GetUiInstance()
+ {
+ return Instance;
+ }
+
+ public IUiCellNode CloneUiCell()
+ {
+ return Clone();
+ }
+}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/src/framework/ui/grid/IUiCellNode.cs b/DungeonShooting_Godot/src/framework/ui/grid/IUiCellNode.cs
new file mode 100644
index 0000000..20e16e7
--- /dev/null
+++ b/DungeonShooting_Godot/src/framework/ui/grid/IUiCellNode.cs
@@ -0,0 +1,18 @@
+
+using Godot;
+
+///
+/// 用于网格中的cell对象
+///
+public interface IUiCellNode
+{
+ ///
+ /// 获取节点实例
+ ///
+ Node GetUiInstance();
+
+ ///
+ /// 克隆并返回新的节点实例
+ ///
+ IUiCellNode CloneUiCell();
+}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/src/framework/ui/grid/UiCell.cs b/DungeonShooting_Godot/src/framework/ui/grid/UiCell.cs
index 2870ffa..f3de805 100644
--- a/DungeonShooting_Godot/src/framework/ui/grid/UiCell.cs
+++ b/DungeonShooting_Godot/src/framework/ui/grid/UiCell.cs
@@ -1,12 +1,12 @@
using Godot;
-public abstract class UiCell : IDestroy where TNodeType : Node where TUiNodeType : IUiNode
+public abstract class UiCell : IDestroy where TUiCellNode : IUiCellNode
{
public bool IsDestroyed { get; private set; }
- public UiGrid Grid { get; set; }
- public TUiNodeType CellNode { get; set; }
+ public UiGrid Grid { get; set; }
+ public TUiCellNode CellNode { get; set; }
public T Data { get; set; }
public virtual void OnInit()
diff --git a/DungeonShooting_Godot/src/framework/ui/grid/UiGrid.cs b/DungeonShooting_Godot/src/framework/ui/grid/UiGrid.cs
index 925b4e2..d1398af 100644
--- a/DungeonShooting_Godot/src/framework/ui/grid/UiGrid.cs
+++ b/DungeonShooting_Godot/src/framework/ui/grid/UiGrid.cs
@@ -10,21 +10,22 @@
/// 原生Godot类型
/// Ui节点类型
/// 传给Cell的数据类型
-public partial class UiGrid : GridContainer, IDestroy where TNodeType : Node where TUiNodeType : IUiNode
+public partial class UiGrid : GridContainer, IDestroy where TUiCellNode : IUiCellNode
{
public bool IsDestroyed { get; private set; }
- private TUiNodeType _template;
+ private TUiCellNode _template;
private Node _parent;
private Type _cellType;
- private Stack> _cellPool = new Stack>();
- private List> _cellList = new List>();
+ private Stack> _cellPool = new Stack>();
+ private List> _cellList = new List>();
- public UiGrid(TUiNodeType template, Type cellType, int columns, int offsetX, int offsetY)
+ public UiGrid(TUiCellNode template, Type cellType, int columns, int offsetX, int offsetY)
{
_template = template;
_cellType = cellType;
- _parent = _template.Instance.GetParent();
- _parent.RemoveChild(_template.Instance);
+ var uiInstance = _template.GetUiInstance();
+ _parent = uiInstance.GetParent();
+ _parent.RemoveChild(uiInstance);
_parent.AddChild(this);
Columns = columns;
AddThemeConstantOverride("h_separation", offsetX);
@@ -33,7 +34,7 @@
public override void _Ready()
{
- if (_template.Instance is Control control)
+ if (_template.GetUiInstance() is Control control)
{
Position = control.Position;
}
@@ -47,7 +48,7 @@
{
var cell = GetCellInstance();
_cellList.Add(cell);
- AddChild(cell.CellNode.Instance);
+ AddChild(cell.CellNode.GetUiInstance());
} while (array.Length > _cellList.Count);
}
else if(array.Length < _cellList.Count)
@@ -71,7 +72,7 @@
{
var cell = GetCellInstance();
_cellList.Add(cell);
- AddChild(cell.CellNode.Instance);
+ AddChild(cell.CellNode.GetUiInstance());
cell.OnSetData(data);
}
@@ -96,27 +97,27 @@
_cellPool = null;
}
- private UiCell GetCellInstance()
+ private UiCell GetCellInstance()
{
if (_cellPool.Count > 0)
{
return _cellPool.Pop();
}
- var uiCell = Activator.CreateInstance(_cellType) as UiCell;
+ var uiCell = Activator.CreateInstance(_cellType) as UiCell;
if (uiCell is null)
{
- throw new Exception($"cellType 无法转为'{typeof(UiCell).FullName}'类型!");
+ throw new Exception($"cellType 无法转为'{typeof(UiCell).FullName}'类型!");
}
- uiCell.CellNode = _template.Clone();
+ uiCell.CellNode = (TUiCellNode)_template.CloneUiCell();
uiCell.Grid = this;
uiCell.OnInit();
return uiCell;
}
- private void ReclaimCellInstance(UiCell cell)
+ private void ReclaimCellInstance(UiCell cell)
{
- RemoveChild(cell.CellNode.Instance);
+ RemoveChild(cell.CellNode.GetUiInstance());
_cellPool.Push(cell);
}
}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs
index f0c3b89..13f88aa 100644
--- a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs
+++ b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs
@@ -52,6 +52,7 @@
public const string prefab_ui_Loading_tscn = "res://prefab/ui/Loading.tscn";
public const string prefab_ui_Main_tscn = "res://prefab/ui/Main.tscn";
public const string prefab_ui_MapEditor_tscn = "res://prefab/ui/MapEditor.tscn";
+ public const string prefab_ui_MapEditorTools_tscn = "res://prefab/ui/MapEditorTools.tscn";
public const string prefab_ui_RoomUI_tscn = "res://prefab/ui/RoomUI.tscn";
public const string prefab_ui_Settlement_tscn = "res://prefab/ui/Settlement.tscn";
public const string prefab_weapon_Weapon0001_tscn = "res://prefab/weapon/Weapon0001.tscn";
diff --git a/DungeonShooting_Godot/src/game/manager/UiManager_Methods.cs b/DungeonShooting_Godot/src/game/manager/UiManager_Methods.cs
index 2a86882..f67ed67 100644
--- a/DungeonShooting_Godot/src/game/manager/UiManager_Methods.cs
+++ b/DungeonShooting_Godot/src/game/manager/UiManager_Methods.cs
@@ -11,6 +11,7 @@
public const string Loading = "Loading";
public const string Main = "Main";
public const string MapEditor = "MapEditor";
+ public const string MapEditorTools = "MapEditorTools";
public const string RoomUI = "RoomUI";
public const string Settlement = "Settlement";
}
@@ -216,6 +217,46 @@
}
///
+ /// 打开 MapEditorTools, 并返回UI实例
+ ///
+ public static UI.MapEditorTools.MapEditorToolsPanel Open_MapEditorTools()
+ {
+ return OpenUi(UiName.MapEditorTools);
+ }
+
+ ///
+ /// 隐藏 MapEditorTools 的所有实例
+ ///
+ public static void Hide_MapEditorTools()
+ {
+ var uiInstance = Get_MapEditorTools_Instance();
+ foreach (var uiPanel in uiInstance)
+ {
+ uiPanel.HideUi();
+ }
+ }
+
+ ///
+ /// 销毁 MapEditorTools 的所有实例
+ ///
+ public static void Dispose_MapEditorTools()
+ {
+ var uiInstance = Get_MapEditorTools_Instance();
+ foreach (var uiPanel in uiInstance)
+ {
+ uiPanel.DisposeUi();
+ }
+ }
+
+ ///
+ /// 获取所有 MapEditorTools 的实例, 如果没有实例, 则返回一个空数组
+ ///
+ public static UI.MapEditorTools.MapEditorToolsPanel[] Get_MapEditorTools_Instance()
+ {
+ return GetUiInstance(nameof(UI.MapEditorTools.MapEditorTools));
+ }
+
+ ///
/// 打开 RoomUI, 并返回UI实例
///
public static UI.RoomUI.RoomUIPanel Open_RoomUI()
diff --git a/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTips.cs b/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTips.cs
index c345195..5900940 100644
--- a/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTips.cs
+++ b/DungeonShooting_Godot/src/game/ui/bottomTips/BottomTips.cs
@@ -12,7 +12,7 @@
{
get
{
- if (_L_Panel == null) _L_Panel = new BottomTips_Panel(GetNodeOrNull("Panel"));
+ if (_L_Panel == null) _L_Panel = new BottomTips_Panel(this, GetNodeOrNull("Panel"));
return _L_Panel;
}
}
@@ -26,16 +26,16 @@
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer.CenterContainer.HBoxContainer.AspectRatioContainer.TextureRect
///
- public class BottomTips_TextureRect : IUiNode
+ public class BottomTips_TextureRect : UiNode
{
- public BottomTips_TextureRect(Godot.TextureRect node) : base(node) { }
- public override BottomTips_TextureRect Clone() => new ((Godot.TextureRect)Instance.Duplicate());
+ public BottomTips_TextureRect(BottomTips uiPanel, Godot.TextureRect node) : base(uiPanel, node) { }
+ public override BottomTips_TextureRect Clone() => new (UiPanel, (Godot.TextureRect)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer.CenterContainer.HBoxContainer.AspectRatioContainer
///
- public class BottomTips_AspectRatioContainer : IUiNode
+ public class BottomTips_AspectRatioContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: BottomTips.Panel.MarginContainer.CenterContainer.HBoxContainer.TextureRect
@@ -44,29 +44,29 @@
{
get
{
- if (_L_TextureRect == null) _L_TextureRect = new BottomTips_TextureRect(Instance.GetNodeOrNull("TextureRect"));
+ if (_L_TextureRect == null) _L_TextureRect = new BottomTips_TextureRect(UiPanel, Instance.GetNodeOrNull("TextureRect"));
return _L_TextureRect;
}
}
private BottomTips_TextureRect _L_TextureRect;
- public BottomTips_AspectRatioContainer(Godot.AspectRatioContainer node) : base(node) { }
- public override BottomTips_AspectRatioContainer Clone() => new ((Godot.AspectRatioContainer)Instance.Duplicate());
+ public BottomTips_AspectRatioContainer(BottomTips uiPanel, Godot.AspectRatioContainer node) : base(uiPanel, node) { }
+ public override BottomTips_AspectRatioContainer Clone() => new (UiPanel, (Godot.AspectRatioContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer.CenterContainer.HBoxContainer.Label
///
- public class BottomTips_Label : IUiNode
+ public class BottomTips_Label : UiNode
{
- public BottomTips_Label(Godot.Label node) : base(node) { }
- public override BottomTips_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public BottomTips_Label(BottomTips uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override BottomTips_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer.CenterContainer.HBoxContainer
///
- public class BottomTips_HBoxContainer : IUiNode
+ public class BottomTips_HBoxContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: BottomTips.Panel.MarginContainer.CenterContainer.AspectRatioContainer
@@ -75,7 +75,7 @@
{
get
{
- if (_L_AspectRatioContainer == null) _L_AspectRatioContainer = new BottomTips_AspectRatioContainer(Instance.GetNodeOrNull("AspectRatioContainer"));
+ if (_L_AspectRatioContainer == null) _L_AspectRatioContainer = new BottomTips_AspectRatioContainer(UiPanel, Instance.GetNodeOrNull("AspectRatioContainer"));
return _L_AspectRatioContainer;
}
}
@@ -88,20 +88,20 @@
{
get
{
- if (_L_Label == null) _L_Label = new BottomTips_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new BottomTips_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
private BottomTips_Label _L_Label;
- public BottomTips_HBoxContainer(Godot.HBoxContainer node) : base(node) { }
- public override BottomTips_HBoxContainer Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public BottomTips_HBoxContainer(BottomTips uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override BottomTips_HBoxContainer Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer.CenterContainer
///
- public class BottomTips_CenterContainer : IUiNode
+ public class BottomTips_CenterContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: BottomTips.Panel.MarginContainer.HBoxContainer
@@ -110,20 +110,20 @@
{
get
{
- if (_L_HBoxContainer == null) _L_HBoxContainer = new BottomTips_HBoxContainer(Instance.GetNodeOrNull("HBoxContainer"));
+ if (_L_HBoxContainer == null) _L_HBoxContainer = new BottomTips_HBoxContainer(UiPanel, Instance.GetNodeOrNull("HBoxContainer"));
return _L_HBoxContainer;
}
}
private BottomTips_HBoxContainer _L_HBoxContainer;
- public BottomTips_CenterContainer(Godot.CenterContainer node) : base(node) { }
- public override BottomTips_CenterContainer Clone() => new ((Godot.CenterContainer)Instance.Duplicate());
+ public BottomTips_CenterContainer(BottomTips uiPanel, Godot.CenterContainer node) : base(uiPanel, node) { }
+ public override BottomTips_CenterContainer Clone() => new (UiPanel, (Godot.CenterContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel.MarginContainer
///
- public class BottomTips_MarginContainer : IUiNode
+ public class BottomTips_MarginContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: BottomTips.Panel.CenterContainer
@@ -132,20 +132,20 @@
{
get
{
- if (_L_CenterContainer == null) _L_CenterContainer = new BottomTips_CenterContainer(Instance.GetNodeOrNull("CenterContainer"));
+ if (_L_CenterContainer == null) _L_CenterContainer = new BottomTips_CenterContainer(UiPanel, Instance.GetNodeOrNull("CenterContainer"));
return _L_CenterContainer;
}
}
private BottomTips_CenterContainer _L_CenterContainer;
- public BottomTips_MarginContainer(Godot.MarginContainer node) : base(node) { }
- public override BottomTips_MarginContainer Clone() => new ((Godot.MarginContainer)Instance.Duplicate());
+ public BottomTips_MarginContainer(BottomTips uiPanel, Godot.MarginContainer node) : base(uiPanel, node) { }
+ public override BottomTips_MarginContainer Clone() => new (UiPanel, (Godot.MarginContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: BottomTips.Panel
///
- public class BottomTips_Panel : IUiNode
+ public class BottomTips_Panel : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: BottomTips.MarginContainer
@@ -154,14 +154,14 @@
{
get
{
- if (_L_MarginContainer == null) _L_MarginContainer = new BottomTips_MarginContainer(Instance.GetNodeOrNull("MarginContainer"));
+ if (_L_MarginContainer == null) _L_MarginContainer = new BottomTips_MarginContainer(UiPanel, Instance.GetNodeOrNull("MarginContainer"));
return _L_MarginContainer;
}
}
private BottomTips_MarginContainer _L_MarginContainer;
- public BottomTips_Panel(Godot.PanelContainer node) : base(node) { }
- public override BottomTips_Panel Clone() => new ((Godot.PanelContainer)Instance.Duplicate());
+ public BottomTips_Panel(BottomTips uiPanel, Godot.PanelContainer node) : base(uiPanel, node) { }
+ public override BottomTips_Panel Clone() => new (UiPanel, (Godot.PanelContainer)Instance.Duplicate());
}
diff --git a/DungeonShooting_Godot/src/game/ui/editorTools/EditorTools.cs b/DungeonShooting_Godot/src/game/ui/editorTools/EditorTools.cs
index c385304..d925d03 100644
--- a/DungeonShooting_Godot/src/game/ui/editorTools/EditorTools.cs
+++ b/DungeonShooting_Godot/src/game/ui/editorTools/EditorTools.cs
@@ -12,7 +12,7 @@
{
get
{
- if (_L_ScrollContainer == null) _L_ScrollContainer = new EditorTools_ScrollContainer(GetNodeOrNull("ScrollContainer"));
+ if (_L_ScrollContainer == null) _L_ScrollContainer = new EditorTools_ScrollContainer(this, GetNodeOrNull("ScrollContainer"));
return _L_ScrollContainer;
}
}
@@ -25,7 +25,7 @@
{
get
{
- if (_L_Confirm == null) _L_Confirm = new EditorTools_Confirm(GetNodeOrNull("Confirm"));
+ if (_L_Confirm == null) _L_Confirm = new EditorTools_Confirm(this, GetNodeOrNull("Confirm"));
return _L_Confirm;
}
}
@@ -38,7 +38,7 @@
{
get
{
- if (_L_Tips == null) _L_Tips = new EditorTools_Tips(GetNodeOrNull("Tips"));
+ if (_L_Tips == null) _L_Tips = new EditorTools_Tips(this, GetNodeOrNull("Tips"));
return _L_Tips;
}
}
@@ -52,25 +52,25 @@
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer.Label
///
- public class EditorTools_Label : IUiNode
+ public class EditorTools_Label : UiNode
{
- public EditorTools_Label(Godot.Label node) : base(node) { }
- public override EditorTools_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer.Button
///
- public class EditorTools_Button : IUiNode
+ public class EditorTools_Button : UiNode
{
- public EditorTools_Button(Godot.Button node) : base(node) { }
- public override EditorTools_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer
///
- public class EditorTools_HBoxContainer : IUiNode
+ public class EditorTools_HBoxContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -79,7 +79,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -92,47 +92,47 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools_Button _L_Button;
- public EditorTools_HBoxContainer(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer3.Label
///
- public class EditorTools1_Label : IUiNode
+ public class EditorTools1_Label : UiNode
{
- public EditorTools1_Label(Godot.Label node) : base(node) { }
- public override EditorTools1_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools1_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools1_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer3.LineEdit
///
- public class EditorTools_LineEdit : IUiNode
+ public class EditorTools_LineEdit : UiNode
{
- public EditorTools_LineEdit(Godot.LineEdit node) : base(node) { }
- public override EditorTools_LineEdit Clone() => new ((Godot.LineEdit)Instance.Duplicate());
+ public EditorTools_LineEdit(EditorTools uiPanel, Godot.LineEdit node) : base(uiPanel, node) { }
+ public override EditorTools_LineEdit Clone() => new (UiPanel, (Godot.LineEdit)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer3.Button
///
- public class EditorTools1_Button : IUiNode
+ public class EditorTools1_Button : UiNode
{
- public EditorTools1_Button(Godot.Button node) : base(node) { }
- public override EditorTools1_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools1_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools1_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer3
///
- public class EditorTools_HBoxContainer3 : IUiNode
+ public class EditorTools_HBoxContainer3 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -141,7 +141,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools1_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools1_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -154,7 +154,7 @@
{
get
{
- if (_L_LineEdit == null) _L_LineEdit = new EditorTools_LineEdit(Instance.GetNodeOrNull("LineEdit"));
+ if (_L_LineEdit == null) _L_LineEdit = new EditorTools_LineEdit(UiPanel, Instance.GetNodeOrNull("LineEdit"));
return _L_LineEdit;
}
}
@@ -167,38 +167,38 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools1_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools1_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools1_Button _L_Button;
- public EditorTools_HBoxContainer3(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer3 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer3(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer3 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer4.Label
///
- public class EditorTools2_Label : IUiNode
+ public class EditorTools2_Label : UiNode
{
- public EditorTools2_Label(Godot.Label node) : base(node) { }
- public override EditorTools2_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools2_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools2_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer4.Button
///
- public class EditorTools2_Button : IUiNode
+ public class EditorTools2_Button : UiNode
{
- public EditorTools2_Button(Godot.Button node) : base(node) { }
- public override EditorTools2_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools2_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools2_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer4
///
- public class EditorTools_HBoxContainer4 : IUiNode
+ public class EditorTools_HBoxContainer4 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -207,7 +207,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools2_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools2_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -220,38 +220,38 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools2_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools2_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools2_Button _L_Button;
- public EditorTools_HBoxContainer4(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer4 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer4(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer4 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer5.Label
///
- public class EditorTools3_Label : IUiNode
+ public class EditorTools3_Label : UiNode
{
- public EditorTools3_Label(Godot.Label node) : base(node) { }
- public override EditorTools3_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools3_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools3_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer5.Button
///
- public class EditorTools3_Button : IUiNode
+ public class EditorTools3_Button : UiNode
{
- public EditorTools3_Button(Godot.Button node) : base(node) { }
- public override EditorTools3_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools3_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools3_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer5
///
- public class EditorTools_HBoxContainer5 : IUiNode
+ public class EditorTools_HBoxContainer5 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -260,7 +260,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools3_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools3_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -273,83 +273,83 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools3_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools3_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools3_Button _L_Button;
- public EditorTools_HBoxContainer5(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer5 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer5(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer5 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.Label
///
- public class EditorTools4_Label : IUiNode
+ public class EditorTools4_Label : UiNode
{
- public EditorTools4_Label(Godot.Label node) : base(node) { }
- public override EditorTools4_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools4_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools4_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.RoomNameInput
///
- public class EditorTools_RoomNameInput : IUiNode
+ public class EditorTools_RoomNameInput : UiNode
{
- public EditorTools_RoomNameInput(Godot.LineEdit node) : base(node) { }
- public override EditorTools_RoomNameInput Clone() => new ((Godot.LineEdit)Instance.Duplicate());
+ public EditorTools_RoomNameInput(EditorTools uiPanel, Godot.LineEdit node) : base(uiPanel, node) { }
+ public override EditorTools_RoomNameInput Clone() => new (UiPanel, (Godot.LineEdit)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.Label2
///
- public class EditorTools_Label2 : IUiNode
+ public class EditorTools_Label2 : UiNode
{
- public EditorTools_Label2(Godot.Label node) : base(node) { }
- public override EditorTools_Label2 Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools_Label2(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools_Label2 Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.RoomGroupSelect
///
- public class EditorTools_RoomGroupSelect : IUiNode
+ public class EditorTools_RoomGroupSelect : UiNode
{
- public EditorTools_RoomGroupSelect(Godot.OptionButton node) : base(node) { }
- public override EditorTools_RoomGroupSelect Clone() => new ((Godot.OptionButton)Instance.Duplicate());
+ public EditorTools_RoomGroupSelect(EditorTools uiPanel, Godot.OptionButton node) : base(uiPanel, node) { }
+ public override EditorTools_RoomGroupSelect Clone() => new (UiPanel, (Godot.OptionButton)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.Label3
///
- public class EditorTools_Label3 : IUiNode
+ public class EditorTools_Label3 : UiNode
{
- public EditorTools_Label3(Godot.Label node) : base(node) { }
- public override EditorTools_Label3 Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools_Label3(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools_Label3 Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.RoomTypeSelect
///
- public class EditorTools_RoomTypeSelect : IUiNode
+ public class EditorTools_RoomTypeSelect : UiNode
{
- public EditorTools_RoomTypeSelect(Godot.OptionButton node) : base(node) { }
- public override EditorTools_RoomTypeSelect Clone() => new ((Godot.OptionButton)Instance.Duplicate());
+ public EditorTools_RoomTypeSelect(EditorTools uiPanel, Godot.OptionButton node) : base(uiPanel, node) { }
+ public override EditorTools_RoomTypeSelect Clone() => new (UiPanel, (Godot.OptionButton)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6.Button
///
- public class EditorTools4_Button : IUiNode
+ public class EditorTools4_Button : UiNode
{
- public EditorTools4_Button(Godot.Button node) : base(node) { }
- public override EditorTools4_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools4_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools4_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer6
///
- public class EditorTools_HBoxContainer6 : IUiNode
+ public class EditorTools_HBoxContainer6 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -358,7 +358,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools4_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools4_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -371,7 +371,7 @@
{
get
{
- if (_L_RoomNameInput == null) _L_RoomNameInput = new EditorTools_RoomNameInput(Instance.GetNodeOrNull("RoomNameInput"));
+ if (_L_RoomNameInput == null) _L_RoomNameInput = new EditorTools_RoomNameInput(UiPanel, Instance.GetNodeOrNull("RoomNameInput"));
return _L_RoomNameInput;
}
}
@@ -384,7 +384,7 @@
{
get
{
- if (_L_Label2 == null) _L_Label2 = new EditorTools_Label2(Instance.GetNodeOrNull("Label2"));
+ if (_L_Label2 == null) _L_Label2 = new EditorTools_Label2(UiPanel, Instance.GetNodeOrNull("Label2"));
return _L_Label2;
}
}
@@ -397,7 +397,7 @@
{
get
{
- if (_L_RoomGroupSelect == null) _L_RoomGroupSelect = new EditorTools_RoomGroupSelect(Instance.GetNodeOrNull("RoomGroupSelect"));
+ if (_L_RoomGroupSelect == null) _L_RoomGroupSelect = new EditorTools_RoomGroupSelect(UiPanel, Instance.GetNodeOrNull("RoomGroupSelect"));
return _L_RoomGroupSelect;
}
}
@@ -410,7 +410,7 @@
{
get
{
- if (_L_Label3 == null) _L_Label3 = new EditorTools_Label3(Instance.GetNodeOrNull("Label3"));
+ if (_L_Label3 == null) _L_Label3 = new EditorTools_Label3(UiPanel, Instance.GetNodeOrNull("Label3"));
return _L_Label3;
}
}
@@ -423,7 +423,7 @@
{
get
{
- if (_L_RoomTypeSelect == null) _L_RoomTypeSelect = new EditorTools_RoomTypeSelect(Instance.GetNodeOrNull("RoomTypeSelect"));
+ if (_L_RoomTypeSelect == null) _L_RoomTypeSelect = new EditorTools_RoomTypeSelect(UiPanel, Instance.GetNodeOrNull("RoomTypeSelect"));
return _L_RoomTypeSelect;
}
}
@@ -436,38 +436,38 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools4_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools4_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools4_Button _L_Button;
- public EditorTools_HBoxContainer6(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer6 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer6(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer6 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer2.Label
///
- public class EditorTools5_Label : IUiNode
+ public class EditorTools5_Label : UiNode
{
- public EditorTools5_Label(Godot.Label node) : base(node) { }
- public override EditorTools5_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools5_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools5_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer2.Button
///
- public class EditorTools5_Button : IUiNode
+ public class EditorTools5_Button : UiNode
{
- public EditorTools5_Button(Godot.Button node) : base(node) { }
- public override EditorTools5_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools5_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools5_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer2
///
- public class EditorTools_HBoxContainer2 : IUiNode
+ public class EditorTools_HBoxContainer2 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -476,7 +476,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools5_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools5_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -489,38 +489,38 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools5_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools5_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools5_Button _L_Button;
- public EditorTools_HBoxContainer2(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer2 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer2(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer2 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer7.Label
///
- public class EditorTools6_Label : IUiNode
+ public class EditorTools6_Label : UiNode
{
- public EditorTools6_Label(Godot.Label node) : base(node) { }
- public override EditorTools6_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public EditorTools6_Label(EditorTools uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override EditorTools6_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer7.Button
///
- public class EditorTools6_Button : IUiNode
+ public class EditorTools6_Button : UiNode
{
- public EditorTools6_Button(Godot.Button node) : base(node) { }
- public override EditorTools6_Button Clone() => new ((Godot.Button)Instance.Duplicate());
+ public EditorTools6_Button(EditorTools uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override EditorTools6_Button Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.HBoxContainer7
///
- public class EditorTools_HBoxContainer7 : IUiNode
+ public class EditorTools_HBoxContainer7 : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer.Label
@@ -529,7 +529,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new EditorTools6_Label(Instance.GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new EditorTools6_Label(UiPanel, Instance.GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -542,20 +542,20 @@
{
get
{
- if (_L_Button == null) _L_Button = new EditorTools6_Button(Instance.GetNodeOrNull("Button"));
+ if (_L_Button == null) _L_Button = new EditorTools6_Button(UiPanel, Instance.GetNodeOrNull("Button"));
return _L_Button;
}
}
private EditorTools6_Button _L_Button;
- public EditorTools_HBoxContainer7(Godot.HBoxContainer node) : base(node) { }
- public override EditorTools_HBoxContainer7 Clone() => new ((Godot.HBoxContainer)Instance.Duplicate());
+ public EditorTools_HBoxContainer7(EditorTools uiPanel, Godot.HBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_HBoxContainer7 Clone() => new (UiPanel, (Godot.HBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer.VBoxContainer
///
- public class EditorTools_VBoxContainer : IUiNode
+ public class EditorTools_VBoxContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.MarginContainer.HBoxContainer
@@ -564,7 +564,7 @@
{
get
{
- if (_L_HBoxContainer == null) _L_HBoxContainer = new EditorTools_HBoxContainer(Instance.GetNodeOrNull("HBoxContainer"));
+ if (_L_HBoxContainer == null) _L_HBoxContainer = new EditorTools_HBoxContainer(UiPanel, Instance.GetNodeOrNull("HBoxContainer"));
return _L_HBoxContainer;
}
}
@@ -577,7 +577,7 @@
{
get
{
- if (_L_HBoxContainer3 == null) _L_HBoxContainer3 = new EditorTools_HBoxContainer3(Instance.GetNodeOrNull("HBoxContainer3"));
+ if (_L_HBoxContainer3 == null) _L_HBoxContainer3 = new EditorTools_HBoxContainer3(UiPanel, Instance.GetNodeOrNull("HBoxContainer3"));
return _L_HBoxContainer3;
}
}
@@ -590,7 +590,7 @@
{
get
{
- if (_L_HBoxContainer4 == null) _L_HBoxContainer4 = new EditorTools_HBoxContainer4(Instance.GetNodeOrNull("HBoxContainer4"));
+ if (_L_HBoxContainer4 == null) _L_HBoxContainer4 = new EditorTools_HBoxContainer4(UiPanel, Instance.GetNodeOrNull("HBoxContainer4"));
return _L_HBoxContainer4;
}
}
@@ -603,7 +603,7 @@
{
get
{
- if (_L_HBoxContainer5 == null) _L_HBoxContainer5 = new EditorTools_HBoxContainer5(Instance.GetNodeOrNull("HBoxContainer5"));
+ if (_L_HBoxContainer5 == null) _L_HBoxContainer5 = new EditorTools_HBoxContainer5(UiPanel, Instance.GetNodeOrNull("HBoxContainer5"));
return _L_HBoxContainer5;
}
}
@@ -616,7 +616,7 @@
{
get
{
- if (_L_HBoxContainer6 == null) _L_HBoxContainer6 = new EditorTools_HBoxContainer6(Instance.GetNodeOrNull("HBoxContainer6"));
+ if (_L_HBoxContainer6 == null) _L_HBoxContainer6 = new EditorTools_HBoxContainer6(UiPanel, Instance.GetNodeOrNull("HBoxContainer6"));
return _L_HBoxContainer6;
}
}
@@ -629,7 +629,7 @@
{
get
{
- if (_L_HBoxContainer2 == null) _L_HBoxContainer2 = new EditorTools_HBoxContainer2(Instance.GetNodeOrNull("HBoxContainer2"));
+ if (_L_HBoxContainer2 == null) _L_HBoxContainer2 = new EditorTools_HBoxContainer2(UiPanel, Instance.GetNodeOrNull("HBoxContainer2"));
return _L_HBoxContainer2;
}
}
@@ -642,20 +642,20 @@
{
get
{
- if (_L_HBoxContainer7 == null) _L_HBoxContainer7 = new EditorTools_HBoxContainer7(Instance.GetNodeOrNull("HBoxContainer7"));
+ if (_L_HBoxContainer7 == null) _L_HBoxContainer7 = new EditorTools_HBoxContainer7(UiPanel, Instance.GetNodeOrNull("HBoxContainer7"));
return _L_HBoxContainer7;
}
}
private EditorTools_HBoxContainer7 _L_HBoxContainer7;
- public EditorTools_VBoxContainer(Godot.VBoxContainer node) : base(node) { }
- public override EditorTools_VBoxContainer Clone() => new ((Godot.VBoxContainer)Instance.Duplicate());
+ public EditorTools_VBoxContainer(EditorTools uiPanel, Godot.VBoxContainer node) : base(uiPanel, node) { }
+ public override EditorTools_VBoxContainer Clone() => new (UiPanel, (Godot.VBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer.MarginContainer
///
- public class EditorTools_MarginContainer : IUiNode
+ public class EditorTools_MarginContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.ScrollContainer.VBoxContainer
@@ -664,20 +664,20 @@
{
get
{
- if (_L_VBoxContainer == null) _L_VBoxContainer = new EditorTools_VBoxContainer(Instance.GetNodeOrNull("VBoxContainer"));
+ if (_L_VBoxContainer == null) _L_VBoxContainer = new EditorTools_VBoxContainer(UiPanel, Instance.GetNodeOrNull("VBoxContainer"));
return _L_VBoxContainer;
}
}
private EditorTools_VBoxContainer _L_VBoxContainer;
- public EditorTools_MarginContainer(Godot.MarginContainer node) : base(node) { }
- public override EditorTools_MarginContainer Clone() => new ((Godot.MarginContainer)Instance.Duplicate());
+ public EditorTools_MarginContainer(EditorTools uiPanel, Godot.MarginContainer node) : base(uiPanel, node) { }
+ public override EditorTools_MarginContainer Clone() => new (UiPanel, (Godot.MarginContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.ScrollContainer
///
- public class EditorTools_ScrollContainer : IUiNode
+ public class EditorTools_ScrollContainer : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: EditorTools.MarginContainer
@@ -686,32 +686,32 @@
{
get
{
- if (_L_MarginContainer == null) _L_MarginContainer = new EditorTools_MarginContainer(Instance.GetNodeOrNull("MarginContainer"));
+ if (_L_MarginContainer == null) _L_MarginContainer = new EditorTools_MarginContainer(UiPanel, Instance.GetNodeOrNull("MarginContainer"));
return _L_MarginContainer;
}
}
private EditorTools_MarginContainer _L_MarginContainer;
- public EditorTools_ScrollContainer(Godot.ScrollContainer node) : base(node) { }
- public override EditorTools_ScrollContainer Clone() => new ((Godot.ScrollContainer)Instance.Duplicate());
+ public EditorTools_ScrollContainer(EditorTools uiPanel, Godot.ScrollContainer node) : base(uiPanel, node) { }
+ public override EditorTools_ScrollContainer Clone() => new (UiPanel, (Godot.ScrollContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.Confirm
///
- public class EditorTools_Confirm : IUiNode
+ public class EditorTools_Confirm : UiNode
{
- public EditorTools_Confirm(Godot.ConfirmationDialog node) : base(node) { }
- public override EditorTools_Confirm Clone() => new ((Godot.ConfirmationDialog)Instance.Duplicate());
+ public EditorTools_Confirm(EditorTools uiPanel, Godot.ConfirmationDialog node) : base(uiPanel, node) { }
+ public override EditorTools_Confirm Clone() => new (UiPanel, (Godot.ConfirmationDialog)Instance.Duplicate());
}
///
/// 类型: , 路径: EditorTools.Tips
///
- public class EditorTools_Tips : IUiNode
+ public class EditorTools_Tips : UiNode
{
- public EditorTools_Tips(Godot.AcceptDialog node) : base(node) { }
- public override EditorTools_Tips Clone() => new ((Godot.AcceptDialog)Instance.Duplicate());
+ public EditorTools_Tips(EditorTools uiPanel, Godot.AcceptDialog node) : base(uiPanel, node) { }
+ public override EditorTools_Tips Clone() => new (UiPanel, (Godot.AcceptDialog)Instance.Duplicate());
}
diff --git a/DungeonShooting_Godot/src/game/ui/loading/Loading.cs b/DungeonShooting_Godot/src/game/ui/loading/Loading.cs
index b061156..a30a2ef 100644
--- a/DungeonShooting_Godot/src/game/ui/loading/Loading.cs
+++ b/DungeonShooting_Godot/src/game/ui/loading/Loading.cs
@@ -12,7 +12,7 @@
{
get
{
- if (_L_ColorRect == null) _L_ColorRect = new Loading_ColorRect(GetNodeOrNull("ColorRect"));
+ if (_L_ColorRect == null) _L_ColorRect = new Loading_ColorRect(this, GetNodeOrNull("ColorRect"));
return _L_ColorRect;
}
}
@@ -25,7 +25,7 @@
{
get
{
- if (_L_Label == null) _L_Label = new Loading_Label(GetNodeOrNull("Label"));
+ if (_L_Label == null) _L_Label = new Loading_Label(this, GetNodeOrNull("Label"));
return _L_Label;
}
}
@@ -39,19 +39,19 @@
///
/// 类型: , 路径: Loading.ColorRect
///
- public class Loading_ColorRect : IUiNode
+ public class Loading_ColorRect : UiNode
{
- public Loading_ColorRect(Godot.ColorRect node) : base(node) { }
- public override Loading_ColorRect Clone() => new ((Godot.ColorRect)Instance.Duplicate());
+ public Loading_ColorRect(Loading uiPanel, Godot.ColorRect node) : base(uiPanel, node) { }
+ public override Loading_ColorRect Clone() => new (UiPanel, (Godot.ColorRect)Instance.Duplicate());
}
///
/// 类型: , 路径: Loading.Label
///
- public class Loading_Label : IUiNode
+ public class Loading_Label : UiNode
{
- public Loading_Label(Godot.Label node) : base(node) { }
- public override Loading_Label Clone() => new ((Godot.Label)Instance.Duplicate());
+ public Loading_Label(Loading uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override Loading_Label Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
diff --git a/DungeonShooting_Godot/src/game/ui/main/Main.cs b/DungeonShooting_Godot/src/game/ui/main/Main.cs
index d0f4d98..e27885a 100644
--- a/DungeonShooting_Godot/src/game/ui/main/Main.cs
+++ b/DungeonShooting_Godot/src/game/ui/main/Main.cs
@@ -12,7 +12,7 @@
{
get
{
- if (_L_Title == null) _L_Title = new Main_Title(GetNodeOrNull("Title"));
+ if (_L_Title == null) _L_Title = new Main_Title(this, GetNodeOrNull("Title"));
return _L_Title;
}
}
@@ -25,7 +25,7 @@
{
get
{
- if (_L_ButtonList == null) _L_ButtonList = new Main_ButtonList(GetNodeOrNull("ButtonList"));
+ if (_L_ButtonList == null) _L_ButtonList = new Main_ButtonList(this, GetNodeOrNull("ButtonList"));
return _L_ButtonList;
}
}
@@ -38,7 +38,7 @@
{
get
{
- if (_L_Version == null) _L_Version = new Main_Version(GetNodeOrNull("Version"));
+ if (_L_Version == null) _L_Version = new Main_Version(this, GetNodeOrNull("Version"));
return _L_Version;
}
}
@@ -52,52 +52,52 @@
///
/// 类型: , 路径: Main.Title
///
- public class Main_Title : IUiNode
+ public class Main_Title : UiNode
{
- public Main_Title(Godot.Label node) : base(node) { }
- public override Main_Title Clone() => new ((Godot.Label)Instance.Duplicate());
+ public Main_Title(Main uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override Main_Title Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.ButtonList.Start
///
- public class Main_Start : IUiNode
+ public class Main_Start : UiNode
{
- public Main_Start(Godot.Button node) : base(node) { }
- public override Main_Start Clone() => new ((Godot.Button)Instance.Duplicate());
+ public Main_Start(Main uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override Main_Start Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.ButtonList.Tools
///
- public class Main_Tools : IUiNode
+ public class Main_Tools : UiNode
{
- public Main_Tools(Godot.Button node) : base(node) { }
- public override Main_Tools Clone() => new ((Godot.Button)Instance.Duplicate());
+ public Main_Tools(Main uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override Main_Tools Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.ButtonList.Setting
///
- public class Main_Setting : IUiNode
+ public class Main_Setting : UiNode
{
- public Main_Setting(Godot.Button node) : base(node) { }
- public override Main_Setting Clone() => new ((Godot.Button)Instance.Duplicate());
+ public Main_Setting(Main uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override Main_Setting Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.ButtonList.Exit
///
- public class Main_Exit : IUiNode
+ public class Main_Exit : UiNode
{
- public Main_Exit(Godot.Button node) : base(node) { }
- public override Main_Exit Clone() => new ((Godot.Button)Instance.Duplicate());
+ public Main_Exit(Main uiPanel, Godot.Button node) : base(uiPanel, node) { }
+ public override Main_Exit Clone() => new (UiPanel, (Godot.Button)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.ButtonList
///
- public class Main_ButtonList : IUiNode
+ public class Main_ButtonList : UiNode
{
///
/// 使用 Instance 属性获取当前节点实例对象, 节点类型: , 节点路径: Main.Start
@@ -106,7 +106,7 @@
{
get
{
- if (_L_Start == null) _L_Start = new Main_Start(Instance.GetNodeOrNull("Start"));
+ if (_L_Start == null) _L_Start = new Main_Start(UiPanel, Instance.GetNodeOrNull("Start"));
return _L_Start;
}
}
@@ -119,7 +119,7 @@
{
get
{
- if (_L_Tools == null) _L_Tools = new Main_Tools(Instance.GetNodeOrNull("Tools"));
+ if (_L_Tools == null) _L_Tools = new Main_Tools(UiPanel, Instance.GetNodeOrNull("Tools"));
return _L_Tools;
}
}
@@ -132,7 +132,7 @@
{
get
{
- if (_L_Setting == null) _L_Setting = new Main_Setting(Instance.GetNodeOrNull("Setting"));
+ if (_L_Setting == null) _L_Setting = new Main_Setting(UiPanel, Instance.GetNodeOrNull("Setting"));
return _L_Setting;
}
}
@@ -145,23 +145,23 @@
{
get
{
- if (_L_Exit == null) _L_Exit = new Main_Exit(Instance.GetNodeOrNull("Exit"));
+ if (_L_Exit == null) _L_Exit = new Main_Exit(UiPanel, Instance.GetNodeOrNull("Exit"));
return _L_Exit;
}
}
private Main_Exit _L_Exit;
- public Main_ButtonList(Godot.VBoxContainer node) : base(node) { }
- public override Main_ButtonList Clone() => new ((Godot.VBoxContainer)Instance.Duplicate());
+ public Main_ButtonList(Main uiPanel, Godot.VBoxContainer node) : base(uiPanel, node) { }
+ public override Main_ButtonList Clone() => new (UiPanel, (Godot.VBoxContainer)Instance.Duplicate());
}
///
/// 类型: , 路径: Main.Version
///
- public class Main_Version : IUiNode
+ public class Main_Version : UiNode
{
- public Main_Version(Godot.Label node) : base(node) { }
- public override Main_Version Clone() => new ((Godot.Label)Instance.Duplicate());
+ public Main_Version(Main uiPanel, Godot.Label node) : base(uiPanel, node) { }
+ public override Main_Version Clone() => new (UiPanel, (Godot.Label)Instance.Duplicate());
}
diff --git a/DungeonShooting_Godot/src/game/ui/main/MainPanel.cs b/DungeonShooting_Godot/src/game/ui/main/MainPanel.cs
index 4b03178..9661ce0 100644
--- a/DungeonShooting_Godot/src/game/ui/main/MainPanel.cs
+++ b/DungeonShooting_Godot/src/game/ui/main/MainPanel.cs
@@ -21,8 +21,7 @@
S_Exit.Instance.Pressed -= OnExitClick;
S_Tools.Instance.Pressed -= OnToolsClick;
}
-
-
+
//点击开始游戏
private void OnStartGameClick()
{
diff --git a/DungeonShooting_Godot/src/game/ui/mapEditor/MapEditor.cs b/DungeonShooting_Godot/src/game/ui/mapEditor/MapEditor.cs
index 92d735e..6104242 100644
--- a/DungeonShooting_Godot/src/game/ui/mapEditor/MapEditor.cs
+++ b/DungeonShooting_Godot/src/game/ui/mapEditor/MapEditor.cs
@@ -12,7 +12,7 @@
{
get
{
- if (_L_Bg == null) _L_Bg = new MapEditor_Bg(GetNodeOrNull("Bg"));
+ if (_L_Bg == null) _L_Bg = new MapEditor_Bg(this, GetNodeOrNull("Bg"));
return _L_Bg;
}
}
@@ -26,16 +26,16 @@
///
/// 类型: , 路径: MapEditor.Bg.HSplitContainer.Left.MapView.SubViewport.TileMap.Draw
///
- public class MapEditor_Draw : IUiNode
+ public class MapEditor_Draw : UiNode
{
- public MapEditor_Draw(Godot.Node2D node) : base(node) { }
- public override MapEditor_Draw Clone() => new ((Godot.Node2D)Instance.Duplicate());
+ public MapEditor_Draw(MapEditor uiPanel, Godot.Node2D node) : base(uiPanel, node) { }
+ public override MapEditor_Draw Clone() => new (UiPanel, (Godot.Node2D)Instance.Duplicate());
}
///
/// 类型: