using System.Collections; using System.Collections.Generic; using UnityEngine; public class Chanks : MonoBehaviour { public Sprite[] imgs; public int Index = 0; void ChangeImgs() { if(imgs.Length > Index) { GetComponent().sprite = imgs[Index]; } } // Update is called once per frame void Update() { ChangeImgs(); } }