Exemplo n.º 1
0
        public static void Patch()
        {
            try
            {
                Console.WriteLine($"[UpgradedVehicles] Start patching");

                var speedModule = new SpeedBooster();
                speedModule.Patch();

                var powerCore = new VehiclePowerCore(speedModule);
                powerCore.Patch();

                var mothMk2 = new SeaMothMk2(powerCore);
                mothMk2.Patch();

                var suitMk2 = new ExosuitMk2(powerCore);
                suitMk2.Patch();

                var mothMk3 = new SeaMothMk3(powerCore);
                mothMk3.Patch();

                HarmonyInstance harmony = HarmonyInstance.Create("com.upgradedvehicles.psmod");
                harmony.PatchAll(Assembly.GetExecutingAssembly());

                Console.WriteLine($"[UpgradedVehicles] Finish patching");
            }
            catch (Exception ex)
            {
                Console.WriteLine("[UpgradedVehicles] EXCEPTION on Patch: " + ex.ToString());
            }
        }
 internal ExosuitMk2(VehiclePowerCore vehiclePowerCore)
     : base("ExosuitMk2",
            "Prawn Suit MK2",
            "An upgraded Prawn Suit now even tougher to take on anything.",
            TechType.Exosuit,
            1.5f,
            TechType.ExoHullModule2)
 {
     PowerCoreID = vehiclePowerCore.TechType;
 }
 internal SeaMothMk3(VehiclePowerCore vehiclePowerCore)
     : base(nameID: "SeaMothMk3",
            friendlyName: "Seamoth MK3",
            description: "The highest end SeaMoth. Ready for adventures in the most hostile of environments.",
            template: TechType.Seamoth,
            healthModifier: 2.15f,    // 2.15x Max HP. 115% more.
            requiredAnalysis: TechType.VehicleHullModule3)
 {
     PowerCoreID = vehiclePowerCore.TechType;
 }
Exemplo n.º 4
0
 internal SeaMothMk2(VehiclePowerCore vehiclePowerCore)
     : base(nameID: "SeaMothMk2",
            friendlyName: "Seamoth MK2",
            description: "An upgraded SeaMoth, built harder and faster to take you anywhere.",
            template: TechType.Seamoth,
            healthModifier: 2f,    // 2x the Max HP. 100% more.
            requiredAnalysis: TechType.VehicleHullModule3)
 {
     PowerCoreID = vehiclePowerCore.TechType;
 }
Exemplo n.º 5
0
 internal ExosuitMk2(VehiclePowerCore vehiclePowerCore)
     : base(
         nameID: "ExosuitMk2",
         friendlyName: "Prawn Suit MK2",
         description: "An upgraded Prawn Suit now even tougher to take on anything.",
         template: TechType.Exosuit,
         healthModifier: 1.5f,
         requiredAnalysis: TechType.ExoHullModule2,
         powerCore: vehiclePowerCore)
 {
 }
Exemplo n.º 6
0
 protected UpgradedVehicle(
     string nameID,
     string friendlyName,
     string description,
     TechType template,
     float healthModifier,
     TechType requiredAnalysis,
     VehiclePowerCore powerCore)
     : base(
         nameID: nameID,
         friendlyName: friendlyName,
         description: description,
         template: template,
         fabricatorType: CraftTree.Type.Constructor,
         fabricatorTab: "Vehicles",
         requiredAnalysis: requiredAnalysis,
         groupForPDA: TechGroup.Constructor,
         categoryForPDA: TechCategory.Constructor,
         prerequisite: powerCore)
 {
     HealthModifier = healthModifier;
     PowerCore      = powerCore;
 }