summaryrefslogtreecommitdiff
path: root/scene/3d/physics_body_3d.h
diff options
context:
space:
mode:
Diffstat (limited to 'scene/3d/physics_body_3d.h')
-rw-r--r--scene/3d/physics_body_3d.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/scene/3d/physics_body_3d.h b/scene/3d/physics_body_3d.h
index 9d45ce3799..0ef9c78f3b 100644
--- a/scene/3d/physics_body_3d.h
+++ b/scene/3d/physics_body_3d.h
@@ -82,13 +82,16 @@ class StaticBody3D : public PhysicsBody3D {
Ref<PhysicsMaterial> physics_material_override;
bool kinematic_motion = false;
+ bool sync_to_physics = false;
+
+ Transform3D last_valid_transform;
+
+ void _direct_state_changed(Object *p_state);
protected:
void _notification(int p_what);
static void _bind_methods();
- void _direct_state_changed(Object *p_state);
-
public:
void set_physics_material_override(const Ref<PhysicsMaterial> &p_physics_material_override);
Ref<PhysicsMaterial> get_physics_material_override() const;
@@ -102,6 +105,8 @@ public:
virtual Vector3 get_linear_velocity() const override;
virtual Vector3 get_angular_velocity() const override;
+ virtual TypedArray<String> get_configuration_warnings() const override;
+
StaticBody3D();
private:
@@ -111,6 +116,9 @@ private:
void set_kinematic_motion_enabled(bool p_enabled);
bool is_kinematic_motion_enabled() const;
+
+ void set_sync_to_physics(bool p_enable);
+ bool is_sync_to_physics_enabled() const;
};
class RigidBody3D : public PhysicsBody3D {
@@ -251,7 +259,7 @@ public:
void apply_impulse(const Vector3 &p_impulse, const Vector3 &p_position = Vector3());
void apply_torque_impulse(const Vector3 &p_impulse);
- TypedArray<String> get_configuration_warnings() const override;
+ virtual TypedArray<String> get_configuration_warnings() const override;
RigidBody3D();
~RigidBody3D();