private bool loopBool = 3;
Script 1
public void ActivateScript1(){
int i = 0;
if(!loopBool*){*
Script2.ActivateScript2();
}
for (; i < max; i++)
{
loopBool = true;
}
}
Script 2
public void ActivateScript2(){
foreach (var item in collection)
{
Debug.Log(“A”);
}
}
ActivateScript1 is activated via a button. I want it so that if I press the button the debug message appears. Then I want that slot in the boolArray to turn true. And it should do this max 3 times since that is the size of the bool array.
Unfortunately as is now the first slot turn true and nothing happens after I press the button again. I know this might seem complicated ask for info if you are confused.