Помогите с методом Start() в Unity2d
Помогите вызвать метод UnlockedLevel в Start()
public static int countUnlockedLevel = 1;
void Start () {
}
void UnlockedLevel() {
for (int i = 0; i < transform.childCount; i++)
{
if (i < countUnlockedLevel)
{
#region FirstStateBtn
transform.GetChild(i).GetComponent<Button>().interactable = true;
#endregion
}
else
{
#region SndStateBtn
transform.GetChild(i).GetComponent<Button>().interactable = false;
#endregion
}
}
}