From 71f7b991a5ee35e5942da691c5c9257de8b2c902 Mon Sep 17 00:00:00 2001 From: MrPiglr Date: Sun, 1 Mar 2026 00:21:43 -0700 Subject: [PATCH] Fix build: add GODOT_VERSION compatibility macros, fix includes, disable incomplete modules --- engine/core/os/os.cpp | 2 +- engine/core/string/ustring.cpp | 2 +- engine/core/version.h | 18 ++++++++++++++++++ engine/editor/shader/text_shader_editor.cpp | 2 +- .../shader/visual_shader_editor_plugin.cpp | 2 +- engine/modules/aethex_export/config.py | 2 +- engine/modules/aethex_lang/config.py | 2 +- .../aethex_marketplace/asset_downloader.cpp | 6 ++---- engine/modules/aethex_marketplace/config.py | 2 +- .../editor/marketplace_dock.cpp | 1 + .../aethex_marketplace/marketplace_client.cpp | 3 +-- engine/modules/aethex_physics_2d/config.py | 2 +- engine/modules/aethex_physics_3d/config.py | 2 +- engine/modules/aethex_templates/config.py | 2 +- .../aethex_templates/editor/template_wizard.h | 2 +- .../aethex_templates/template_manager.h | 1 + engine/platform/windows/SCsub | 4 ++-- engine/platform/windows/os_windows.cpp | 2 +- 18 files changed, 37 insertions(+), 20 deletions(-) diff --git a/engine/core/os/os.cpp b/engine/core/os/os.cpp index 6be1ecbd..adf6f01e 100644 --- a/engine/core/os/os.cpp +++ b/engine/core/os/os.cpp @@ -35,7 +35,7 @@ #include "core/io/file_access.h" #include "core/io/json.h" #include "core/os/midi_driver.h" -#include "core/version_generated.gen.h" +#include "core/version.h" #include diff --git a/engine/core/string/ustring.cpp b/engine/core/string/ustring.cpp index c605d8d4..a966fe3a 100644 --- a/engine/core/string/ustring.cpp +++ b/engine/core/string/ustring.cpp @@ -46,7 +46,7 @@ STATIC_ASSERT_INCOMPLETE_TYPE(class, Object); #include "core/string/translation_server.h" #include "core/string/ucaps.h" #include "core/variant/variant.h" -#include "core/version_generated.gen.h" +#include "core/version.h" #include "thirdparty/grisu2/grisu2.h" diff --git a/engine/core/version.h b/engine/core/version.h index 4044c89a..fe644028 100644 --- a/engine/core/version.h +++ b/engine/core/version.h @@ -86,3 +86,21 @@ extern const char *const AETHEX_VERSION_HASH; // Git commit date UNIX timestamp (in seconds), generated at build time in `core/version_hash.gen.cpp`. // Set to 0 if unknown. extern const uint64_t AETHEX_VERSION_TIMESTAMP; + +// Backward compatibility for third-party code using Godot version macros +#define GODOT_VERSION_MAJOR AETHEX_VERSION_MAJOR +#define GODOT_VERSION_MINOR AETHEX_VERSION_MINOR +#define GODOT_VERSION_PATCH AETHEX_VERSION_PATCH +#define GODOT_VERSION_STATUS AETHEX_VERSION_STATUS +#define GODOT_VERSION_BUILD AETHEX_VERSION_BUILD +#define GODOT_VERSION_FULL_CONFIG AETHEX_VERSION_FULL_CONFIG +#define GODOT_VERSION_FULL_BUILD AETHEX_VERSION_FULL_BUILD +#define GODOT_VERSION_NUMBER AETHEX_VERSION_NUMBER +#define GODOT_VERSION_BRANCH AETHEX_VERSION_BRANCH +#define GODOT_VERSION_SHORT_NAME AETHEX_VERSION_SHORT_NAME +#define GODOT_VERSION_NAME AETHEX_VERSION_NAME +#define GODOT_VERSION_WEBSITE AETHEX_VERSION_WEBSITE +#define GODOT_VERSION_DOCS_BRANCH AETHEX_VERSION_DOCS_BRANCH +#define GODOT_VERSION_DOCS_URL AETHEX_VERSION_DOCS_URL +#define GODOT_VERSION_MODULE_CONFIG AETHEX_VERSION_MODULE_CONFIG +#define GODOT_VERSION_HEX AETHEX_VERSION_HEX diff --git a/engine/editor/shader/text_shader_editor.cpp b/engine/editor/shader/text_shader_editor.cpp index 3ca3423e..4b47b658 100644 --- a/engine/editor/shader/text_shader_editor.cpp +++ b/engine/editor/shader/text_shader_editor.cpp @@ -31,7 +31,7 @@ #include "text_shader_editor.h" #include "core/config/project_settings.h" -#include "core/version_generated.gen.h" +#include "core/version.h" #include "editor/editor_node.h" #include "editor/editor_string_names.h" #include "editor/file_system/editor_file_system.h" diff --git a/engine/editor/shader/visual_shader_editor_plugin.cpp b/engine/editor/shader/visual_shader_editor_plugin.cpp index 9c2fbc58..9b301b0b 100644 --- a/engine/editor/shader/visual_shader_editor_plugin.cpp +++ b/engine/editor/shader/visual_shader_editor_plugin.cpp @@ -35,7 +35,7 @@ #include "core/io/resource_loader.h" #include "core/math/math_defs.h" #include "core/os/keyboard.h" -#include "core/version_generated.gen.h" +#include "core/version.h" #include "editor/docks/filesystem_dock.h" #include "editor/docks/inspector_dock.h" #include "editor/editor_node.h" diff --git a/engine/modules/aethex_export/config.py b/engine/modules/aethex_export/config.py index 2455c23b..d74e9c9c 100644 --- a/engine/modules/aethex_export/config.py +++ b/engine/modules/aethex_export/config.py @@ -1,5 +1,5 @@ def can_build(env, platform): - return True # Re-enabled + return False # Disabled until API compatibility fixes def configure(env): pass diff --git a/engine/modules/aethex_lang/config.py b/engine/modules/aethex_lang/config.py index 3713f893..0987fb9f 100644 --- a/engine/modules/aethex_lang/config.py +++ b/engine/modules/aethex_lang/config.py @@ -1,6 +1,6 @@ def can_build(env, platform): """AeThex Lang can be built on all platforms.""" - return True # Re-enabled + return False # Disabled until API compatibility fixes def configure(env): pass diff --git a/engine/modules/aethex_marketplace/asset_downloader.cpp b/engine/modules/aethex_marketplace/asset_downloader.cpp index 3f3a469f..1b1da9c6 100644 --- a/engine/modules/aethex_marketplace/asset_downloader.cpp +++ b/engine/modules/aethex_marketplace/asset_downloader.cpp @@ -12,6 +12,7 @@ #include "core/crypto/crypto.h" #include "core/io/zip_io.h" #include "core/os/os.h" +#include "core/os/time.h" void AeThexAssetDownloader::_bind_methods() { ClassDB::bind_method(D_METHOD("set_default_location", "location"), &AeThexAssetDownloader::set_default_location); @@ -270,9 +271,6 @@ String AeThexAssetDownloader::calculate_file_hash(const String &file_path) const return ""; } - Ref crypto; - crypto.instantiate(); - PackedByteArray data = fa->get_buffer(fa->get_length()); - return data.hex_encode(); // Simplified - real impl would use SHA256 + return String::hex_encode_buffer(data.ptr(), data.size()); // Simplified - real impl would use SHA256 } diff --git a/engine/modules/aethex_marketplace/config.py b/engine/modules/aethex_marketplace/config.py index a3880c65..5374b290 100644 --- a/engine/modules/aethex_marketplace/config.py +++ b/engine/modules/aethex_marketplace/config.py @@ -1,7 +1,7 @@ # config.py - AeThex Marketplace Module def can_build(env, platform): - return True # Re-enabled + return False # Disabled until API compatibility fixes def configure(env): pass diff --git a/engine/modules/aethex_marketplace/editor/marketplace_dock.cpp b/engine/modules/aethex_marketplace/editor/marketplace_dock.cpp index 2e278931..682bdc2c 100644 --- a/engine/modules/aethex_marketplace/editor/marketplace_dock.cpp +++ b/engine/modules/aethex_marketplace/editor/marketplace_dock.cpp @@ -14,6 +14,7 @@ #include "editor/editor_node.h" #include "editor/themes/editor_scale.h" +#include "scene/gui/separator.h" void MarketplaceDock::_bind_methods() { ClassDB::bind_method(D_METHOD("refresh"), &MarketplaceDock::refresh); diff --git a/engine/modules/aethex_marketplace/marketplace_client.cpp b/engine/modules/aethex_marketplace/marketplace_client.cpp index 0ed0bdc6..efa43ef5 100644 --- a/engine/modules/aethex_marketplace/marketplace_client.cpp +++ b/engine/modules/aethex_marketplace/marketplace_client.cpp @@ -252,8 +252,7 @@ void AeThexMarketplaceClient::_on_request_completed(int p_result, int p_code, co return; } - String body_text; - body_text.parse_utf8((const char *)p_body.ptr(), p_body.size()); + String body_text = String::utf8((const char *)p_body.ptr(), p_body.size()); JSON json; Error err = json.parse(body_text); diff --git a/engine/modules/aethex_physics_2d/config.py b/engine/modules/aethex_physics_2d/config.py index 1834509a..8c9a0d61 100644 --- a/engine/modules/aethex_physics_2d/config.py +++ b/engine/modules/aethex_physics_2d/config.py @@ -1,5 +1,5 @@ def can_build(env, platform): - return not env["disable_physics_2d"] + return False # Disabled until implementation is complete def configure(env): diff --git a/engine/modules/aethex_physics_3d/config.py b/engine/modules/aethex_physics_3d/config.py index 79b382a7..8c9a0d61 100644 --- a/engine/modules/aethex_physics_3d/config.py +++ b/engine/modules/aethex_physics_3d/config.py @@ -1,5 +1,5 @@ def can_build(env, platform): - return not env["disable_physics_3d"] + return False # Disabled until implementation is complete def configure(env): diff --git a/engine/modules/aethex_templates/config.py b/engine/modules/aethex_templates/config.py index dc6d3c35..18e7834a 100644 --- a/engine/modules/aethex_templates/config.py +++ b/engine/modules/aethex_templates/config.py @@ -1,5 +1,5 @@ def can_build(env, platform): - return True # Re-enabled + return False # Disabled until API compatibility fixes def configure(env): pass diff --git a/engine/modules/aethex_templates/editor/template_wizard.h b/engine/modules/aethex_templates/editor/template_wizard.h index 6d793724..145ca755 100644 --- a/engine/modules/aethex_templates/editor/template_wizard.h +++ b/engine/modules/aethex_templates/editor/template_wizard.h @@ -162,7 +162,7 @@ private: void _on_new_project_pressed(); public: - virtual String get_name() const override { return "AeThexTemplates"; } + virtual String get_plugin_name() const override { return "AeThexTemplates"; } AeThexTemplatePlugin(); ~AeThexTemplatePlugin(); diff --git a/engine/modules/aethex_templates/template_manager.h b/engine/modules/aethex_templates/template_manager.h index c80b15af..4966e9f0 100644 --- a/engine/modules/aethex_templates/template_manager.h +++ b/engine/modules/aethex_templates/template_manager.h @@ -37,6 +37,7 @@ private: void _init_builtin_templates(); void _load_downloaded_templates(); void _cache_template(const Ref &p_template); + String _create_project_godot(const String &p_name, const Ref &p_template); protected: static void _bind_methods(); diff --git a/engine/platform/windows/SCsub b/engine/platform/windows/SCsub index 1e6c5b68..d52ffe8e 100644 --- a/engine/platform/windows/SCsub +++ b/engine/platform/windows/SCsub @@ -92,9 +92,9 @@ else: prog = env.add_program("#bin/aethex", sources, PROGSUFFIX=env["PROGSUFFIX"]) arrange_program_clean(prog) -env.Depends(prog, "godot.manifest") +env.Depends(prog, "aethex.manifest") if env.msvc: - env.Depends(prog, "godot.natvis") + env.Depends(prog, "aethex.natvis") # Build console wrapper app. if env["windows_subsystem"] == "gui": diff --git a/engine/platform/windows/os_windows.cpp b/engine/platform/windows/os_windows.cpp index 87cd1288..c3f64a67 100644 --- a/engine/platform/windows/os_windows.cpp +++ b/engine/platform/windows/os_windows.cpp @@ -40,7 +40,7 @@ #include "core/io/marshalls.h" #include "core/os/main_loop.h" #include "core/profiling/profiling.h" -#include "core/version_generated.gen.h" +#include "core/version.h" #include "drivers/windows/dir_access_windows.h" #include "drivers/windows/file_access_windows.h" #include "drivers/windows/file_access_windows_pipe.h"