Skip to content

Commit

Permalink
Make RID allocation thread-safe when using Jolt Physics
Browse files Browse the repository at this point in the history
(cherry picked from commit f6126ba)
  • Loading branch information
mihe authored and Spartan322 committed Dec 15, 2024
1 parent aa3ff42 commit da4621f
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions modules/jolt_physics/jolt_physics_server_3d.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ class JoltPhysicsServer3D final : public PhysicsServer3D {

inline static JoltPhysicsServer3D *singleton = nullptr;

mutable RID_PtrOwner<JoltSpace3D> space_owner;
mutable RID_PtrOwner<JoltArea3D> area_owner;
mutable RID_PtrOwner<JoltBody3D> body_owner;
mutable RID_PtrOwner<JoltSoftBody3D> soft_body_owner;
mutable RID_PtrOwner<JoltShape3D> shape_owner;
mutable RID_PtrOwner<JoltJoint3D> joint_owner;
mutable RID_PtrOwner<JoltSpace3D, true> space_owner;
mutable RID_PtrOwner<JoltArea3D, true> area_owner;
mutable RID_PtrOwner<JoltBody3D, true> body_owner;
mutable RID_PtrOwner<JoltSoftBody3D, true> soft_body_owner;
mutable RID_PtrOwner<JoltShape3D, true> shape_owner;
mutable RID_PtrOwner<JoltJoint3D, true> joint_owner;

HashSet<JoltSpace3D *> active_spaces;

Expand Down

0 comments on commit da4621f

Please sign in to comment.