From 0aa29d33e4ebf67b06a94b708d70a1bc6d53acb0 Mon Sep 17 00:00:00 2001 From: Shawn Date: Wed, 1 Jul 2026 20:34:15 -0400 Subject: [PATCH] =?UTF-8?q?fix:=20GDExtension=20C++=20build=20=E2=80=94=20?= =?UTF-8?q?fix=20enum=20bitwise=20cast,=20add=20.gdextension=20entry=20fil?= =?UTF-8?q?e?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gdextension/simulation.gdextension | 8 ++++++++ gdextension/simulation/src/entity.cpp | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 gdextension/simulation.gdextension diff --git a/gdextension/simulation.gdextension b/gdextension/simulation.gdextension new file mode 100644 index 0000000..cb8f5c8 --- /dev/null +++ b/gdextension/simulation.gdextension @@ -0,0 +1,8 @@ +[configuration] +entry_symbol = "gdextension_init" +compatibility_minimum = "4.2" + +[libraries] +linux.x86_64 = "res://gdextension/simulation/gdextension/bin/linux/libsimulation.so" +windows.x86_64 = "" +macos.universal = "" diff --git a/gdextension/simulation/src/entity.cpp b/gdextension/simulation/src/entity.cpp index a1badb8..a5bd38e 100644 --- a/gdextension/simulation/src/entity.cpp +++ b/gdextension/simulation/src/entity.cpp @@ -54,7 +54,7 @@ EntitySnapshot Entity::capture_snapshot() const { } EntitySnapshot::ChangeMask Entity::compute_change_mask(const EntitySnapshot &base) const { - EntitySnapshot::ChangeMask mask = EntitySnapshot::CHANGED_NONE; + uint32_t mask = EntitySnapshot::CHANGED_NONE; if (position_ != base.position) mask |= EntitySnapshot::CHANGED_POSITION; if (velocity_ != base.velocity) mask |= EntitySnapshot::CHANGED_VELOCITY; @@ -67,7 +67,7 @@ EntitySnapshot::ChangeMask Entity::compute_change_mask(const EntitySnapshot &bas if (last_input_.input_sequence != base.last_processed_input) mask |= EntitySnapshot::CHANGED_INPUT; - return mask; + return static_cast(mask); } // ---- GDScript Bindings -------------------------------------------------------