Skip to content

Commit 568cab6

Browse files
committed
Update to 4.6
1 parent b69a28f commit 568cab6

File tree

7 files changed

+60
-127
lines changed

7 files changed

+60
-127
lines changed

addons/gaea/editor/graph_editor/graph_edit.gd

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,6 @@ var is_loading = false
2626
## Reference to the output node
2727
var _output_node: GaeaOutputGraphNode
2828

29-
## Reference to the window popout separator
30-
var _window_popout_separator: VSeparator
31-
32-
## Reference to the window popout button
33-
var _window_popout_button: Button
34-
3529
var _back_icon: Texture2D
3630
var _forward_icon: Texture2D
3731

@@ -195,31 +189,6 @@ func _add_toolbar_buttons() -> void:
195189
about_button.pressed.connect(main_editor.about_popup_request.emit)
196190
container.add_child(about_button)
197191

198-
_window_popout_separator = VSeparator.new()
199-
container.add_child(_window_popout_separator)
200-
201-
_window_popout_button = Button.new()
202-
_window_popout_button.theme_type_variation = &"FlatButton"
203-
_window_popout_button.icon = EditorInterface.get_base_control().get_theme_icon(&"MakeFloating", &"EditorIcons")
204-
_window_popout_button.pressed.connect(main_editor.panel_popout_request.emit)
205-
container.add_child(_window_popout_button)
206-
207-
if not EditorInterface.is_multi_window_enabled():
208-
_window_popout_button.disabled = true
209-
_window_popout_button.tooltip_text = _get_multiwindow_support_tooltip_text()
210-
211-
212-
func _get_multiwindow_support_tooltip_text() -> String:
213-
# Adapted from https://github.com/godotengine/godot/blob/a8598cd8e261716fa3addb6f10bb57c03a061be9/editor/editor_node.cpp#L4725-L4737
214-
var prefix: String = "Multi-window support is not available because"
215-
if EditorInterface.get_editor_settings().get_setting("interface/editor/single_window_mode"):
216-
return tr(prefix + " Interface > Editor > Single Window Mode is enabled in the editor settings.")
217-
if not EditorInterface.get_editor_settings().get_setting("interface/multi_window/enable"):
218-
return tr(prefix + " Interface > Multi Window > Enable is disabled in the editor settings.")
219-
if DisplayServer.has_feature(DisplayServer.FEATURE_SUBWINDOWS):
220-
return tr(prefix + " the `--single-window` command line argument was used to start the editor.")
221-
return tr(prefix + " the current platform doesn't support multiple windows.")
222-
223192

224193
func _add_node_button_pressed() -> void:
225194
main_editor.popup_create_node_request.emit()
@@ -790,12 +759,6 @@ func _on_edited_script_changed(script: Script):
790759
#endregion
791760

