public void AddChild(CombatAIController child) { if (!(child is SwarmerAttackerControl)) { return; } foreach (Ship loadingSwarmer in this.m_LoadingSwarmers) { if (loadingSwarmer == child.GetShip()) { this.m_LoadingSwarmers.Remove(loadingSwarmer); this.m_LaunchingShips.Add(loadingSwarmer); this.m_SpawnedSwarmers.Add(child as SwarmerAttackerControl); break; } } foreach (Ship loadingGuardian in this.m_LoadingGuardians) { if (loadingGuardian == child.GetShip()) { this.m_LoadingGuardians.Remove(loadingGuardian); this.m_LaunchingShips.Add(loadingGuardian); this.m_SpawnedGuardians.Add(child as SwarmerAttackerControl); break; } } }
public void AddChild(CombatAIController child) { if (child is VonNeumannChildControl) { foreach (Ship loadingChild in this.m_LoadingChilds) { if (loadingChild == child.GetShip()) { this.m_LoadingChilds.Remove(loadingChild); break; } } this.m_SpawnedChilds.Add(child as VonNeumannChildControl); } else if (child is VonNeumannMomControl) { if (child.GetShip() == this.m_LoadingMom) { this.m_LoadingMom = (Ship)null; } this.m_SpawnedMoms.Add(child as VonNeumannMomControl); } switch (this.m_State) { case VonNeumannMomStates.INITFLEE: case VonNeumannMomStates.FLEE: case VonNeumannMomStates.VANISH: child.ForceFlee(); break; } }
public void AddCrow(CombatAIController crow) { if (!(crow is MorrigiCrowControl)) { return; } foreach (Ship loadingCrow in this.m_LoadingCrows) { if (loadingCrow == crow.GetShip()) { this.m_LoadingCrows.Remove(loadingCrow); this.m_LaunchingCrows.Add(loadingCrow); break; } } this.m_SpawnedCrows.Add(crow as MorrigiCrowControl); }
public override void AddChild(CombatAIController child) { base.AddChild(child); if (!(child is VonNeumannPyramidControl)) { return; } foreach (Ship loadingPyramid in this.m_LoadingPyramids) { if (loadingPyramid == child.GetShip()) { this.m_LoadingPyramids.Remove(loadingPyramid); break; } } this.m_Pyramids.Add(child as VonNeumannPyramidControl); }
public virtual void AddChild(CombatAIController child) { if (!(child is VonNeumannDiscControl)) { return; } foreach (Ship loadingDisc in this.m_LoadingDiscs) { if (loadingDisc == child.GetShip()) { loadingDisc.Active = this.m_DiscsActivated; this.m_LoadingDiscs.Remove(loadingDisc); break; } } this.m_Discs.Add(child as VonNeumannDiscControl); }
public void AddFighter(CombatAIController fighter) { if (fighter is LocustFighterControl) { foreach (Ship loadingFighter in this.m_LoadingFighters) { if (loadingFighter == fighter.GetShip()) { this.m_LoadingFighters.Remove(loadingFighter); this.m_LaunchingFighters.Add(loadingFighter); break; } } this.m_SpawnedFighters.Add(fighter as LocustFighterControl); } if (this.m_LoadingFighters.Count != 0) { return; } this.m_State = LocustNestStates.WAITFORDOCKED; }