using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

public class InstructionUIController : MonoBehaviour {

	#region variables
	private Image _image;

	[SerializeField]
	private Sprite[] _sprites;

	private int _index = 0;
	#endregion


	#region events
	void Awake () {

		_image = GetComponent <Image> ();

	}

	void OnDisable () {

		Next ();
		
	}
	#endregion


	#region methods
	void Next () {

		if (++_index < _sprites.Length) {
			_image.sprite = _sprites[_index];
		}

	}
	#endregion

}