792761
#region Utils and misc
793-
@warning_ignore("shadowed_variable_base_class")
794-
func set_window_popout_button_visible(visible: bool) -> void:
795-
_window_popout_button.visible = visible
796-
_window_popout_separator.visible = visible
797-
798-
799762
## This function converts a local position to a grid position based on the current zoom level and scroll offset.
800763
## It also applies snapping if enabled in the GraphEdit.
801764
func local_to_grid(

addons/gaea/editor/graph_editor/main_editor.gd

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ signal popup_create_node_and_connect_node_request(node: GaeaGraphNode, type: Gae
1010

1111
signal popup_node_context_menu_at_mouse_request(selected_nodes: Array)
1212
signal popup_link_context_menu_at_mouse_request(connection: Dictionary)
13-
@warning_ignore("unused_signal")
14-
signal panel_popout_request()
1513

1614
signal node_selected_for_creation(resource: GaeaNodeResource)
1715
signal special_node_selected_for_creation(id: StringName)

addons/gaea/editor/panel/panel.gd

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -17,48 +17,3 @@ static func instantiate() -> Node:
1717
func _ready() -> void:
1818
if is_part_of_edited_scene():
1919
return
20-
21-
main_editor.panel_popout_request.connect(_on_panel_popout_request)
22-
23-
24-
#region Popout Panel Window
25-
func _on_panel_popout_request() -> void:
26-
graph_edit.set_window_popout_button_visible(false)
27-
var window: Window = Window.new()
28-
window.min_size = get_combined_minimum_size()
29-
window.size = size
30-
window.title = "Gaea - Godot Engine"
31-
window.close_requested.connect(_on_window_close_requested.bind(get_parent(), window))
32-
33-
var margin_container: MarginContainer = MarginContainer.new()
34-
margin_container.set_anchors_preset(Control.PRESET_FULL_RECT)
35-
var panel: Panel = Panel.new()
36-
panel.add_theme_stylebox_override(
37-
&"panel",
38-
EditorInterface.get_base_control().get_theme_stylebox(&"PanelForeground", &"EditorStyles")
39-
)
40-
panel.set_anchors_preset(Control.PRESET_FULL_RECT)
41-
panel.mouse_filter = Control.MOUSE_FILTER_IGNORE
42-
panel.z_index -= 1
43-
window.add_child(margin_container)
44-
margin_container.add_sibling(panel)
45-
46-
var margin: int = get_theme_constant(&"base_margin", &"Editor")
47-
margin_container.add_theme_constant_override(&"margin_top", margin)
48-
margin_container.add_theme_constant_override(&"margin_bottom", margin)
49-
margin_container.add_theme_constant_override(&"margin_left", margin)
50-
margin_container.add_theme_constant_override(&"margin_right", margin)
51-
52-
window.position = global_position as Vector2i + DisplayServer.window_get_position()
53-
54-
reparent(margin_container, false)
55-
56-
EditorInterface.get_base_control().add_child(window)
57-
window.popup()
58-
59-
60-
func _on_window_close_requested(original_parent: Control, window: Window) -> void:
61-
graph_edit.set_window_popout_button_visible(true)
62-
reparent(original_parent, false)
63-
window.queue_free()
64-
#endregion

addons/gaea/gaea.gd

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,45 +5,48 @@ extends EditorPlugin
55

66
const InspectorPlugin = preload("uid://bpg2cpobusnnl")
77

8-
var _container: MarginContainer
98
var _panel: GaeaPanel
10-
var _panel_button: Button
9+
var _dock: EditorDock
1110
var _editor_selection: EditorSelection
1211
var _inspector_plugin: EditorInspectorPlugin
1312
var _custom_project_settings: GaeaProjectSettings
1413

1514

1615
func _enter_tree() -> void:
17-
if Engine.is_editor_hint():
18-
_editor_selection = EditorInterface.get_selection()
19-
_editor_selection.selection_changed.connect(_on_selection_changed)
16+
_editor_selection = EditorInterface.get_selection()
17+
_editor_selection.selection_changed.connect(_on_selection_changed)
18+
19+
_panel = GaeaPanel.instantiate()
20+
_panel.plugin = self
21+
22+
_dock = EditorDock.new()
23+
_dock.available_layouts = EditorDock.DOCK_LAYOUT_FLOATING | EditorDock.DOCK_LAYOUT_HORIZONTAL
24+
_dock.title = "Gaea"
25+
_dock.default_slot = EditorDock.DOCK_SLOT_BOTTOM
26+
_dock.add_child(_panel)
27+
add_dock(_dock)
2028

21-
_container = MarginContainer.new()
22-
_panel = GaeaPanel.instantiate()
23-
_panel.plugin = self
24-
_container.add_child(_panel)
25-
_panel_button = add_control_to_bottom_panel(_container, "Gaea")
26-
_panel_button.show()
2729

28-
_inspector_plugin = InspectorPlugin.new(_panel)
29-
add_inspector_plugin(_inspector_plugin)
30+
_inspector_plugin = InspectorPlugin.new(_panel)
31+
add_inspector_plugin(_inspector_plugin)
3032

31-
GaeaEditorSettings.new().add_settings()
32-
_custom_project_settings = GaeaProjectSettings.new()
33-
_custom_project_settings.add_settings()
33+
GaeaEditorSettings.new().add_settings()
34+
_custom_project_settings = GaeaProjectSettings.new()
35+
_custom_project_settings.add_settings()
3436

35-
resource_saved.connect(_on_resource_saved)
37+
resource_saved.connect(_on_resource_saved)
3638

37-
EditorInterface.get_file_system_dock().resource_removed.connect(_on_resource_removed)
38-
EditorInterface.get_file_system_dock().file_removed.connect(_on_file_removed)
39+
EditorInterface.get_file_system_dock().resource_removed.connect(_on_resource_removed)
40+
EditorInterface.get_file_system_dock().file_removed.connect(_on_file_removed)
3941

4042

4143
func _exit_tree() -> void:
4244
if Engine.is_editor_hint():
4345
_panel.graph_edit.unpopulate()
4446
remove_inspector_plugin(_inspector_plugin)
45-
remove_control_from_bottom_panel(_container)
46-
_container.queue_free()
47+
remove_dock(_dock)
48+
_dock.queue_free()
49+
_dock = null
4750

4851

4952
func _disable_plugin() -> void:
@@ -90,7 +93,7 @@ func _edit(object: Object) -> void:
9093
if object.resource_path.is_empty():
9194
return
9295

93-
make_bottom_panel_item_visible(_container)
96+
_dock.make_visible()
9497
if _panel.graph_edit.graph == object:
9598
return
9699

addons/gaea_documentation_toolkit/documentation_toolkit.tscn

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[gd_scene load_steps=4 format=3 uid="uid://bxanwt5o3b0ng"]
1+
[gd_scene format=3 uid="uid://bxanwt5o3b0ng"]
22

33
[ext_resource type="Script" uid="uid://darqwls1ewij0" path="res://addons/gaea_documentation_toolkit/documentation_toolkit.gd" id="1_lxb1e"]
44
[ext_resource type="Script" uid="uid://obmksa6ngu1s" path="res://addons/gaea_documentation_toolkit/tree.gd" id="2_8ok20"]
@@ -8,7 +8,8 @@ font_names = PackedStringArray("Consolas", "Monospace")
88
subpixel_positioning = 0
99
keep_rounding_remainders = false
1010

11-
[node name="DocumentationToolkit" type="Control"]
11+
[node name="DocumentationToolkit" type="Control" unique_id=1633651677]
12+
custom_minimum_size = Vector2(0, 128)
1213
layout_mode = 3
1314
anchors_preset = 15
1415
anchor_right = 1.0
@@ -17,49 +18,49 @@ grow_horizontal = 2
1718
grow_vertical = 2
1819
script = ExtResource("1_lxb1e")
1920

20-
[node name="HBoxContainer" type="HSplitContainer" parent="."]
21+
[node name="HBoxContainer" type="HSplitContainer" parent="." unique_id=1744461141]
2122
layout_mode = 1
2223
anchors_preset = 15
2324
anchor_right = 1.0
2425
anchor_bottom = 1.0
2526
grow_horizontal = 2
2627
grow_vertical = 2
2728

28-
[node name="TreeContainer" type="VBoxContainer" parent="HBoxContainer"]
29+
[node name="TreeContainer" type="VBoxContainer" parent="HBoxContainer" unique_id=515664750]
2930
custom_minimum_size = Vector2(200, 0)
3031
layout_mode = 2
3132

32-
[node name="SearchBar" type="LineEdit" parent="HBoxContainer/TreeContainer"]
33+
[node name="SearchBar" type="LineEdit" parent="HBoxContainer/TreeContainer" unique_id=1200599534]
3334
layout_mode = 2
3435
placeholder_text = "Search..."
3536

36-
[node name="Tree" type="Tree" parent="HBoxContainer/TreeContainer"]
37+
[node name="Tree" type="Tree" parent="HBoxContainer/TreeContainer" unique_id=1446740897]
3738
unique_name_in_owner = true
3839
custom_minimum_size = Vector2(192, 0)
3940
layout_mode = 2
4041
size_flags_vertical = 3
4142
script = ExtResource("2_8ok20")
4243

43-
[node name="HBoxContainer" type="HBoxContainer" parent="HBoxContainer/TreeContainer"]
44+
[node name="HBoxContainer" type="HBoxContainer" parent="HBoxContainer/TreeContainer" unique_id=2112535570]
4445
layout_mode = 2
4546

46-
[node name="OpenFolderButton" type="Button" parent="HBoxContainer/TreeContainer/HBoxContainer"]
47+
[node name="OpenFolderButton" type="Button" parent="HBoxContainer/TreeContainer/HBoxContainer" unique_id=1158338676]
4748
unique_name_in_owner = true
4849
custom_minimum_size = Vector2(31, 0)
4950
layout_mode = 2
5051
tooltip_text = "Open target folder..."
5152

52-
[node name="ExportAllButton" type="Button" parent="HBoxContainer/TreeContainer/HBoxContainer"]
53+
[node name="ExportAllButton" type="Button" parent="HBoxContainer/TreeContainer/HBoxContainer" unique_id=205747794]
5354
layout_mode = 2
5455
size_flags_horizontal = 3
5556
text = "Export All"
5657

57-
[node name="RightContainer" type="Control" parent="HBoxContainer"]
58+
[node name="RightContainer" type="Control" parent="HBoxContainer" unique_id=9088164]
5859
custom_minimum_size = Vector2(200, 0)
5960
layout_mode = 2
6061
size_flags_horizontal = 3
6162

62-
[node name="SubViewportContainer" type="SubViewportContainer" parent="HBoxContainer/RightContainer"]
63+
[node name="SubViewportContainer" type="SubViewportContainer" parent="HBoxContainer/RightContainer" unique_id=414675997]
6364
z_index = -4096
6465
z_as_relative = false
6566
layout_mode = 1
@@ -70,14 +71,14 @@ grow_horizontal = 2
7071
grow_vertical = 2
7172
size_flags_horizontal = 3
7273

73-
[node name="SubViewport" type="SubViewport" parent="HBoxContainer/RightContainer/SubViewportContainer"]
74+
[node name="SubViewport" type="SubViewport" parent="HBoxContainer/RightContainer/SubViewportContainer" unique_id=989321962]
7475
unique_name_in_owner = true
7576
transparent_bg = true
7677
handle_input_locally = false
7778
size = Vector2i(2, 2)
7879
render_target_update_mode = 4
7980

80-
[node name="Panel" type="Panel" parent="HBoxContainer/RightContainer"]
81+
[node name="Panel" type="Panel" parent="HBoxContainer/RightContainer" unique_id=1631485179]
8182
layout_mode = 1
8283
anchors_preset = 15
8384
anchor_right = 1.0
@@ -86,7 +87,7 @@ grow_horizontal = 2
8687
grow_vertical = 2
8788
size_flags_horizontal = 3
8889

89-
[node name="Markdown" type="RichTextLabel" parent="HBoxContainer/RightContainer/Panel"]
90+
[node name="Markdown" type="RichTextLabel" parent="HBoxContainer/RightContainer/Panel" unique_id=1995849860]
9091
unique_name_in_owner = true
9192
layout_mode = 1
9293
anchors_preset = 15
@@ -100,7 +101,7 @@ autowrap_trim_flags = 0
100101
context_menu_enabled = true
101102
selection_enabled = true
102103

103-
[node name="ConfirmationDialog" type="ConfirmationDialog" parent="."]
104+
[node name="ConfirmationDialog" type="ConfirmationDialog" parent="." unique_id=880913801]
104105
dialog_text = "This will create images for every node in the tree, are you sure you want to?"
105106

106107
[connection signal="text_changed" from="HBoxContainer/TreeContainer/SearchBar" to="HBoxContainer/TreeContainer/Tree" method="_on_search_bar_text_changed"]

addons/gaea_documentation_toolkit/plugin.gd

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,20 @@ extends EditorPlugin
33

44
const DocumentationToolkit = preload("uid://bxanwt5o3b0ng")
55

6-
var _panel: Control
6+
var _dock: EditorDock
77

88

99
func _enter_tree() -> void:
10-
_panel = DocumentationToolkit.instantiate()
11-
add_control_to_bottom_panel(_panel, "Gaea Documentation Toolkit")
10+
_dock = EditorDock.new()
11+
_dock.available_layouts = EditorDock.DOCK_LAYOUT_FLOATING | EditorDock.DOCK_LAYOUT_HORIZONTAL
12+
_dock.title = "Gaea Documentation Toolkit"
13+
_dock.default_slot = EditorDock.DOCK_SLOT_BOTTOM
14+
15+
_dock.add_child(DocumentationToolkit.instantiate())
16+
add_dock(_dock)
1217

1318

1419
func _exit_tree() -> void:
15-
remove_control_from_bottom_panel(_panel)
20+
remove_dock(_dock)
21+
_dock.queue_free()
22+
_dock = null

project.godot

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,23 @@
88

99
config_version=5
1010

11+
[animation]
12+
13+
compatibility/default_parent_skeleton_in_mesh_instance_3d=true
14+
1115
[application]
1216

1317
config/name="Gaea"
1418
config/tags=PackedStringArray("addon")
1519
run/main_scene="res://scenes/walker_demo/walker_demo.tscn"
16-
config/features=PackedStringArray("4.5", "Forward Plus")
20+
config/features=PackedStringArray("4.6", "Forward Plus")
1721
config/icon="res://icon.svg"
1822

1923
[debug]
2024

21-
gdscript/warnings/exclude_addons=false
25+
gdscript/warnings/directory_rules={
26+
"res://addons": 1
27+
}
2228

2329
[display]
2430

0 commit comments

Comments
 (0)