I opened up an old team project to and finish it, and i’m getting this warning. the coder wont be back from break for two weeks. So I’m trying to see if anyone know how to fix it.
error"
Assets/Standard Assets/ParticleSystems/Scripts/WaterHoseParticles.cs(41,48): error CS1061: Type UnityEngine.ParticleCollisionEvent' does not contain a definition for
componentCollider’ and no extension method componentCollider' of type
UnityEngine.ParticleCollisionEvent’ could be found. Are you missing an assembly reference?"
here is the script
using System;
using UnityEngine;
namespace UnityStandardAssets.Effects
{
public class WaterHoseParticles : MonoBehaviour
{
public static float lastSoundTime;
public float force = 1;
private ParticleCollisionEvent[ ] m_CollisionEvents = new ParticleCollisionEvent[16];
private ParticleSystem m_ParticleSystem;
private void Start()
{
m_ParticleSystem = GetComponent();
}
private void OnParticleCollision(GameObject other)
{
int safeLength = m_ParticleSystem.GetSafeCollisionEventSize();
if (m_CollisionEvents.Length < safeLength)
{
m_CollisionEvents = new ParticleCollisionEvent[safeLength];
}
int numCollisionEvents = m_ParticleSystem.GetCollisionEvents(other, m_CollisionEvents);
int i = 0;
while (i < numCollisionEvents)
{
if (Time.time > lastSoundTime + 0.2f)
{
lastSoundTime = Time.time;
}
var col = m_CollisionEvents*.Collider;*
if (col.attachedRigidbody != null)
{
Vector3 vel = m_CollisionEvents*.velocity;
_col.attachedRigidbody.AddForce(velforce, ForceMode.Impulse);_
}
other.BroadcastMessage(“Extinguish”, SendMessageOptions.DontRequireReceiver);
i++;
}
}
}
}