// Use this for initialization void Start() { view = gameObject.GetComponent <EvolutionSceneView>(); model = gameObject.GetComponent <EvolutionSceneModel>(); Deck deck = GlobalVariables.GetSelectedDeck(); PreviousIsEditable = deck.IsEditable; deck.IsEditable = false; List <Card> cardList = deck.cardList; if (cardList.Count == 0) { Card newCard = new Card(); cardList.Add(newCard); } model.init(deck); view.init(); editable = deck.IsEditable; if (editable) { errorMsg.text = ""; } else { portugueseText.interactable = false; englishText.interactable = false; } }
// Use this for initialization void Start () { view = gameObject.GetComponent<EvolutionSceneView>(); model = gameObject.GetComponent<EvolutionSceneModel>(); Deck deck = GlobalVariables.GetSelectedDeck(); PreviousIsEditable = deck.IsEditable; deck.IsEditable = false; List<Card> cardList = deck.cardList; if(cardList.Count == 0) { Card newCard = new Card(); cardList.Add(newCard); } model.init(deck); view.init(); editable = deck.IsEditable; if (editable) { errorMsg.text = ""; } else { portugueseText.interactable = false; englishText.interactable = false; } }
public void init() { GameObject deckCreator = GameObject.Find("Deck Creator"); model = deckCreator.GetComponent<EvolutionSceneModel>(); deckName.text = model.getDeckName(); sessionNumber.text = model.getSessionNumber(); updateCardContainer(); updatePorEnglText(); }
public void init() { GameObject deckCreator = GameObject.Find("Deck Creator"); model = deckCreator.GetComponent <EvolutionSceneModel>(); deckName.text = model.getDeckName(); sessionNumber.text = model.getSessionNumber(); updateCardContainer(); updatePorEnglText(); }