public void populateRecipe(ItemSpellScriptableObject spell){
resetCard();
button.SetActive(true);
title.SetActive(true);
background.GetComponent().color = new Color32(255,255,255,225);
dotgo.GetComponent().color = new Color32(255,255,255,225);
dialgo.GetComponent().color = new Color32(255,255,255,225);
phasesgo.GetComponent().color = new Color32(255,255,255,225);
flowerOfLifego.GetComponent().color = new Color32(255,255,255,225);
combo1.GetComponent().transform.localScale = GetRatio(spell.items[0]);
combo1.GetComponent().sprite = spell.items[0].icon;
combo1.GetComponent().color = new Color32(255,255,255,255);
combo2.GetComponent().transform.localScale = GetRatio(spell.items[1]);
combo2.GetComponent().sprite = spell.items[1].icon;
combo2.GetComponent().color = new Color32(255,255,255,255);
item.GetComponent().transform.localScale = GetRatio(spell.created);
item.GetComponent().sprite = spell.created.icon;
item.GetComponent().color = new Color32(255,255,255,255);
combo1.GetComponent().material = spell.items[0].material;
combo2.GetComponent().material = spell.items[1].material;
item.GetComponent().material = spell.created.material;
itemName.GetComponent().text = spell.created.title;
details.GetComponent().text = spell.created.details;
backgroundColor.GetComponent().color = new Color32(255,255,255,255);
backgroundColor.GetComponent().sprite = GetImage(spell.created.element.ToString(), "background");
type.GetComponent().color = new Color32(255,255,255,255);
type.GetComponent().sprite = GetImage(spell.created.element.ToString(), "element");
cardType = "potion";
open = false;
}
Leave a Reply