Browse Source

Merge pull request #46795 from angad-k/use_collision_mask_in_vehicle_raycast

use collision mask in vehicle raycast
Rémi Verschelde 4 years ago
parent
commit
ee13944f9c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      scene/3d/vehicle_body_3d.cpp

+ 1 - 1
scene/3d/vehicle_body_3d.cpp

@@ -407,7 +407,7 @@ real_t VehicleBody3D::_ray_cast(int p_idx, PhysicsDirectBodyState3D *s) {
 
 
 	PhysicsDirectSpaceState3D *ss = s->get_space_state();
 	PhysicsDirectSpaceState3D *ss = s->get_space_state();
 
 
-	bool col = ss->intersect_ray(source, target, rr, exclude);
+	bool col = ss->intersect_ray(source, target, rr, exclude, get_collision_mask());
 
 
 	wheel.m_raycastInfo.m_groundObject = nullptr;
 	wheel.m_raycastInfo.m_groundObject = nullptr;