Hi,
Does anybody know hot to control all particles on a Particle System?
I have an particle that simulate a laser beam, when player pass trough it he loses some HP, but the point is, he is colliding with multiples particles at the same time and when he pass trough the laser beam he loses all his HP at the same time.
I’m using this script i’ve maded, and this script is atached to the Particle System:
public var player : GameObject;
function OnParticleCollision(hit : GameObject){
if(hit.tag=="Player"){
Debug.Log("Particle Colision!!!!!");
player.gameObject.FindWithTag("Player").GetComponent("LifeBar").hp = -1;
}
}
Does anybody have an idea how to control it?
Thanks for your reply!!!