private void UpdateInput() { foreach (var slot in Slots) { if (Input.GetButtonDown(slot.InputName)) { if (slot.CanWarmSlot()) { if (_spellCaster.TryWarmSpell(slot.ScrollElement.SpellDescriptor)) { slot.WarmSlot(); } } } } foreach (var slot in Slots) { if (Input.GetButtonUp(slot.InputName)) { if (slot.CanFireSlot()) { if (_spellCaster.TryFireSpell(slot.ScrollElement.SpellDescriptor)) { slot.FireSlot(); } } } } }