//--------------------------------------------------- // AddAISystem //--------------------------------------------------- public void AddAISystem(Define.Battle.TEAM_TYPE type, BaseBattleAISystem aiSystem, string name) { _AISystemList.Add(type, aiSystem); _TeamNameList.Add(type, name); _observable.PushEvent("EVENT_SetTeamName", Common.CreateHashTable("teamType", type, "name", name)); }
//--------------------------------------------------- // CreateAISystem //--------------------------------------------------- void CreateAISystem() { for (int i = 0; i < _AISystemList.Count; i++) { Define.Battle.TEAM_TYPE teamType = (Define.Battle.TEAM_TYPE)i; BaseBattleAISystem system = Instantiate(_AISystemList[i]).GetComponent <BaseBattleAISystem>(); system.Initialize(teamType, this); _battleModel.AddAISystem(teamType, system, TeamNameList[i]); } }