public void UpdateInfo() { ChallengeInformationText[] cits = FindObjectsOfType <ChallengeInformationText>(); ChallengeGenerator cg = FindObjectOfType <ChallengeGenerator>(); foreach (var cit in cits) { ChallengeInformation info = cg.GetChallengeInfo(cit.gameObject.name); if (info.Completed) { cit.tick.enabled = true; } } }
public void SetChallengeInfo(string name) { challengeInfo = challengeGenerator.GetChallengeInfo(name); }