public static List <string> FormatCrewStats(CrewData crew, bool useSpace, int raritySearch = 0, bool forGauntlet = false) { var data = crew.skill_data.FirstOrDefault(sd => sd.rarity == raritySearch); if (data != null) { return(FormatCrewStatsInternal(data.base_skills, useSpace, forGauntlet)); } return(FormatCrewStatsInternal(crew.base_skills, useSpace, forGauntlet)); }
private static Skill GetCrewSkill(CrewData crew, string skill) { Skill result = null; if (skill == "sci") { result = crew.base_skills.science_skill; } else if (skill == "sec") { result = crew.base_skills.security_skill; } else if (skill == "eng") { result = crew.base_skills.engineering_skill; } else if (skill == "dip") { result = crew.base_skills.diplomacy_skill; } else if (skill == "cmd") { result = crew.base_skills.command_skill; } else if (skill == "med") { result = crew.base_skills.medicine_skill; } if (result == null) { result = new Skill(); result.core = 0; result.range_max = 0; result.range_min = 0; } return(result); }
public CrewSearchFuzzyHelper(CrewData crew, int distance) { Crew = crew; Distance = distance; }
private static double GetAvgSkill(CrewData crew, string skill) { var skillData = GetCrewSkill(crew, skill); return(skillData.core * STARBASE_BONUS_CORE + GetRangeAvgSkill(crew, skill)); }
private static double GetRangeAvgSkill(CrewData crew, string skill) { var skillData = GetCrewSkill(crew, skill); return(((skillData.range_max + skillData.range_min) * STARBASE_BONUS_RANGE) / 2); }