// Remember to clean after ourself... public void OnRestart() { switch (GameConstants.ParticipantRace) { case NydusNetwork.API.Protocol.Race.NoRace: break; case NydusNetwork.API.Protocol.Race.Terran: _abathur.RemoveFromGameloop(_terranModule); _added = true; break; case NydusNetwork.API.Protocol.Race.Zerg: _abathur.RemoveFromGameloop(_zergModule); _added = true; break; case NydusNetwork.API.Protocol.Race.Protoss: _abathur.RemoveFromGameloop(_protossModule); _added = true; break; case NydusNetwork.API.Protocol.Race.Random: break; } }
/// <summary> /// Abathur will not automaticly remove modules added at run-time. /// We need to manually remove the modules we added. /// </summary> public void OnRestart() { _abathur.RemoveFromGameloop(_terranModule); _abathur.RemoveFromGameloop(_zergModule); _abathur.RemoveFromGameloop(_protossModule); }
private void RemoveTactic(IReplaceableModule tactic) { activeTactics.Remove(tactic); abathur.RemoveFromGameloop(tactic); }