Переглянути джерело

Move server files into their subfolders

Aaron Franke 1 рік тому
батько
коміт
3d1c9fd5de
100 змінених файлів з 156 додано та 148 видалено
  1. 1 1
      core/debugger/remote_debugger.cpp
  2. 1 1
      core/io/resource_loader.cpp
  3. 1 1
      drivers/accesskit/accessibility_driver_accesskit.cpp
  4. 1 1
      drivers/accesskit/accessibility_driver_accesskit.h
  5. 1 1
      drivers/alsa/audio_driver_alsa.h
  6. 1 1
      drivers/apple_embedded/display_server_apple_embedded.h
  7. 1 1
      drivers/apple_embedded/godot_view_renderer.mm
  8. 1 1
      drivers/apple_embedded/os_apple_embedded.h
  9. 1 1
      drivers/apple_embedded/tts_apple_embedded.h
  10. 1 1
      drivers/coreaudio/audio_driver_coreaudio.h
  11. 1 1
      drivers/d3d12/rendering_context_driver_d3d12.h
  12. 1 1
      drivers/egl/egl_manager.h
  13. 1 1
      drivers/gles3/rasterizer_scene_gles3.cpp
  14. 1 1
      drivers/gles3/rasterizer_scene_gles3.h
  15. 1 1
      drivers/gles3/shader_gles3.h
  16. 1 1
      drivers/pulseaudio/audio_driver_pulseaudio.h
  17. 1 1
      drivers/unix/os_unix.cpp
  18. 1 1
      drivers/wasapi/audio_driver_wasapi.h
  19. 1 1
      drivers/xaudio2/audio_driver_xaudio2.h
  20. 1 1
      editor/animation/animation_player_editor_plugin.cpp
  21. 1 1
      editor/audio/editor_audio_buses.cpp
  22. 1 1
      editor/debugger/editor_debugger_tree.cpp
  23. 1 1
      editor/debugger/script_editor_debugger.cpp
  24. 1 1
      editor/docks/filesystem_dock.cpp
  25. 1 1
      editor/docks/scene_tree_dock.cpp
  26. 6 6
      editor/editor_node.cpp
  27. 1 1
      editor/gui/editor_dir_dialog.cpp
  28. 1 1
      editor/gui/editor_file_dialog.cpp
  29. 1 1
      editor/gui/progress_dialog.cpp
  30. 1 1
      editor/import/resource_importer_bmfont.h
  31. 1 1
      editor/import/resource_importer_dynamic_font.cpp
  32. 1 1
      editor/import/resource_importer_imagefont.h
  33. 1 1
      editor/import/resource_importer_texture.h
  34. 7 7
      editor/project_manager/project_manager.cpp
  35. 1 1
      editor/run/editor_run.cpp
  36. 1 1
      editor/run/editor_run_bar.cpp
  37. 1 1
      editor/scene/2d/tiles/tile_data_editors.cpp
  38. 1 1
      editor/scene/2d/tiles/tile_set_atlas_source_editor.cpp
  39. 1 1
      editor/script/script_editor_plugin.cpp
  40. 1 1
      editor/shader/shader_file_editor_plugin.cpp
  41. 1 1
      editor/shader/visual_shader_editor_plugin.cpp
  42. 13 13
      main/main.cpp
  43. 1 1
      main/main_timer_sync.cpp
  44. 11 6
      main/performance.cpp
  45. 3 0
      main/performance.h
  46. 1 1
      modules/basis_universal/image_compress_basisu.cpp
  47. 1 1
      modules/betsy/image_compress_betsy.cpp
  48. 1 1
      modules/camera/camera_android.h
  49. 1 1
      modules/camera/camera_feed_linux.cpp
  50. 1 1
      modules/camera/camera_linux.h
  51. 1 1
      modules/camera/camera_macos.h
  52. 1 1
      modules/camera/camera_win.h
  53. 1 1
      modules/csg/csg_shape.cpp
  54. 1 1
      modules/gdscript/gdscript_parser.cpp
  55. 1 1
      modules/gdscript/gdscript_tokenizer.cpp
  56. 1 1
      modules/gdscript/language_server/gdscript_text_document.cpp
  57. 1 1
      modules/godot_physics_2d/godot_area_2d.h
  58. 1 1
      modules/godot_physics_2d/godot_body_direct_state_2d.h
  59. 1 1
      modules/godot_physics_2d/godot_collision_object_2d.h
  60. 1 1
      modules/godot_physics_2d/godot_physics_server_2d.h
  61. 1 1
      modules/godot_physics_2d/godot_shape_2d.h
  62. 2 2
      modules/godot_physics_2d/register_types.cpp
  63. 1 1
      modules/godot_physics_3d/godot_area_3d.h
  64. 1 1
      modules/godot_physics_3d/godot_body_direct_state_3d.h
  65. 1 1
      modules/godot_physics_3d/godot_collision_object_3d.h
  66. 1 1
      modules/godot_physics_3d/godot_physics_server_3d.h
  67. 1 1
      modules/godot_physics_3d/godot_shape_3d.h
  68. 1 1
      modules/godot_physics_3d/godot_soft_body_3d.cpp
  69. 2 2
      modules/godot_physics_3d/register_types.cpp
  70. 2 2
      modules/gridmap/grid_map.cpp
  71. 1 1
      modules/jolt_physics/joints/jolt_joint_3d.h
  72. 1 1
      modules/jolt_physics/jolt_physics_server_3d.cpp
  73. 1 1
      modules/jolt_physics/jolt_physics_server_3d.h
  74. 1 1
      modules/jolt_physics/objects/jolt_area_3d.h
  75. 1 1
      modules/jolt_physics/objects/jolt_physics_direct_body_state_3d.h
  76. 1 1
      modules/jolt_physics/objects/jolt_soft_body_3d.cpp
  77. 1 1
      modules/jolt_physics/objects/jolt_soft_body_3d.h
  78. 1 1
      modules/jolt_physics/register_types.cpp
  79. 1 1
      modules/jolt_physics/shapes/jolt_shape_3d.h
  80. 1 1
      modules/jolt_physics/spaces/jolt_physics_direct_space_state_3d.h
  81. 1 1
      modules/jolt_physics/spaces/jolt_space_3d.h
  82. 1 1
      modules/mobile_vr/mobile_vr_interface.cpp
  83. 1 1
      modules/mono/csharp_script.cpp
  84. 3 3
      modules/navigation_2d/2d/godot_navigation_server_2d.h
  85. 3 3
      modules/navigation_2d/2d/nav_base_iteration_2d.h
  86. 1 1
      modules/navigation_2d/2d/nav_mesh_generator_2d.h
  87. 3 4
      modules/navigation_2d/2d/nav_mesh_queries_2d.cpp
  88. 6 5
      modules/navigation_2d/2d/nav_mesh_queries_2d.h
  89. 1 1
      modules/navigation_2d/nav_agent_2d.h
  90. 3 3
      modules/navigation_2d/nav_base_2d.h
  91. 1 1
      modules/navigation_2d/nav_link_2d.cpp
  92. 1 1
      modules/navigation_2d/nav_map_2d.cpp
  93. 1 1
      modules/navigation_2d/nav_map_2d.h
  94. 1 1
      modules/navigation_2d/nav_region_2d.cpp
  95. 2 2
      modules/navigation_2d/nav_utils_2d.h
  96. 1 1
      modules/navigation_2d/register_types.cpp
  97. 1 1
      modules/navigation_3d/3d/godot_navigation_server_3d.cpp
  98. 3 3
      modules/navigation_3d/3d/godot_navigation_server_3d.h
  99. 3 3
      modules/navigation_3d/3d/nav_base_iteration_3d.h
  100. 1 1
      modules/navigation_3d/3d/nav_mesh_generator_3d.h

