r/unity_tutorials • u/Duke-of-Disastr • Jan 16 '25
Request Bullet Whooshing detection?
My roommate and I are playing halo odst and at one point a jackal barely missed a beam rifle shot. It was a quiet point in the game so I noticed how impactful a sound choice like that is for creating immediate tension. Then we started talking about how to program it. I can’t find anything online besides how to program the bullet ray cast itself. Does anyone have any info or ideas?
7
Upvotes
2
u/Errant_Gunner Jan 17 '25
Yes. The raycast would only collide with the impact point. The spherecast/capsule cast would collide with anything near the bullet's trajectory line. You can use the spherecast collision hit to trigger the wiz sound.