public static Superpower FromName(string from)
        {
            Superpower result = SUPERPOWERS.FirstOrDefault(v => v.name == from);

            if (result == null)
            {
                Logging.Report("Unknown Superpower name " + from);
            }
            return(result);
        }
示例#2
0
        public static Superpower From(string from)
        {
            Superpower result = FromName(from);

            if (result == null)
            {
                result = FromEDName(from);
            }
            return(result);
        }
 public DockedEvent(DateTime timestamp, string system, string station, Superpower allegiance, string faction, State factionstate, Economy economy, Government government, SecurityLevel security) : base(timestamp, NAME)
 {
     this.system = system;
     this.station = station;
     this.allegiance = (allegiance == null ? Superpower.None.name : allegiance.name);
     this.faction = faction;
     this.factionstate = (factionstate == null ? State.None.name : factionstate.name);
     this.economy = (economy == null ? Economy.None.name : economy.name);
     this.government = (government == null ? Government.None.name : government.name);
     this.security = (security == null ? SecurityLevel.Low.name : security.name);
 }
示例#4
0
        public static Superpower FromName(string from)
        {
            if (from == null)
            {
                return(null);
            }

            Superpower result = SUPERPOWERS.FirstOrDefault(v => v.name == from);

            return(result);
        }
 public JumpedEvent(DateTime timestamp, string system, decimal x, decimal y, decimal z, decimal fuelused, decimal fuelremaining, Superpower allegiance, string faction, State factionstate, Economy economy, Government government, SecurityLevel security) : base(timestamp, NAME)
 {
     this.system = system;
     this.x = x;
     this.y = y;
     this.z = z;
     this.fuelused = fuelused;
     this.fuelremaining = fuelremaining;
     this.allegiance = (allegiance == null ? Superpower.None.name : allegiance.name) ;
     this.faction = faction;
     this.factionstate = (factionstate == null ? State.None.name : factionstate.name);
     this.economy = (economy == null ? Economy.None.name : economy.name);
     this.government = (government == null ? Government.None.name : government.name);
     this.security = (security == null ? SecurityLevel.None.name : security.name);
 }
示例#6
0
文件: Power.cs 项目: Deekfoz/EDDI
 private Power(string edname, Superpower allegiance, string headquarters) : base(edname, edname)
 {
     this.Allegiance   = allegiance;
     this.headquarters = headquarters;
 }