+ 1 - 1
core/debugger/remote_debugger.cpp

@@ -40,7 +40,7 @@
 #include "core/math/expression.h"
 #include "core/object/script_language.h"
 #include "core/os/os.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 class RemoteDebugger::PerformanceProfiler : public EngineProfiler {
 	Object *performance = nullptr;

+ 1 - 1
core/io/resource_loader.cpp

@@ -43,7 +43,7 @@
 #include "core/string/translation_server.h"
 #include "core/templates/rb_set.h"
 #include "core/variant/variant_parser.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #ifdef DEBUG_LOAD_THREADED
 #define print_lt(m_text) print_line(m_text)

+ 1 - 1
drivers/accesskit/accessibility_driver_accesskit.cpp

@@ -35,7 +35,7 @@
 #include "core/config/project_settings.h"
 #include "core/version.h"
 
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 
 AccessibilityDriverAccessKit *AccessibilityDriverAccessKit::singleton = nullptr;
 

+ 1 - 1
drivers/accesskit/accessibility_driver_accesskit.h

@@ -33,7 +33,7 @@
 #ifdef ACCESSKIT_ENABLED
 
 #include "core/templates/rid_owner.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 #ifdef ACCESSKIT_DYNAMIC
 #ifdef LINUXBSD_ENABLED

+ 1 - 1
drivers/alsa/audio_driver_alsa.h

@@ -35,7 +35,7 @@
 #include "core/os/mutex.h"
 #include "core/os/thread.h"
 #include "core/templates/safe_refcount.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #ifdef SOWRAP_ENABLED
 #include "asound-so_wrap.h"

+ 1 - 1
drivers/apple_embedded/display_server_apple_embedded.h

@@ -31,7 +31,7 @@
 #pragma once
 
 #include "core/input/input.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 #if defined(RD_ENABLED)
 #include "servers/rendering/renderer_rd/renderer_compositor_rd.h"

+ 1 - 1
drivers/apple_embedded/godot_view_renderer.mm

@@ -36,7 +36,7 @@
 #include "core/config/project_settings.h"
 #include "core/os/keyboard.h"
 #include "main/main.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #import <AudioToolbox/AudioServices.h>
 #import <CoreMotion/CoreMotion.h>

+ 1 - 1
drivers/apple_embedded/os_apple_embedded.h

@@ -37,7 +37,7 @@
 #import "drivers/apple/joypad_apple.h"
 #import "drivers/coreaudio/audio_driver_coreaudio.h"
 #include "drivers/unix/os_unix.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 #include "servers/rendering/renderer_compositor.h"
 
 #if defined(RD_ENABLED)

+ 1 - 1
drivers/apple_embedded/tts_apple_embedded.h

@@ -34,7 +34,7 @@
 #include "core/templates/hash_map.h"
 #include "core/templates/list.h"
 #include "core/variant/array.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 #if __has_include(<AVFAudio/AVSpeechSynthesis.h>)
 #import <AVFAudio/AVSpeechSynthesis.h>

+ 1 - 1
drivers/coreaudio/audio_driver_coreaudio.h

@@ -32,7 +32,7 @@
 
 #ifdef COREAUDIO_ENABLED
 
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #import <AudioUnit/AudioUnit.h>
 #ifdef MACOS_ENABLED

+ 1 - 1
drivers/d3d12/rendering_context_driver_d3d12.h

@@ -34,7 +34,7 @@
 #include "core/string/ustring.h"
 #include "core/templates/rid_owner.h"
 #include "rendering_device_driver_d3d12.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 #include "servers/rendering/rendering_context_driver.h"
 
 #if defined(AS)

+ 1 - 1
drivers/egl/egl_manager.h

@@ -36,7 +36,7 @@
 #include "platform_gl.h"
 
 #include "core/templates/local_vector.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 class EGLManager {
 private:

+ 1 - 1
drivers/gles3/rasterizer_scene_gles3.cpp

@@ -42,7 +42,7 @@
 #include "core/config/project_settings.h"
 #include "core/templates/sort_array.h"
 #include "servers/camera/camera_feed.h"
-#include "servers/camera_server.h"
+#include "servers/camera/camera_server.h"
 #include "servers/rendering/rendering_server_default.h"
 #include "servers/rendering/rendering_server_globals.h"
 

+ 1 - 1
drivers/gles3/rasterizer_scene_gles3.h

@@ -42,7 +42,7 @@
 #include "scene/resources/mesh.h"
 #include "servers/rendering/renderer_compositor.h"
 #include "servers/rendering/renderer_scene_render.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 #include "shader_gles3.h"
 #include "storage/light_storage.h"
 #include "storage/material_storage.h"

+ 1 - 1
drivers/gles3/shader_gles3.h

@@ -36,7 +36,7 @@
 #include "core/templates/hash_map.h"
 #include "core/templates/local_vector.h"
 #include "core/templates/rid_owner.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #ifdef GLES3_ENABLED
 

+ 1 - 1
drivers/pulseaudio/audio_driver_pulseaudio.h

@@ -35,7 +35,7 @@
 #include "core/os/mutex.h"
 #include "core/os/thread.h"
 #include "core/templates/safe_refcount.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #ifdef SOWRAP_ENABLED
 #include "pulse-so_wrap.h"

