internal ResearchCompleteController(Player owner, ResearchTopic topic, GameController gameController, MainGame game) { this.game = game; this.gameController = gameController; this.Owner = owner; this.TopicProgress = this.game.States.ResearchAdvances.Of[owner].First(x => x.Topic == topic); this.priorities.AddRange(this.TopicProgress.Topic.Unlocks[this.TopicProgress.NextLevel]); }
internal ResearchTopicInfo(ResearchProgress tech, ResearchResult investmentResult, IEnumerable <DevelopmentTopic> developmentTopics) { this.topic = tech.Topic; this.textVars = new Var(DevelopmentTopic.LevelKey, tech.NextLevel).Get; this.Cost = tech.Topic.Cost.Evaluate(textVars); this.InvestedPoints = tech.InvestedPoints; this.Investment = investmentResult.InvestedPoints; this.Level = tech.Level; this.NextLevel = investmentResult.CompletedCount > 1 ? tech.Level + (int)investmentResult.CompletedCount : tech.NextLevel; this.Unlocks = tech.Topic.Unlocks[tech.NextLevel].Select(id => new DevelopmentTopicInfo(new DevelopmentProgress( developmentTopics.First(x => x.IdCode == id), tech.Owner) )).ToArray(); }
internal TechnologyGeneralInfo(ResearchTopic data) { this.imagePath = data.ImagePath; this.maxLevel = data.MaxLevel; this.languageCode = data.LanguageCode; }