Ejemplo n.º 1
0
 public void Clean()
 {// clean the scene after endgame
     foreach (Team t in m_teams)
     {
         m_factory.DestroyTeam(t);
     }
     m_teams         = null;
     m_configuration = null;
     m_currentMap.CleanGraphics();
     Material.Destroy(m_currentMap.Material);
     m_currentMap = null;
     m_points.Clear();
 }
Ejemplo n.º 2
0
 //to destroy a Team, we have to clean the entire game
 public void DestroyTeam(Team t)
 {
     t.SpawnPoint.CleanGraphical();
     t.Flag.CleanGraphical();
     foreach (Character c in t.Characters)
     {
         DestroyCharacter(c);
     }
     t.Target     = null;
     t.Flag       = null;
     t.SpawnPoint = null;
     t.CleanGraphical();
     Material.Destroy(t.Material);
 }