From 029a6671b4bccb571b9c6ead5af59cd9cf8c8f1b Mon Sep 17 00:00:00 2001 From: Relintai Date: Wed, 5 Oct 2022 15:19:59 +0200 Subject: [PATCH] Moved from the TERRAMAN_2D_PRESENT define to the module system's equivalent define aswell. --- modules/props_2d/SCsub | 3 --- modules/props_2d/prop_2d_mesher.cpp | 2 +- modules/props_2d/prop_2d_mesher.h | 4 ++-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/modules/props_2d/SCsub b/modules/props_2d/SCsub index ac53dfbf9..de7971dc7 100644 --- a/modules/props_2d/SCsub +++ b/modules/props_2d/SCsub @@ -6,9 +6,6 @@ module_env = env.Clone() import version -if os.path.isdir('../terraman_2d'): - module_env.Append(CPPDEFINES=['TERRAMAN_2D_PRESENT']) - sources = [ "register_types.cpp", diff --git a/modules/props_2d/prop_2d_mesher.cpp b/modules/props_2d/prop_2d_mesher.cpp index 2b6a318f8..3398ad77f 100644 --- a/modules/props_2d/prop_2d_mesher.cpp +++ b/modules/props_2d/prop_2d_mesher.cpp @@ -871,7 +871,7 @@ void Prop2DMesher::bake_colors_lights() { } } -#ifdef TERRAMAN_2D_PRESENT +#ifdef MODULE_TERRAMAN_2D_ENABLED void Prop2DMesher::bake_lights(MeshInstance *node, Vector> &lights) { /* ERR_FAIL_COND(node == NULL); diff --git a/modules/props_2d/prop_2d_mesher.h b/modules/props_2d/prop_2d_mesher.h index 4651f7e75..e0779dd58 100644 --- a/modules/props_2d/prop_2d_mesher.h +++ b/modules/props_2d/prop_2d_mesher.h @@ -41,7 +41,7 @@ SOFTWARE. #include "../mesh_data_resource/mesh_data_resource.h" #endif -#ifdef TERRAMAN_2D_PRESENT +#ifdef MODULE_TERRAMAN_2D_ENABLED #include "../terraman_2d/data/terrain_2d_light.h" #endif @@ -149,7 +149,7 @@ public: void bake_colors_lights_rao(); void bake_colors_lights(); -#ifdef TERRAMAN_2D_PRESENT +#ifdef MODULE_TERRAMAN_2D_ENABLED void bake_lights(MeshInstance *node, Vector> &lights); #endif