Fix moving platforms with ray shapes
In the case of ray shapes, the body RID used to apply platform velocity wasn't properly set.
This commit is contained in:
parent
ed3742c4a7
commit
ad5e70cde4
2 changed files with 2 additions and 0 deletions
|
@ -1015,6 +1015,7 @@ bool KinematicBody2D::separate_raycast_shapes(bool p_infinite_inertia, Collision
|
|||
|
||||
if (deepest != -1) {
|
||||
r_collision.collider = sep_res[deepest].collider_id;
|
||||
r_collision.collider_rid = sep_res[deepest].collider;
|
||||
r_collision.collider_metadata = sep_res[deepest].collider_metadata;
|
||||
r_collision.collider_shape = sep_res[deepest].collider_shape;
|
||||
r_collision.collider_vel = sep_res[deepest].collider_velocity;
|
||||
|
|
|
@ -1278,6 +1278,7 @@ bool KinematicBody::separate_raycast_shapes(bool p_infinite_inertia, Collision &
|
|||
|
||||
if (deepest != -1) {
|
||||
r_collision.collider = sep_res[deepest].collider_id;
|
||||
r_collision.collider_rid = sep_res[deepest].collider;
|
||||
r_collision.collider_metadata = sep_res[deepest].collider_metadata;
|
||||
r_collision.collider_shape = sep_res[deepest].collider_shape;
|
||||
r_collision.collider_vel = sep_res[deepest].collider_velocity;
|
||||
|
|
Loading…
Reference in a new issue