diff options
Diffstat (limited to 'scene/3d/skeleton.h')
-rw-r--r-- | scene/3d/skeleton.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/scene/3d/skeleton.h b/scene/3d/skeleton.h index f0e71c8b4f..9672acb57a 100644 --- a/scene/3d/skeleton.h +++ b/scene/3d/skeleton.h @@ -38,7 +38,10 @@ @author Juan Linietsky <reduzio@gmail.com> */ +#ifndef _3D_DISABLED class PhysicalBone; +#endif // _3D_DISABLED + class Skeleton : public Spatial { GDCLASS(Skeleton, Spatial); @@ -64,8 +67,10 @@ class Skeleton : public Spatial { Transform transform_final; +#ifndef _3D_DISABLED PhysicalBone *physical_bone; PhysicalBone *cache_parent_physical_bone; +#endif // _3D_DISABLED List<uint32_t> nodes_bound; @@ -75,8 +80,10 @@ class Skeleton : public Spatial { ignore_animation = false; custom_pose_enable = false; disable_rest = false; +#ifndef _3D_DISABLED physical_bone = NULL; cache_parent_physical_bone = NULL; +#endif // _3D_DISABLED } }; @@ -120,9 +127,11 @@ public: // skeleton creation api void add_bone(const String &p_name); - int find_bone(String p_name) const; + int find_bone(const String &p_name) const; String get_bone_name(int p_bone) const; + bool is_bone_parent_of(int p_bone_id, int p_parent_bone_id) const; + void set_bone_parent(int p_bone, int p_parent); int get_bone_parent(int p_bone) const; @@ -162,6 +171,7 @@ public: void localize_rests(); // used for loaders and tools +#ifndef _3D_DISABLED // Physical bone API void bind_physical_bone_to_bone(int p_bone, PhysicalBone *p_physical_bone); @@ -176,9 +186,11 @@ private: void _rebuild_physical_bones_cache(); public: - void physical_bones_simulation(bool start); + void physical_bones_stop_simulation(); + void physical_bones_start_simulation_on(const Array &p_bones); void physical_bones_add_collision_exception(RID p_exception); void physical_bones_remove_collision_exception(RID p_exception); +#endif // _3D_DISABLED public: Skeleton(); |