/// <summary> /// Loads the graphics in. /// </summary> public void LoadGraphics() { EmptySpace = new SpaceTile() { color = Spritemanager.Colors["GREY"], sprite = Spritemanager.GetSprite("space") }; Star = new List <SpaceTile>(); Star.Add(new SpaceTile() { color = Spritemanager.Colors["YELLOW"], sprite = Spritemanager.GetSprite("star1"), MovementCost = 3 }); Star.Add(new SpaceTile() { color = Spritemanager.Colors["RED"], sprite = Spritemanager.GetSprite("star1"), MovementCost = 3 }); //Star.Add(new SpaceTile() //{ // color = Spritemanager.Colors["BROWN"], // sprite = Spritemanager.GetSprite("star1"), // MovementCost = 3 //}); Planet = new SpaceTile() { color = Spritemanager.Colors["BROWN"], sprite = Spritemanager.GetSprite("planet1"), MovementCost = 2 }; }
public void LoadBasicDesigns() { BasicDesigns = new Dictionary <string, ShipDesign>(); var corvette = new ShipDesign() { Name = "Corvette", Type = "Corvette", Sprite = Spritemanager.GetSprite("corvette"), MaxHp = 10, BaseComponents = new List <BaseComponent>() { GetComponentType("engine"), GetComponentType("weapon") } }; corvette.Cost = corvette.BaseComponents.Sum(x => x.Cost); BasicDesigns.Add(corvette.Name, corvette); var colony = new ShipDesign() { Name = "Colony", Type = "ColonyShip", Sprite = Spritemanager.GetSprite("colonyship"), MaxHp = 10, BaseComponents = new List <BaseComponent>() { GetComponentType("engine"), GetComponentType("engine"), GetComponentType("engine"), GetComponentType("colony") } }; colony.Cost = colony.BaseComponents.Sum(x => x.Cost); BasicDesigns.Add(colony.Name, colony); var frigate = new ShipDesign() { Name = "Frigate", Type = "Frigate", Sprite = Spritemanager.GetSprite("frigate"), MaxHp = 10, BaseComponents = new List <BaseComponent>() { GetComponentType("engine"), GetComponentType("engine"), GetComponentType("engine"), GetComponentType("mass"), GetComponentType("armor"), GetComponentType("armor"), GetComponentType("mass"), } }; frigate.Cost = frigate.BaseComponents.Sum(x => x.Cost); BasicDesigns.Add(frigate.Name, frigate); var destroyer = new ShipDesign() { Name = "Destroyer", Type = "Destroyer", Sprite = Spritemanager.GetSprite("destroyer"), MaxHp = 10, BaseComponents = new List <BaseComponent>() { GetComponentType("engine"), GetComponentType("engine"), GetComponentType("engine"), GetComponentType("mass"), GetComponentType("armor"), GetComponentType("armor"), GetComponentType("mass"), GetComponentType("shield"), GetComponentType("energy") } }; destroyer.Cost = destroyer.BaseComponents.Sum(x => x.Cost); BasicDesigns.Add(destroyer.Name, destroyer); var battleship = new ShipDesign() { Name = "Battleship", Type = "Battleship", Sprite = Spritemanager.GetSprite("battleship"), MaxHp = 10, BaseComponents = new List <BaseComponent>() { GetComponentType("engine"), GetComponentType("engine"), GetComponentType("engine"), GetComponentType("mass"), GetComponentType("armor"), GetComponentType("armor"), GetComponentType("mass"), GetComponentType("shield"), GetComponentType("energy"), GetComponentType("engine"), GetComponentType("missile"), GetComponentType("armor"), GetComponentType("armor"), } }; battleship.Cost = battleship.BaseComponents.Sum(x => x.Cost); BasicDesigns.Add(battleship.Name, battleship); }