From 3a707b1f54cc7427d7cfc915907ef70802d9aabb Mon Sep 17 00:00:00 2001 From: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> Date: Fri, 23 Feb 2024 12:52:06 +0100 Subject: 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 --- scene/register_scene_types.cpp | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) (limited to 'scene/register_scene_types.cpp') 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 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); -- cgit v1.2.3