+ 1 - 1
drivers/unix/os_unix.cpp

@@ -40,7 +40,7 @@
 #include "drivers/unix/file_access_unix_pipe.h"
 #include "drivers/unix/net_socket_unix.h"
 #include "drivers/unix/thread_posix.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #if defined(__APPLE__)
 #include <mach-o/dyld.h>

+ 1 - 1
drivers/wasapi/audio_driver_wasapi.h

@@ -35,7 +35,7 @@
 #include "core/os/mutex.h"
 #include "core/os/thread.h"
 #include "core/templates/safe_refcount.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #include <audioclient.h>
 #include <mmdeviceapi.h>

+ 1 - 1
drivers/xaudio2/audio_driver_xaudio2.h

@@ -33,7 +33,7 @@
 #include "core/os/mutex.h"
 #include "core/os/thread.h"
 #include "core/templates/safe_refcount.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 #include <mmsystem.h>
 #define WIN32_LEAN_AND_MEAN

+ 1 - 1
editor/animation/animation_player_editor_plugin.cpp

@@ -52,7 +52,7 @@
 #include "scene/main/window.h"
 #include "scene/resources/animation.h"
 #include "scene/resources/image_texture.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 ///////////////////////////////////
 

+ 1 - 1
editor/audio/editor_audio_buses.cpp

