Exemplo n.º 1
0
 public void Btn_Confirm()
 {
     if (BTP == null)
     {
         BTP = GetComponentInParent <BattleTeamPanel>();
     }
     BTP.ConfirmBattleTeam(TeamId);
 }
Exemplo n.º 2
0
 public void Btn_Edit()
 {
     //打开队伍编辑页面
     //SDGameManager.Instance.currentHeroTeamIndex = TeamId;
     if (BTP == null)
     {
         BTP = GetComponentInParent <BattleTeamPanel>();
     }
     BTP.openEditUnitTeamPanel(TeamId);
 }
Exemplo n.º 3
0
 public void initThisUnitTeam(GDEunitTeamData Team)
 {
     if (BTP == null)
     {
         BTP = GetComponentInParent <BattleTeamPanel>();
     }
     TeamEmpty.gameObject.SetActive(false);
     if (Team != null)
     {
         this.TeamId = Team.id;
         List <GDEHeroData> all = SDDataManager.Instance.getHerosFromTeam(TeamId);
         if (all.Count > 0)
         {
             //
             if (!string.IsNullOrEmpty(Team.goddess))
             {
                 GoddessInfo goddess = SDDataManager.Instance.getGoddessInfoById(Team.goddess);
                 TeamGoddess.GetComponentInChildren <Image>().sprite
                     = goddess.FaceIcon;
             }
             else
             {
             }
             //
             if (Team.teamName != "" && Team.teamName != null)
             {
                 TeamNameText.text = Team.teamName;
             }
             else
             {
                 TeamNameText.text = randomTeamNameBefore() + SDGameManager.T("小队") + Team.id;
             }
             //
             for (int i = 0; i < all.Count; i++)
             {
                 TeamHeroes[i] = all[i].hashCode;
             }
             //
             if (Team.badge > 0)
             {
             }
             else
             {
             }
         }
         else
         {
             ShowEmpty();
         }
     }
     else
     {
         ShowEmpty();
     }
 }