UnityNinja Community
Would you like to react to this message? Create an account in a few clicks or log in to continue.

UnityNinja CommunityLog in

UnityNinja - Video Game Development Community, including Resources, Forums, Marketplace & More.


descriptionDestroying individual particles with Raycast or Linerender in Unity3d EmptyDestroying individual particles with Raycast or Linerender in Unity3d

more_horiz
I am developing a Unity game in which a character will shoot individual objects and they are destroyed on the impact. For the objects, I used a particle system to generate them. This is a 3d game. The character shoots a beam at the objects created by the particle system. I want these objects to be destroyed/inactive when the beam touches them. The particle system has "collider" enabled.

I'm fairly new to unity so I haven't executed this before. How do I destroy the individual particles when the character shoots them. After some research, 1 solution that I found was to add a collider or mesh to the linerenderer that the character generates when shooting but this did not work out well. I didn't find this exact issue addressed on the Unity3d forum and my question regarding this remains unanswered.

Can anyone offer some insight in to this and hopefully point me in the right direction?

confused

descriptionDestroying individual particles with Raycast or Linerender in Unity3d EmptyRe: Destroying individual particles with Raycast or Linerender in Unity3d

more_horiz
Take a look here Wink



https://docs.unity3d.com/ScriptReference/MonoBehaviour.OnParticleCollision.html

https://unity3d.com/learn/tutorials/topics/scripting/particle-collisions
privacy_tip Permissions in this forum:
You cannot reply to topics in this forum
power_settings_newLogin to reply