示例#1
0
        private static void LoadHorrents()
        {
            ShipTemplate template = TemplateDatabase.AddShip("HornetMk1");

            template.SetName(Resources.Fighter_HornetName);
            template.SetDescription(Resources.Fighter_HornetDescription);
            template.SetClass("Starfighter", "Interceptor");
            template.SetModel("WespeScoutYellow");
            template.SetRadarTrace("radar_fighter.png");
            template.SetHull(30);
            template.SetShields(20);
            template.SetSpeed(120, 30, 25);
            template.SetDefaultAI("fighter");
            // Arc, Dir, Range, CycleTime, Dmg
            template.SetupBeamWeapon(0, 30, 0, 700.0f, 4.0f, 2);

            template.SetFuelCapcity(400);

            template.SetReairCrew(1);

            template.AddRoom(3, 0, 1, 1, ShipSystemTypes.Maneuver);
            template.AddRoom(1, 0, 2, 1, ShipSystemTypes.Beams);
            template.AddRoom(0, 1, 1, 2, ShipSystemTypes.Shields(2));
            template.AddRoom(1, 1, 2, 2, ShipSystemTypes.Reactor);
            template.AddRoom(3, 1, 2, 1, ShipSystemTypes.FTL);
            template.AddRoom(3, 2, 2, 1, ShipSystemTypes.Jump);
            template.AddRoom(5, 1, 1, 2, ShipSystemTypes.Shields(1));
            template.AddRoom(1, 3, 2, 1, ShipSystemTypes.Missiles);
            template.AddRoom(3, 3, 1, 1, ShipSystemTypes.Sublight);

            template.AddDoor(2, 1, true);
            template.AddDoor(3, 1, true);
            template.AddDoor(1, 1, false);
            template.AddDoor(3, 1, false);
            template.AddDoor(3, 2, false);
            template.AddDoor(3, 3, true);
            template.AddDoor(2, 3, true);
            template.AddDoor(5, 1, false);
            template.AddDoor(5, 2, false);


            // mk2 upgrade
            ShipTemplate variation = TemplateDatabase.CloneShip(template, "HornetMk2");

            variation.SetName(Resources.Fighter_HornetMk2Name);
            variation.SetDescription(Resources.Fighter_HornetMk2Description);
            variation.SetModel("WespeScoutRed");
            variation.SetHull(35);
            variation.SetShields(22);
            variation.SetSpeed(125, 32, 25);
            variation.SetupBeamWeapon(0, 30, 0, 900.0f, 4.0f, 2.5f);


            // mk 3 player variant
            variation = TemplateDatabase.CloneShip(template, "HornetMk3P");
            variation.SetName(Resources.Fighter_HornetMk3Name);
            variation.SetDescription(Resources.Fighter_HornetMk3Description);

            variation.SetHull(70);
            variation.SetShields(60);
            variation.SetSpeed(125, 32, 25);
            variation.SetupBeamWeapon(0, 30, 0, 900.0f, 4.0f, 2.5f);
            variation.SetupBeamWeapon(1, 30, -5, 900.0f, 4.0f, 2.5f);
        }