I started working on FPS Car Mechanic Game, but I don’t know how to solve, that I can mount parts to the car engine with mouse, when in right place we can mount part with left click and set child as empty gameobject (empty gameobject = part placeholder). On right click take out part from the engine and set as ItemSlot child. My problem is Raycast collide in Engine block part and not in the Piston. (if piston in the cylinder)
How could solve this problem ?
Yes, I have a code for mount item, but I found a solution.The raycast don’t collide with piston,because the engine block mesh collider is convex with rigidbody (cube,with no holes), but on the asset store I found THIS script and if the engine block have a normal mesh collider (with holes/cylinders), then the raycast will collide the piston collider.I hope it was understandable, because my english is not perfect.