#How to set a boolean arrays elements to equal a bool in a GameObjects array
1 messages · Page 1 of 1 (latest)
i think you're not calling the function Players()
I just realized that but it doesn't fix the problem no,
also tried this
public void Players()
{
bool state;
for(int i = 0; i < playerCount; i++)
{
state = players[i].GetComponent<PlayerController>().isDead;
playerStates.Append(state);
}
}
but it did not work either
does the object player have the tag Player?