summaryrefslogtreecommitdiffstats
path: root/scene/register_scene_types.cpp
diff options
context:
space:
mode:
authorA Thousand Ships <96648715+AThousandShips@users.noreply.github.com>2024-02-23 12:52:06 +0100
committerA Thousand Ships <96648715+AThousandShips@users.noreply.github.com>2024-02-23 20:58:56 +0100
commit3a707b1f54cc7427d7cfc915907ef70802d9aabb (patch)
treefe1c1e702fa21eee9ac0b4988ebc303cfd65be14 /scene/register_scene_types.cpp
parent87d40ba743ff3a3a484db051c11b16559604efa9 (diff)
downloadredot-engine-3a707b1f54cc7427d7cfc915907ef70802d9aabb.tar.gz
Fix some additional errors with 3D disabled
* Disabled 2D navigation tests as they do not work * Disabled tests for primitive meshes * Unbound some `Mesh` methods that rely on 3D resources * Unexposed `World3D` as it depends on physics (and isn't useful) * Unexposed some `Viewport` vrs related properties that had unexposed methods
Diffstat (limited to 'scene/register_scene_types.cpp')
-rw-r--r--scene/register_scene_types.cpp25
1 files changed, 12 insertions, 13 deletions
diff --git a/scene/register_scene_types.cpp b/scene/register_scene_types.cpp
index 18e96454ba..3aa4dd4457 100644
--- a/scene/register_scene_types.cpp
+++ b/scene/register_scene_types.cpp
@@ -147,25 +147,19 @@
#include "scene/resources/audio_stream_wav.h"
#include "scene/resources/bit_map.h"
#include "scene/resources/bone_map.h"
-#include "scene/resources/box_shape_3d.h"
#include "scene/resources/camera_attributes.h"
#include "scene/resources/camera_texture.h"
#include "scene/resources/capsule_shape_2d.h"
-#include "scene/resources/capsule_shape_3d.h"
#include "scene/resources/circle_shape_2d.h"
#include "scene/resources/compositor.h"
#include "scene/resources/compressed_texture.h"
#include "scene/resources/concave_polygon_shape_2d.h"
-#include "scene/resources/concave_polygon_shape_3d.h"
#include "scene/resources/convex_polygon_shape_2d.h"
-#include "scene/resources/convex_polygon_shape_3d.h"
#include "scene/resources/curve_texture.h"
-#include "scene/resources/cylinder_shape_3d.h"
#include "scene/resources/environment.h"
#include "scene/resources/font.h"
#include "scene/resources/gradient.h"
#include "scene/resources/gradient_texture.h"
-#include "scene/resources/height_map_shape_3d.h"
#include "scene/resources/image_texture.h"
#include "scene/resources/immediate_mesh.h"
#include "scene/resources/label_settings.h"
@@ -183,12 +177,10 @@
#include "scene/resources/placeholder_textures.h"
#include "scene/resources/polygon_path_finder.h"
#include "scene/resources/portable_compressed_texture.h"
-#include "scene/resources/primitive_meshes.h"
#include "scene/resources/rectangle_shape_2d.h"
#include "scene/resources/resource_format_text.h"
#include "scene/resources/segment_shape_2d.h"
#include "scene/resources/separation_ray_shape_2d.h"
-#include "scene/resources/separation_ray_shape_3d.h"
#include "scene/resources/shader_include.h"
#include "scene/resources/skeleton_modification_2d.h"
#include "scene/resources/skeleton_modification_2d_ccdik.h"
@@ -202,7 +194,6 @@
#include "scene/resources/skeleton_profile.h"
#include "scene/resources/sky.h"
#include "scene/resources/sky_material.h"
-#include "scene/resources/sphere_shape_3d.h"
#include "scene/resources/style_box.h"
#include "scene/resources/style_box_flat.h"
#include "scene/resources/style_box_line.h"
@@ -222,9 +213,7 @@
#include "scene/resources/visual_shader_particle_nodes.h"
#include "scene/resources/visual_shader_sdf_nodes.h"
#include "scene/resources/world_2d.h"
-#include "scene/resources/world_3d.h"
#include "scene/resources/world_boundary_shape_2d.h"
-#include "scene/resources/world_boundary_shape_3d.h"
#include "scene/scene_string_names.h"
#include "scene/theme/theme_db.h"
@@ -276,10 +265,20 @@
#include "scene/3d/xr_face_modifier_3d.h"
#include "scene/3d/xr_nodes.h"
#include "scene/animation/root_motion_view.h"
-#include "scene/resources/environment.h"
+#include "scene/resources/box_shape_3d.h"
+#include "scene/resources/capsule_shape_3d.h"
+#include "scene/resources/concave_polygon_shape_3d.h"
+#include "scene/resources/convex_polygon_shape_3d.h"
+#include "scene/resources/cylinder_shape_3d.h"
#include "scene/resources/fog_material.h"
+#include "scene/resources/height_map_shape_3d.h"
#include "scene/resources/importer_mesh.h"
#include "scene/resources/mesh_library.h"
+#include "scene/resources/primitive_meshes.h"
+#include "scene/resources/separation_ray_shape_3d.h"
+#include "scene/resources/sphere_shape_3d.h"
+#include "scene/resources/world_3d.h"
+#include "scene/resources/world_boundary_shape_3d.h"
#endif // _3D_DISABLED
static Ref<ResourceFormatSaverText> resource_saver_text;
@@ -864,12 +863,12 @@ void register_scene_types() {
GDREGISTER_CLASS(WorldBoundaryShape3D);
GDREGISTER_CLASS(ConvexPolygonShape3D);
GDREGISTER_CLASS(ConcavePolygonShape3D);
+ GDREGISTER_CLASS(World3D);
OS::get_singleton()->yield(); // may take time to init
#endif // _3D_DISABLED
GDREGISTER_CLASS(PhysicsMaterial);
- GDREGISTER_CLASS(World3D);
GDREGISTER_CLASS(Compositor);
GDREGISTER_CLASS(Environment);
GDREGISTER_VIRTUAL_CLASS(CameraAttributes);