Describe the bug
I would like to use Raycast for deteching one thing however it collides with every collider in the scene.
To Reproduce
Steps to reproduce the behavior:
1.Clone https://github.com/Hsgngr/Pandemic_Simulation.git
Screenshots
The agent's ray perception sensor (blue one) hits another cubes sphere collider which I only want to use for triggering certain actions. I dont want to detect that. There is another collider which I would like to reach.

My agent has 2 colliders. SphereCollider is for triggering some actions and the other one is a cube collider which is attacthed to a child of this agent. This child object has ColliderCube tag and in my Detectable Tags: I am only giving wall and ColliderCube

Desired Behaviour

It hits directly to the box collider (I deactivate other sphere collider)
Environment (please complete the following information):
I solved the problem by using Layers. I added a new layer for the agent prefab and only added this to the parent object. I took the cube collider and put that as a child. Then I changed only parent's layer. I closed IgnoreRaycast from Project Settings/Physics (InfectionLayer is the agent layer)

I unchecked the Ray Layer Mask > InfectiousLayer in RayPerceptionSensor3D

and voila. Now it hit as it should.

Most helpful comment
I solved the problem by using Layers. I added a new layer for the agent prefab and only added this to the parent object. I took the cube collider and put that as a child. Then I changed only parent's layer. I closed IgnoreRaycast from Project Settings/Physics (InfectionLayer is the agent layer)
I unchecked the Ray Layer Mask > InfectiousLayer in RayPerceptionSensor3D
and voila. Now it hit as it should.