|
I'm running this code:
This is on a particle system (bullets) that hits a rigidbody, and I want it to spawn another particle system at the same place (poofs). I've also tried OnCollisionEnter and OnParticleCollision, but I think the Trigger would be best, perhaps. I was under the impression that OnParticleCollision, that works best on rigidbodies trying to detect whether they're being hit by a particle, i.e. so that it knows to be damaged. So far, the Debug text doesn't even appear in the Console log, so I'm pretty much at wit's end on this issue. TIA!
(comments are locked)
|
|
A particle system can't be a trigger; it will only generate OnParticleCollision events. OnParticleCollision doesn't have collision location information anyway...you'd be better off raycasting and using particles as visual elements only. Thanks for the suggestion, that sounds about right. Do you know of any good resources on raycasting other than what's in the scripting API? I'd like to know more about how that works exactly.
Feb 09 '10 at 02:29 PM
CryptoQuick
If you mean raycasting in general, I'd suggest googling it, since it's nothing unique to Unity. If you mean the Unity-specific implementation, various tutorials have raycasting in them, like the first-person shooter tutorial.
Feb 09 '10 at 08:12 PM
Eric5h5
Thanks, man. You get the answer. :)
Feb 11 '10 at 04:17 PM
CryptoQuick
(comments are locked)
|
