Hello, I have two classes. The first have a trigger and the second have a parameter. Please, I need to conect the two classes to when I enter on the trigger, I can change the parameter.
void OnTriggerEnter(Collider other)
{
if (other.transform.tag == "mytag")
{
myboolean = true;
if(myboolean == true)
{
}
}
}
My other class:
transform.Translate(Vector3.forward * Time.deltaTime * speed);
I need to change the translate direccion on trigger enter.
Thank You!!