@@ -46,7 +46,7 @@
 #include "editor/themes/editor_theme_manager.h"
 #include "scene/gui/separator.h"
 #include "scene/resources/font.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
 
 void EditorAudioBus::_update_visible_channels() {
 	int i = 0;

+ 1 - 1
editor/debugger/editor_debugger_tree.cpp

@@ -40,7 +40,7 @@
 #include "scene/debugger/scene_debugger.h"
 #include "scene/gui/texture_rect.h"
 #include "scene/resources/packed_scene.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 EditorDebuggerTree::EditorDebuggerTree() {
 	set_v_size_flags(SIZE_EXPAND_FILL);

+ 1 - 1
editor/debugger/script_editor_debugger.cpp

@@ -66,7 +66,7 @@
 #include "scene/gui/tab_container.h"
 #include "scene/gui/tree.h"
 #include "servers/debugger/servers_debugger.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 using CameraOverride = EditorDebuggerNode::CameraOverride;
 

+ 1 - 1
editor/docks/filesystem_dock.cpp

@@ -63,7 +63,7 @@
 #include "scene/gui/line_edit.h"
 #include "scene/gui/progress_bar.h"
 #include "scene/resources/packed_scene.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 Control *FileSystemTree::make_custom_tooltip(const String &p_text) const {
 	TreeItem *item = get_item_at_position(get_local_mouse_position());

+ 1 - 1
editor/docks/scene_tree_dock.cpp

@@ -65,7 +65,7 @@
 #include "scene/gui/check_box.h"
 #include "scene/property_utils.h"
 #include "scene/resources/packed_scene.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void SceneTreeDock::_nodes_drag_begin() {
 	pending_click_select = nullptr;

+ 6 - 6
editor/editor_node.cpp

@@ -67,10 +67,10 @@
 #include "scene/resources/packed_scene.h"
 #include "scene/resources/portable_compressed_texture.h"
 #include "scene/theme/theme_db.h"
-#include "servers/display_server.h"
-#include "servers/navigation_server_2d.h"
-#include "servers/navigation_server_3d.h"
-#include "servers/rendering_server.h"
+#include "servers/display/display_server.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
+#include "servers/rendering/rendering_server.h"
 
 #include "editor/animation/animation_player_editor_plugin.h"
 #include "editor/asset_library/asset_library_editor_plugin.h"
@@ -183,11 +183,11 @@
 #include "modules/modules_enabled.gen.h" // For gdscript, mono.
 
 #ifndef PHYSICS_2D_DISABLED
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 #endif // PHYSICS_2D_DISABLED
 
 #ifndef PHYSICS_3D_DISABLED
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 #endif // PHYSICS_3D_DISABLED
 
 #ifdef ANDROID_ENABLED

+ 1 - 1
editor/gui/editor_dir_dialog.cpp

@@ -36,7 +36,7 @@
 #include "editor/themes/editor_theme_manager.h"
 #include "scene/gui/box_container.h"
 #include "scene/gui/tree.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void EditorDirDialog::_update_dir(const Color &p_default_folder_color, const Dictionary &p_assigned_folder_colors, const HashMap<String, Color> &p_folder_colors, bool p_is_dark_theme, TreeItem *p_item, EditorFileSystemDirectory *p_dir, const String &p_select_path) {
 	updating = true;

+ 1 - 1
editor/gui/editor_file_dialog.cpp

@@ -50,7 +50,7 @@
 #include "scene/gui/separator.h"
 #include "scene/gui/split_container.h"
 #include "scene/gui/texture_rect.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void EditorFileDialog::_native_popup() {
 	// Show native dialog directly.

+ 1 - 1
editor/gui/progress_dialog.cpp

@@ -37,7 +37,7 @@
 #include "main/main.h"
 #include "scene/gui/panel_container.h"
 #include "scene/main/window.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void BackgroundProgress::_add_task(const String &p_task, const String &p_label, int p_steps) {
 	_THREAD_SAFE_METHOD_

+ 1 - 1
editor/import/resource_importer_bmfont.h

@@ -32,7 +32,7 @@
 
 #include "core/io/resource_importer.h"
 #include "scene/resources/font.h"
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 
 class ResourceImporterBMFont : public ResourceImporter {
 	GDCLASS(ResourceImporterBMFont, ResourceImporter);

+ 1 - 1
editor/import/resource_importer_dynamic_font.cpp

@@ -34,7 +34,7 @@
 #include "core/io/resource_saver.h"
 #include "editor/import/dynamic_font_import_settings.h"
 #include "scene/resources/font.h"
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 
 String ResourceImporterDynamicFont::get_importer_name() const {
 	return "font_data_dynamic";

+ 1 - 1
editor/import/resource_importer_imagefont.h

@@ -32,7 +32,7 @@
 
 #include "core/io/resource_importer.h"
 #include "scene/resources/font.h"
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 
 class ResourceImporterImageFont : public ResourceImporter {
 	GDCLASS(ResourceImporterImageFont, ResourceImporter);

+ 1 - 1
editor/import/resource_importer_texture.h

@@ -33,7 +33,7 @@
 #include "core/io/file_access.h"
 #include "core/io/image.h"
 #include "core/io/resource_importer.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 class CompressedTexture2D;
 

+ 7 - 7
editor/project_manager/project_manager.cpp

@@ -62,17 +62,17 @@
 #include "scene/gui/separator.h"
 #include "scene/main/window.h"
 #include "scene/theme/theme_db.h"
-#include "servers/display_server.h"
-#include "servers/navigation_server_3d.h"
-
-#ifndef PHYSICS_3D_DISABLED
-#include "servers/physics_server_3d.h"
-#endif // PHYSICS_3D_DISABLED
+#include "servers/display/display_server.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 
 #ifndef PHYSICS_2D_DISABLED
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 #endif // PHYSICS_2D_DISABLED
 
+#ifndef PHYSICS_3D_DISABLED
+#include "servers/physics_3d/physics_server_3d.h"
+#endif // PHYSICS_3D_DISABLED
+
 constexpr int GODOT4_CONFIG_VERSION = 5;
 
 ProjectManager *ProjectManager::singleton = nullptr;

+ 1 - 1
editor/run/editor_run.cpp

@@ -36,7 +36,7 @@
 #include "editor/run/run_instances_dialog.h"
 #include "editor/settings/editor_settings.h"
 #include "main/main.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 EditorRun::Status EditorRun::get_status() const {
 	return status;

+ 1 - 1
editor/run/editor_run_bar.cpp

@@ -49,7 +49,7 @@
 #include "scene/gui/panel_container.h"
 
 #ifndef XR_DISABLED
-#include "servers/xr_server.h"
+#include "servers/xr/xr_server.h"
 #endif // XR_DISABLED
 
 EditorRunBar *EditorRunBar::singleton = nullptr;

+ 1 - 1
editor/scene/2d/tiles/tile_data_editors.cpp

@@ -50,7 +50,7 @@
 #include "scene/gui/separator.h"
 #include "scene/gui/spin_box.h"
 
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 void TileDataEditor::_tile_set_changed_plan_update() {
 	_tile_set_changed_update_needed = true;

+ 1 - 1
editor/scene/2d/tiles/tile_set_atlas_source_editor.cpp

@@ -48,7 +48,7 @@
 #include "core/math/geometry_2d.h"
 #include "core/os/keyboard.h"
 
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 void TileSetAtlasSourceEditor::TileSetAtlasSourceProxyObject::set_id(int p_id) {
 	ERR_FAIL_COND(p_id < 0);

+ 1 - 1
editor/script/script_editor_plugin.cpp

@@ -72,7 +72,7 @@
 #include "scene/main/node.h"
 #include "scene/main/window.h"
 #include "script_text_editor.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 #include "text_editor.h"
 
 /*** SYNTAX HIGHLIGHTER ****/

+ 1 - 1
editor/shader/shader_file_editor_plugin.cpp

@@ -37,7 +37,7 @@
 #include "editor/themes/editor_scale.h"
 #include "scene/gui/item_list.h"
 #include "scene/gui/split_container.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 /*** SHADER SCRIPT EDITOR ****/
 

+ 1 - 1
editor/shader/visual_shader_editor_plugin.cpp

@@ -71,7 +71,7 @@
 #include "scene/resources/style_box_flat.h"
 #include "scene/resources/visual_shader_nodes.h"
 #include "scene/resources/visual_shader_particle_nodes.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 #include "servers/rendering/shader_preprocessor.h"
 #include "servers/rendering/shader_types.h"
 

+ 13 - 13
main/main.cpp

@@ -67,39 +67,39 @@
 #include "scene/resources/packed_scene.h"
 #include "scene/theme/theme_db.h"
 #include "servers/audio/audio_driver_dummy.h"
-#include "servers/audio_server.h"
-#include "servers/camera_server.h"
-#include "servers/display_server.h"
+#include "servers/audio/audio_server.h"
+#include "servers/camera/camera_server.h"
+#include "servers/display/display_server.h"
 #include "servers/movie_writer/movie_writer.h"
 #include "servers/register_server_types.h"
 #include "servers/rendering/rendering_server_default.h"
+#include "servers/text/text_server.h"
 #include "servers/text/text_server_dummy.h"
-#include "servers/text_server.h"
 
 // 2D
 #ifndef NAVIGATION_2D_DISABLED
-#include "servers/navigation_server_2d.h"
-#include "servers/navigation_server_2d_dummy.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d_dummy.h"
 #endif // NAVIGATION_2D_DISABLED
 
 #ifndef PHYSICS_2D_DISABLED
-#include "servers/physics_server_2d.h"
-#include "servers/physics_server_2d_dummy.h"
+#include "servers/physics_2d/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d_dummy.h"
 #endif // PHYSICS_2D_DISABLED
 
 // 3D
 #ifndef NAVIGATION_3D_DISABLED
-#include "servers/navigation_server_3d.h"
-#include "servers/navigation_server_3d_dummy.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_server_3d_dummy.h"
 #endif // NAVIGATION_3D_DISABLED
 
 #ifndef PHYSICS_3D_DISABLED
-#include "servers/physics_server_3d.h"
-#include "servers/physics_server_3d_dummy.h"
+#include "servers/physics_3d/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d_dummy.h"
 #endif // PHYSICS_3D_DISABLED
 
 #ifndef XR_DISABLED
-#include "servers/xr_server.h"
+#include "servers/xr/xr_server.h"
 #endif // XR_DISABLED
 
 #ifdef TESTS_ENABLED

+ 1 - 1
main/main_timer_sync.cpp

@@ -31,7 +31,7 @@
 #include "main_timer_sync.h"
 
 #include "core/os/os.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void MainFrameTime::clamp_process_step(double min_process_step, double max_process_step) {
 	if (process_step < min_process_step) {

+ 11 - 6
main/performance.cpp

@@ -34,21 +34,23 @@
 #include "core/variant/typed_array.h"
 #include "scene/main/node.h"
 #include "scene/main/scene_tree.h"
-#include "servers/audio_server.h"
+#include "servers/audio/audio_server.h"
+#include "servers/rendering/rendering_server.h"
+
 #ifndef NAVIGATION_2D_DISABLED
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 #endif // NAVIGATION_2D_DISABLED
+
 #ifndef NAVIGATION_3D_DISABLED
-#include "servers/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 #endif // NAVIGATION_3D_DISABLED
-#include "servers/rendering_server.h"
 
 #ifndef PHYSICS_2D_DISABLED
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 #endif // PHYSICS_2D_DISABLED
 
 #ifndef PHYSICS_3D_DISABLED
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 #endif // PHYSICS_3D_DISABLED
 
 Performance *Performance::singleton = nullptr;
@@ -307,6 +309,7 @@ double Performance::get_monitor(Monitor p_monitor) const {
 		case AUDIO_OUTPUT_LATENCY:
 			return AudioServer::get_singleton()->get_output_latency();
 
+			// Deprecated, use the 2D/3D specific ones instead.
 		case NAVIGATION_ACTIVE_MAPS:
 #ifndef NAVIGATION_2D_DISABLED
 			info = NavigationServer2D::get_singleton()->get_process_info(NavigationServer2D::INFO_ACTIVE_MAPS);
@@ -503,6 +506,7 @@ Performance::MonitorType Performance::get_monitor_type(Monitor p_monitor) const
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
+#ifndef _3D_DISABLED
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
@@ -513,6 +517,7 @@ Performance::MonitorType Performance::get_monitor_type(Monitor p_monitor) const
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
 		MONITOR_TYPE_QUANTITY,
+#endif // _3D_DISABLED
 
 	};
 	static_assert((sizeof(types) / sizeof(MonitorType)) == MONITOR_MAX);

+ 3 - 0
main/performance.h

@@ -91,6 +91,7 @@ public:
 		PHYSICS_3D_COLLISION_PAIRS,
 		PHYSICS_3D_ISLAND_COUNT,
 		AUDIO_OUTPUT_LATENCY,
+		// Deprecated, use the 2D/3D specific ones instead.
 		NAVIGATION_ACTIVE_MAPS,
 		NAVIGATION_REGION_COUNT,
 		NAVIGATION_AGENT_COUNT,
@@ -116,6 +117,7 @@ public:
 		NAVIGATION_2D_EDGE_CONNECTION_COUNT,
 		NAVIGATION_2D_EDGE_FREE_COUNT,
 		NAVIGATION_2D_OBSTACLE_COUNT,
+#ifndef _3D_DISABLED
 		NAVIGATION_3D_ACTIVE_MAPS,
 		NAVIGATION_3D_REGION_COUNT,
 		NAVIGATION_3D_AGENT_COUNT,
@@ -126,6 +128,7 @@ public:
 		NAVIGATION_3D_EDGE_CONNECTION_COUNT,
 		NAVIGATION_3D_EDGE_FREE_COUNT,
 		NAVIGATION_3D_OBSTACLE_COUNT,
+#endif // _3D_DISABLED
 		MONITOR_MAX
 	};
 

+ 1 - 1
modules/basis_universal/image_compress_basisu.cpp

@@ -34,7 +34,7 @@
 #include "core/io/image.h"
 #include "core/os/os.h"
 #include "core/string/print_string.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #include <transcoder/basisu_transcoder.h>
 #ifdef TOOLS_ENABLED

+ 1 - 1
modules/betsy/image_compress_betsy.cpp

@@ -38,7 +38,7 @@
 #include "bc1.glsl.gen.h"
 #include "bc4.glsl.gen.h"
 #include "bc6h.glsl.gen.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 static Mutex betsy_mutex;
 static BetsyCompressor *betsy = nullptr;

+ 1 - 1
modules/camera/camera_android.h

@@ -31,7 +31,7 @@
 #pragma once
 
 #include "servers/camera/camera_feed.h"
-#include "servers/camera_server.h"
+#include "servers/camera/camera_server.h"
 
 #include <camera/NdkCameraDevice.h>
 #include <camera/NdkCameraError.h>

+ 1 - 1
modules/camera/camera_feed_linux.cpp

@@ -30,7 +30,7 @@
 
 #include "camera_feed_linux.h"
 
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #include <fcntl.h>
 #include <sys/ioctl.h>

+ 1 - 1
modules/camera/camera_linux.h

@@ -32,7 +32,7 @@
 
 #include "core/os/mutex.h"
 #include "core/os/thread.h"
-#include "servers/camera_server.h"
+#include "servers/camera/camera_server.h"
 
 class CameraLinux : public CameraServer {
 private:

+ 1 - 1
modules/camera/camera_macos.h

@@ -33,7 +33,7 @@
 ///@TODO this is a near duplicate of CameraIOS, we should find a way to combine those to minimize code duplication!!!!
 // If you fix something here, make sure you fix it there as well!
 
-#include "servers/camera_server.h"
+#include "servers/camera/camera_server.h"
 
 class CameraMacOS : public CameraServer {
 	GDSOFTCLASS(CameraMacOS, CameraServer);

+ 1 - 1
modules/camera/camera_win.h

@@ -31,7 +31,7 @@
 #pragma once
 
 #include "servers/camera/camera_feed.h"
-#include "servers/camera_server.h"
+#include "servers/camera/camera_server.h"
 
 class CameraWindows : public CameraServer {
 private:

+ 1 - 1
modules/csg/csg_shape.cpp

@@ -37,7 +37,7 @@
 #include "scene/resources/3d/navigation_mesh_source_geometry_data_3d.h"
 #include "scene/resources/navigation_mesh.h"
 #ifndef NAVIGATION_3D_DISABLED
-#include "servers/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 #endif // NAVIGATION_3D_DISABLED
 
 #include <manifold/manifold.h>

+ 1 - 1
modules/gdscript/gdscript_parser.cpp

@@ -40,7 +40,7 @@
 
 #ifdef DEBUG_ENABLED
 #include "core/string/string_builder.h"
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 #endif
 
 #ifdef TOOLS_ENABLED

+ 1 - 1
modules/gdscript/gdscript_tokenizer.cpp

@@ -34,7 +34,7 @@
 #include "core/string/char_utils.h"
 
 #ifdef DEBUG_ENABLED
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 #endif
 
 #ifdef TOOLS_ENABLED

+ 1 - 1
modules/gdscript/language_server/gdscript_text_document.cpp

@@ -36,7 +36,7 @@
 
 #include "editor/script/script_text_editor.h"
 #include "editor/settings/editor_settings.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 
 void GDScriptTextDocument::_bind_methods() {
 	ClassDB::bind_method(D_METHOD("didOpen"), &GDScriptTextDocument::didOpen);

+ 1 - 1
modules/godot_physics_2d/godot_area_2d.h

@@ -33,7 +33,7 @@
 #include "godot_collision_object_2d.h"
 
 #include "core/templates/self_list.h"
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 
 class GodotSpace2D;
 class GodotBody2D;

+ 1 - 1
modules/godot_physics_2d/godot_body_direct_state_2d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 
 class GodotBody2D;
 

+ 1 - 1
modules/godot_physics_2d/godot_collision_object_2d.h

@@ -34,7 +34,7 @@
 #include "godot_shape_2d.h"
 
 #include "core/templates/self_list.h"
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 
 class GodotSpace2D;
 

+ 1 - 1
modules/godot_physics_2d/godot_physics_server_2d.h

@@ -36,7 +36,7 @@
 #include "godot_step_2d.h"
 
 #include "core/templates/rid_owner.h"
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 
 class GodotPhysicsServer2D : public PhysicsServer2D {
 	GDCLASS(GodotPhysicsServer2D, PhysicsServer2D);

+ 1 - 1
modules/godot_physics_2d/godot_shape_2d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d.h"
 
 class GodotShape2D;
 

+ 2 - 2
modules/godot_physics_2d/register_types.cpp

@@ -32,8 +32,8 @@
 
 #include "core/config/project_settings.h"
 #include "godot_physics_server_2d.h"
-#include "servers/physics_server_2d.h"
-#include "servers/physics_server_2d_wrap_mt.h"
+#include "servers/physics_2d/physics_server_2d.h"
+#include "servers/physics_2d/physics_server_2d_wrap_mt.h"
 
 static PhysicsServer2D *_createGodotPhysics2DCallback() {
 #ifdef THREADS_ENABLED

+ 1 - 1
modules/godot_physics_3d/godot_area_3d.h

@@ -33,7 +33,7 @@
 #include "godot_collision_object_3d.h"
 
 #include "core/templates/self_list.h"
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class GodotSpace3D;
 class GodotBody3D;

+ 1 - 1
modules/godot_physics_3d/godot_body_direct_state_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class GodotBody3D;
 

+ 1 - 1
modules/godot_physics_3d/godot_collision_object_3d.h

@@ -34,7 +34,7 @@
 #include "godot_shape_3d.h"
 
 #include "core/templates/self_list.h"
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #ifdef DEBUG_ENABLED
 #define MAX_OBJECT_DISTANCE 3.1622776601683791e+18

+ 1 - 1
modules/godot_physics_3d/godot_physics_server_3d.h

@@ -36,7 +36,7 @@
 #include "godot_step_3d.h"
 
 #include "core/templates/rid_owner.h"
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class GodotPhysicsServer3D : public PhysicsServer3D {
 	GDCLASS(GodotPhysicsServer3D, PhysicsServer3D);

+ 1 - 1
modules/godot_physics_3d/godot_shape_3d.h

@@ -32,7 +32,7 @@
 
 #include "core/math/geometry_3d.h"
 #include "core/templates/local_vector.h"
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class GodotShape3D;
 

+ 1 - 1
modules/godot_physics_3d/godot_soft_body_3d.cpp

@@ -33,7 +33,7 @@
 #include "godot_space_3d.h"
 
 #include "core/math/geometry_3d.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 // Based on Bullet soft body.
 

+ 2 - 2
modules/godot_physics_3d/register_types.cpp

@@ -31,8 +31,8 @@
 #include "register_types.h"
 
 #include "godot_physics_server_3d.h"
-#include "servers/physics_server_3d.h"
-#include "servers/physics_server_3d_wrap_mt.h"
+#include "servers/physics_3d/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d_wrap_mt.h"
 
 static PhysicsServer3D *_createGodotPhysics3DCallback() {
 #ifdef THREADS_ENABLED

+ 2 - 2
modules/gridmap/grid_map.cpp

@@ -35,7 +35,7 @@
 #include "scene/resources/3d/mesh_library.h"
 #include "scene/resources/3d/primitive_meshes.h"
 #include "scene/resources/surface_tool.h"
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #ifndef PHYSICS_3D_DISABLED
 #include "core/math/convex_hull.h"
@@ -52,7 +52,7 @@
 
 #ifndef NAVIGATION_3D_DISABLED
 #include "scene/resources/3d/navigation_mesh_source_geometry_data_3d.h"
-#include "servers/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 
 Callable GridMap::_navmesh_source_geometry_parsing_callback;
 RID GridMap::_navmesh_source_geometry_parser;

+ 1 - 1
modules/jolt_physics/joints/jolt_joint_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #include "Jolt/Jolt.h"
 

+ 1 - 1
modules/jolt_physics/jolt_physics_server_3d.cpp

@@ -39,7 +39,7 @@
 #include "objects/jolt_area_3d.h"
 #include "objects/jolt_body_3d.h"
 #include "objects/jolt_soft_body_3d.h"
-#include "servers/physics_server_3d_wrap_mt.h"
+#include "servers/physics_3d/physics_server_3d_wrap_mt.h"
 #include "shapes/jolt_box_shape_3d.h"
 #include "shapes/jolt_capsule_shape_3d.h"
 #include "shapes/jolt_concave_polygon_shape_3d.h"

+ 1 - 1
modules/jolt_physics/jolt_physics_server_3d.h

@@ -31,7 +31,7 @@
 #pragma once
 
 #include "core/templates/rid_owner.h"
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class JoltArea3D;
 class JoltBody3D;

+ 1 - 1
modules/jolt_physics/objects/jolt_area_3d.h

@@ -32,7 +32,7 @@
 
 #include "jolt_shaped_object_3d.h"
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class JoltBody3D;
 class JoltSoftBody3D;

+ 1 - 1
modules/jolt_physics/objects/jolt_physics_direct_body_state_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 class JoltBody3D;
 

+ 1 - 1
modules/jolt_physics/objects/jolt_soft_body_3d.cpp

@@ -38,7 +38,7 @@
 #include "jolt_body_3d.h"
 #include "jolt_group_filter.h"
 
-#include "servers/rendering_server.h"
+#include "servers/rendering/rendering_server.h"
 
 #include "Jolt/Physics/SoftBody/SoftBodyMotionProperties.h"
 

+ 1 - 1
modules/jolt_physics/objects/jolt_soft_body_3d.h

@@ -32,7 +32,7 @@
 
 #include "jolt_object_3d.h"
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #include "Jolt/Jolt.h"
 

+ 1 - 1
modules/jolt_physics/register_types.cpp

@@ -34,7 +34,7 @@
 #include "jolt_physics_server_3d.h"
 #include "jolt_project_settings.h"
 
-#include "servers/physics_server_3d_wrap_mt.h"
+#include "servers/physics_3d/physics_server_3d_wrap_mt.h"
 
 PhysicsServer3D *create_jolt_physics_server() {
 #ifdef THREADS_ENABLED

+ 1 - 1
modules/jolt_physics/shapes/jolt_shape_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #include "Jolt/Jolt.h"
 

+ 1 - 1
modules/jolt_physics/spaces/jolt_physics_direct_space_state_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #include "Jolt/Jolt.h"
 

+ 1 - 1
modules/jolt_physics/spaces/jolt_space_3d.h

@@ -30,7 +30,7 @@
 
 #pragma once
 
-#include "servers/physics_server_3d.h"
+#include "servers/physics_3d/physics_server_3d.h"
 
 #include "Jolt/Jolt.h"
 

+ 1 - 1
modules/mobile_vr/mobile_vr_interface.cpp

@@ -32,7 +32,7 @@
 
 #include "core/input/input.h"
 #include "core/os/os.h"
-#include "servers/display_server.h"
+#include "servers/display/display_server.h"
 #include "servers/rendering/renderer_compositor.h"
 
 StringName MobileVRInterface::get_name() const {

+ 1 - 1
modules/mono/csharp_script.cpp

@@ -55,7 +55,7 @@
 #include "core/os/mutex.h"
 #include "core/os/os.h"
 #include "core/os/thread.h"
-#include "servers/text_server.h"
+#include "servers/text/text_server.h"
 
 #ifdef TOOLS_ENABLED
 #include "core/os/keyboard.h"

+ 3 - 3
modules/navigation_2d/2d/godot_navigation_server_2d.h

@@ -39,9 +39,9 @@
 #include "core/templates/local_vector.h"
 #include "core/templates/rid.h"
 #include "core/templates/rid_owner.h"
-#include "servers/navigation/navigation_path_query_parameters_2d.h"
-#include "servers/navigation/navigation_path_query_result_2d.h"
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_path_query_parameters_2d.h"
+#include "servers/navigation_2d/navigation_path_query_result_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 /// The commands are functions executed during the `sync` phase.
 

+ 3 - 3
modules/navigation_2d/2d/nav_base_iteration_2d.h

@@ -33,7 +33,7 @@
 #include "../nav_utils_2d.h"
 
 #include "core/object/ref_counted.h"
-#include "servers/navigation/navigation_utilities.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
 
 class NavBaseIteration2D : public RefCounted {
 	GDCLASS(NavBaseIteration2D, RefCounted);
@@ -43,7 +43,7 @@ public:
 	uint32_t navigation_layers = 1;
 	real_t enter_cost = 0.0;
 	real_t travel_cost = 1.0;
-	NavigationUtilities::PathSegmentType owner_type;
+	NavigationEnums2D::PathSegmentType owner_type;
 	ObjectID owner_object_id;
 	RID owner_rid;
 	bool owner_use_edge_connections = false;
@@ -51,7 +51,7 @@ public:
 	LocalVector<LocalVector<Nav2D::Connection>> internal_connections;
 
 	bool get_enabled() const { return enabled; }
-	NavigationUtilities::PathSegmentType get_type() const { return owner_type; }
+	NavigationEnums2D::PathSegmentType get_type() const { return owner_type; }
 	RID get_self() const { return owner_rid; }
 	ObjectID get_owner_id() const { return owner_object_id; }
 	uint32_t get_navigation_layers() const { return navigation_layers; }

+ 1 - 1
modules/navigation_2d/2d/nav_mesh_generator_2d.h

@@ -35,7 +35,7 @@
 #include "core/object/class_db.h"
 #include "core/object/worker_thread_pool.h"
 #include "core/templates/rid_owner.h"
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 class Node;
 class NavigationPolygon;

+ 3 - 4
modules/navigation_2d/2d/nav_mesh_queries_2d.cpp

@@ -36,7 +36,6 @@
 #include "nav_region_iteration_2d.h"
 
 #include "core/math/geometry_2d.h"
-#include "servers/navigation/navigation_utilities.h"
 
 using namespace Nav2D;
 
@@ -151,7 +150,7 @@ void NavMeshQueries2D::map_query_path(NavMap2D *p_map, const Ref<NavigationPathQ
 	ERR_FAIL_COND(p_query_parameters.is_null());
 	ERR_FAIL_COND(p_query_result.is_null());
 
-	using namespace NavigationUtilities;
+	using namespace NavigationDefaults2D;
 
 	NavMeshQueries2D::NavMeshPathQueryTask2D query_task;
 	query_task.start_position = p_query_parameters->get_start_position();
@@ -1156,7 +1155,7 @@ bool NavMeshQueries2D::_query_task_is_connection_owner_usable(const NavMeshPathQ
 
 	if (p_query_task.exclude_regions || p_query_task.include_regions) {
 		switch (p_owner->get_type()) {
-			case NavigationUtilities::PathSegmentType::PATH_SEGMENT_TYPE_REGION: {
+			case NavigationEnums2D::PathSegmentType::PATH_SEGMENT_TYPE_REGION: {
 				if (p_query_task.exclude_regions && p_query_task.excluded_regions.has(p_owner->get_self())) {
 					// Not usable. Exclude region filter is active and this region is excluded.
 					owner_usable = false;
@@ -1165,7 +1164,7 @@ bool NavMeshQueries2D::_query_task_is_connection_owner_usable(const NavMeshPathQ
 					owner_usable = false;
 				}
 			} break;
-			case NavigationUtilities::PathSegmentType::PATH_SEGMENT_TYPE_LINK: {
+			case NavigationEnums2D::PathSegmentType::PATH_SEGMENT_TYPE_LINK: {
 				const LocalVector<Polygon> &link_polygons = p_owner->get_navmesh_polygons();
 				if (link_polygons.size() != 2) {
 					// Not usable. Whatever this is, it is not a valid connected link.

+ 6 - 5
modules/navigation_2d/2d/nav_mesh_queries_2d.h

@@ -34,12 +34,13 @@
 
 #include "core/templates/a_hash_map.h"
 
-#include "servers/navigation/navigation_globals.h"
-#include "servers/navigation/navigation_path_query_parameters_2d.h"
-#include "servers/navigation/navigation_path_query_result_2d.h"
-#include "servers/navigation/navigation_utilities.h"
+#include "servers/nav_heap.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
+#include "servers/navigation_2d/navigation_path_query_parameters_2d.h"
+#include "servers/navigation_2d/navigation_path_query_result_2d.h"
 
-using namespace NavigationUtilities;
+using namespace NavigationDefaults2D;
+using namespace NavigationEnums2D;
 
 class NavMap2D;
 struct NavMapIteration2D;

+ 1 - 1
modules/navigation_2d/nav_agent_2d.h

@@ -34,7 +34,7 @@
 
 #include "core/object/class_db.h"
 #include "core/templates/self_list.h"
-#include "servers/navigation/navigation_globals.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
 
 #include <Agent2d.h>
 

+ 3 - 3
modules/navigation_2d/nav_base_2d.h

@@ -33,7 +33,7 @@
 #include "nav_rid_2d.h"
 #include "nav_utils_2d.h"
 
-#include "servers/navigation/navigation_utilities.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
 
 class NavMap2D;
 
@@ -43,10 +43,10 @@ protected:
 	real_t enter_cost = 0.0;
 	real_t travel_cost = 1.0;
 	ObjectID owner_id;
-	NavigationUtilities::PathSegmentType type;
+	NavigationEnums2D::PathSegmentType type;
 
 public:
-	NavigationUtilities::PathSegmentType get_type() const { return type; }
+	NavigationEnums2D::PathSegmentType get_type() const { return type; }
 
 	virtual void set_use_edge_connections(bool p_enabled) {}
 	virtual bool get_use_edge_connections() const { return false; }

+ 1 - 1
modules/navigation_2d/nav_link_2d.cpp

@@ -203,7 +203,7 @@ Ref<NavLinkIteration2D> NavLink2D::get_iteration() {
 
 NavLink2D::NavLink2D() :
 		sync_dirty_request_list_element(this) {
-	type = NavigationUtilities::PathSegmentType::PATH_SEGMENT_TYPE_LINK;
+	type = NavigationEnums2D::PathSegmentType::PATH_SEGMENT_TYPE_LINK;
 	iteration.instantiate();
 }
 

+ 1 - 1
modules/navigation_2d/nav_map_2d.cpp

@@ -40,7 +40,7 @@
 
 #include "core/config/project_settings.h"
 #include "core/object/worker_thread_pool.h"
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 #include <Obstacle2d.h>
 

+ 1 - 1
modules/navigation_2d/nav_map_2d.h

@@ -37,7 +37,7 @@
 
 #include "core/math/math_defs.h"
 #include "core/object/worker_thread_pool.h"
-#include "servers/navigation/navigation_globals.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
 
 #include <KdTree2d.h>
 #include <RVOSimulator2d.h>

+ 1 - 1
modules/navigation_2d/nav_region_2d.cpp

@@ -338,7 +338,7 @@ bool NavRegion2D::get_use_async_iterations() const {
 
 NavRegion2D::NavRegion2D() :
 		sync_dirty_request_list_element(this), async_list_element(this) {
-	type = NavigationUtilities::PathSegmentType::PATH_SEGMENT_TYPE_REGION;
+	type = NavigationEnums2D::PathSegmentType::PATH_SEGMENT_TYPE_REGION;
 	iteration_build.region = this;
 	iteration.instantiate();
 

+ 2 - 2
modules/navigation_2d/nav_utils_2d.h

@@ -34,8 +34,8 @@
 #include "core/object/ref_counted.h"
 #include "core/templates/hash_map.h"
 #include "core/templates/hashfuncs.h"
-#include "servers/navigation/nav_heap.h"
-#include "servers/navigation/navigation_utilities.h"
+#include "core/templates/local_vector.h"
+#include "servers/navigation_2d/navigation_constants_2d.h"
 
 class NavBaseIteration2D;
 

+ 1 - 1
modules/navigation_2d/register_types.cpp

@@ -33,7 +33,7 @@
 #include "2d/godot_navigation_server_2d.h"
 
 #include "core/config/engine.h"
-#include "servers/navigation_server_2d.h"
+#include "servers/navigation_2d/navigation_server_2d.h"
 
 #ifdef TOOLS_ENABLED
 #include "editor/navigation_link_2d_editor_plugin.h"

+ 1 - 1
modules/navigation_3d/3d/godot_navigation_server_3d.cpp

@@ -35,7 +35,7 @@
 
 #include "nav_mesh_generator_3d.h"
 
-using namespace NavigationUtilities;
+using namespace NavigationDefaults3D;
 
 /// Creates a struct for each function and a function that once called creates
 /// an instance of that struct with the submitted parameters.

+ 3 - 3
modules/navigation_3d/3d/godot_navigation_server_3d.h

@@ -39,9 +39,9 @@
 #include "core/templates/local_vector.h"
 #include "core/templates/rid.h"
 #include "core/templates/rid_owner.h"
-#include "servers/navigation/navigation_path_query_parameters_3d.h"
-#include "servers/navigation/navigation_path_query_result_3d.h"
-#include "servers/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_path_query_parameters_3d.h"
+#include "servers/navigation_3d/navigation_path_query_result_3d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 
 /// The commands are functions executed during the `sync` phase.
 

+ 3 - 3
modules/navigation_3d/3d/nav_base_iteration_3d.h

@@ -33,7 +33,7 @@
 #include "../nav_utils_3d.h"
 
 #include "core/object/ref_counted.h"
-#include "servers/navigation/navigation_utilities.h"
+#include "servers/navigation_3d/navigation_constants_3d.h"
 
 class NavBaseIteration3D : public RefCounted {
 	GDCLASS(NavBaseIteration3D, RefCounted);
@@ -43,7 +43,7 @@ public:
 	uint32_t navigation_layers = 1;
 	real_t enter_cost = 0.0;
 	real_t travel_cost = 1.0;
-	NavigationUtilities::PathSegmentType owner_type;
+	NavigationEnums3D::PathSegmentType owner_type;
 	ObjectID owner_object_id;
 	RID owner_rid;
 	bool owner_use_edge_connections = false;
@@ -51,7 +51,7 @@ public:
 	LocalVector<LocalVector<Nav3D::Connection>> internal_connections;
 
 	bool get_enabled() const { return enabled; }
-	NavigationUtilities::PathSegmentType get_type() const { return owner_type; }
+	NavigationEnums3D::PathSegmentType get_type() const { return owner_type; }
 	RID get_self() const { return owner_rid; }
 	ObjectID get_owner_id() const { return owner_object_id; }
 	uint32_t get_navigation_layers() const { return navigation_layers; }

+ 1 - 1
modules/navigation_3d/3d/nav_mesh_generator_3d.h

@@ -33,7 +33,7 @@
 #include "core/object/class_db.h"
 #include "core/object/worker_thread_pool.h"
 #include "core/templates/rid_owner.h"
-#include "servers/navigation_server_3d.h"
+#include "servers/navigation_3d/navigation_server_3d.h"
 
 class Node;
 class NavigationMesh;

Деякі файли не було показано, через те що забагато файлів було змінено