Esempio n. 1
0
        public override void Run()
        {
            if (GameTask.Count <TechSelect>() > 1)
            {
                // Dialog already open
                EndTask();
                return;
            }

            if (!_human)
            {
                // This task is only for human players
                EndTask();
                return;
            }

            if (_player.Science == 0 && _player.Cities.Sum(x => x.Science) == 0)
            {
                // This task is only for human players
                EndTask();
                return;
            }

            if (!_player.AvailableResearch.Any())
            {
                // No more research Available
                //TODO: Implement future techs.
                EndTask();
                return;
            }

            ChooseTech chooseTech = new ChooseTech();

            chooseTech.Closed += ClosedChooseTech;
            Common.AddScreen(chooseTech);
        }