After attaching it to unity UI button, the function cannot be found under click(). However, if i were to remove the ref, i can see it. How can i solve this?
public bool bool1 = false;
public bool bool2 = false;
public bool bool3 = false;
....
public bool bool100 = false;
public void ChangeBool(ref bool a)
{
a = true;
}
My goal is to create a single function for many buttons which will change each individual boolean each.
I understand that i can create 100 functions for 100 booleans but my worries is that the script will get very long.