void Start() { for (int i = 0; i < skills.Length; i++) { skills[i].transform = transform; skills[i].Init(); GameEvents.On("Skill" + i.ToString(), skills[i].Cast); Button btn = SkillButton.GetButton(i); Image btnImage = btn.GetComponent <Image>(); btnImage.sprite = skills[i].image; btnImage.color = Color.white; } GameEvents.On("PlayerTick", CastSkillsInQueue); }