using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
///
/// Class to handle learnable progress card display
///
public class LearnableProgressCard : MonoBehaviour
{
///
/// Reference to the progress so we can display a progress bar
///
public PersistentDataController.SavedLearnableProgress progress;
///
/// Reference to the list of minigameCards so we can query the correct course
///
public Learnable learnable;
///
/// UI reference to the thumbnail of the course
///
public Image thumbnail;
///
/// UI refeerence to the title of the course
///
public List stars;
///
/// Start is called before the first frame update
///
void Start()
{
thumbnail.sprite = learnable.image;
var starRewards = new float[] { 1.0f, 2.5f, 4.0f, };
for (int i = 0; i < 3; i++)
stars[i].color = starRewards[i] < progress.progress ? Color.white : Color.black;
}
}