Esempio n. 1
0
    void ClearCharDices()
    {
        Debug.Log("Clear CHAR Dices");

        while (charDices.Count > 0)
        {
            CharDiceUI charDice = charDices[0];
            charDices.Remove(charDice);
            Destroy(charDice.gameObject);
        }
    }
Esempio n. 2
0
    public void CreateCharactersDices()
    {
        Debug.Log("Create CHAR Dices");

        ClearCharDices();

        for (int i = 0; i < charactersManager.characters.Count; i++)
        {
            CharDiceUI charDice = Instantiate(charDicePrefab, transform).GetComponent <CharDiceUI>();
            charDice.character = charactersManager.characters[i];
            charDice.battleUI  = this;
            charDices.Add(charDice);
        }
    }