async Task ExecuteRunHeuristic() { try { List <Problem> problems = null; IHeuristicConfigurationSetting settings = null; if (Context.Instance.Settings.GeneralSettings.MultiplesExecutions) { problems = Context.Instance.Problems; } else { problems = new List <Problem> { Context.Instance.Problems.Where(t => t.ID_Problem.Equals(DARPSelected)).ToList().First() } }; switch (Context.Instance.Settings.GeneralSettings.DefaultHeuristic) { case "ILS": settings = Context.Instance.Settings.ILSConfigurationSettings; break; default: settings = Context.Instance.Settings.ILSConfigurationSettings; break; } //Mostrar Splash splashController.ShowSplash(new SplashInfo()); RunMetaheuristicInput input = new RunMetaheuristicInput { Problems = problems, HeuristicSettings = settings, Random = new Random(1) }; RunMetaheuristicOutput output = await processController.Specific.RunMetaheuristic.ExecuteProcess(input); if (output != null) { Context.Instance.Solutions = output.Solutions; DARPResults = new ResultsViewModel(output.Solutions.First()); ILSEvolution = new ILSEvolutionViewModel(output.Solutions.First()); VNSOperators = new VNSOperatorsViewModel(output.Solutions.First()); AlgorithmSummary = new SummaryResultsViewModel(output.Solutions.First()); ChartsViewModel = new ChartsViewModel(output.Solutions.First()); HeuristicExecuted = true; TabSelected = 1; SetStatus(Constants.StatusType.Ok, String.Format(Properties.Resources.HEURISTIC_EXECUTED_SUCCESFULLY)); } else { SetStatus(Constants.StatusType.Ok, String.Format(Properties.Resources.HEURISTIC_EXECUTED_FAIL)); } } finally { splashController.HideSplash(); } }
protected override void Start() { base.Start(); SplashController.HideSplash(); dailyBtn.transform.DOScale(1.05f, 0.8f).SetLoops(-1, LoopType.Yoyo); playBtn.transform.DOScale(1.05f, 0.8f).SetLoops(-1, LoopType.Yoyo); if (!FB.IsLoggedIn) { if (Prefs.FirstLoginFacebook == 1) { facebookReward.transform.GetChild(0).gameObject.SetActive(false); } facebookReward.transform.DOScale(1.05f, 0.8f).SetLoops(-1, LoopType.Yoyo); facebookReward.SetActive(true); } else { facebookReward.transform.DOKill(); facebookReward.SetActive(false); } }