/// <summary> /// Completes the initialization by updating the prequisites and checking trainability on trial account. /// </summary> internal void CompleteInitialization(IEnumerable <SerializableSkillPrerequisite> prereqs) { if (prereqs == null) { return; } // Create the prerequisites list Prerequisites.AddRange(prereqs.Select(x => new StaticSkillLevel(x.GetSkill(), x.Level))); }
public TechProject( fbGame game, int owner, Station station, int length, TechID tech ) : base(game, owner, station, Tech.Techs[tech].Cost, length) { this.tech = tech; Prerequisites.AddRange(Tech.Techs[tech].Prerequisites); }
public virtual void Initialize(Actor a, string d, List <Goal> p, List <Goal> o) { m_Actor = a; Description = d; Prerequisites.AddRange(p); Options.AddRange(o); foreach (var prereq in Prerequisites) { prereq.Initialize(a); } }
public BuildingProject( fbGame game, int owner, Station station, int length, UnitType unitType ) : base( game, owner, station, unitType.Cost, length ) { this.unitType = unitType; Prerequisites.AddRange(unitType.Prerequisites); }
/// <summary> /// Completes the initialization by updating the prequisites and checking trainability on trial account. /// </summary> internal void CompleteInitialization(IEnumerable <SerializableSkillPrerequisite> prereqs) { if (prereqs == null) { return; } // Create the prerequisites list Prerequisites.AddRange(prereqs.Select(x => new StaticSkillLevel(x.GetSkill(), x.Level))); if (!IsTrainableOnTrialAccount) { return; } // Check trainableOnTrialAccount on its childrens to be sure it's really trainable if (Prerequisites.All(prereq => prereq.Skill.IsTrainableOnTrialAccount)) { return; } IsTrainableOnTrialAccount = false; }
public DatabaseSpecification After(params Specification[] specifications) { return(new DatabaseSpecification(_databaseName, MigrationHistoryBuilder, Prerequisites.AddRange(specifications.SelectMany(x => x.Migrations)))); }
public TableSpecification After(params Specification[] specifications) { return(new TableSpecification(_migration, MigrationHistoryBuilder, Prerequisites.AddRange(specifications.SelectMany(x => x.Migrations)))); }