| | |
| | | |
| | | public partial class TeamBase |
| | | { |
| | | public TeamHero[] teamHeros = new TeamHero[TeamConst.MaxTeamHeroCount]; |
| | | public TeamHero[] teamHeros = new TeamHero[TeamConst.MaxTeamSlotCount]; |
| | | |
| | | public int GetTeamHeroCount() |
| | | { |
| | |
| | | } |
| | | |
| | | return count; |
| | | } |
| | | } |
| | | |
| | | public bool SwapTeamHero(int index1, int index2) |
| | | { |
| | |
| | | { |
| | | |
| | | } |
| | | |
| | | #if UNITY_EDITOR |
| | | public void FillWithFakeData() |
| | | { |
| | | for (int i = 0; i < TeamConst.MaxTeamHeroCount; i++) |
| | | { |
| | | TeamHero hero = new TeamHero(); |
| | | hero.curHp = 100; |
| | | hero.attack = UnityEngine.Random.Range(300, 500); |
| | | hero.defense = UnityEngine.Random.Range(80, 100); |
| | | hero.heroInfo = new HeroInfo(); |
| | | hero.teamBase = this; |
| | | hero.heroIndex = i; |
| | | teamHeros[i] = hero; |
| | | } |
| | | } |
| | | #endif |
| | | } |