示例#1
0
        // -------------------------------------------------------------------------------
        // Initialize
        // -------------------------------------------------------------------------------
        public void Initialize(SelectionPanel panel, CharacterBase character)  
        {
            characterBase  = character;
            selectionPanel = panel;

            string name = "";

            name = characterBase.template.fullName + " [";

            if (characterBase.IsRearguard)
            {
                name += Finder.txt.formationNames.rear;
            }
            else
            {
                name += Finder.txt.formationNames.front;
            }

            name += "]";


            GetComponentInChildren <Text>().text = name;

            if (characterBase.template.icon != null)
            {
                icon.sprite = characterBase.template.icon;
                icon.gameObject.SetActive(true);
            }
            else
            {
                icon.gameObject.SetActive(false);
            }
        }
示例#2
0
 // -------------------------------------------------------------------------------
 //
 // -------------------------------------------------------------------------------
 private void Start()
 {
     selectionPanel = _selectionPanel.GetComponent <SelectionPanel>();
     StartCoroutine(OnApplicationStarted());
 }