From a0247ab6e41a1799ad8e1c73b06574da0ed29e4f Mon Sep 17 00:00:00 2001 From: RafaelDominiquini <61922887+RafaelDominiquini@users.noreply.github.com> Date: Wed, 16 Jun 2021 02:14:13 -0300 Subject: [PATCH 1/2] Refactor --- .../Snacks/LifeSupportResources/Air.txt | 105 ++---------------- 1 file changed, 12 insertions(+), 93 deletions(-) diff --git a/GameData/WildBlueIndustries/Snacks/LifeSupportResources/Air.txt b/GameData/WildBlueIndustries/Snacks/LifeSupportResources/Air.txt index 6bfec6f..b1e7181 100644 --- a/GameData/WildBlueIndustries/Snacks/LifeSupportResources/Air.txt +++ b/GameData/WildBlueIndustries/Snacks/LifeSupportResources/Air.txt @@ -90,7 +90,7 @@ STORAGE_TEMPLATE //When a part with crew capacity is loaded in the editor and it lacks this resource, //or when a vessel is loaded into the scene and its parts with crew capacity lack this resource, -//add it to the part. Doesn’t apply to kerbals going on EVA. Use SNACKS_EVA_RESOURCE for that. +//add it to the part. Doesn’t apply to kerbals going on EVA. Use SNACKS_EVA_RESOURCE for that. SNACKS_PART_RESOURCE { name = FreshAir @@ -284,14 +284,14 @@ SNACKS_RESOURCE_PROCESSOR } } -@PART[crewCabin,mk2CrewCabin] +@PART[crewCabin,MK1CrewCabin,mk2CrewCabin,mk3CrewCabin,mk3Cockpit_Shuttle,Large_Crewed_Lab] { MODULE { name = SnacksConverter ConverterName = Air Scrubber StartActionName = Start Air Scrubber - StopActionName = Stop Air Scribber + StopActionName = Stop Air Scrubber AutoShutdown = false GeneratesHeat = false UseSpecialistBonus = false @@ -299,115 +299,34 @@ SNACKS_RESOURCE_PROCESSOR INPUT_RESOURCE { ResourceName = StaleAir - Ratio = 0.00074 + Ratio = 0.000185 + @Ratio *= #$../../CrewCapacity$ FlowMode = ALL_VESSEL } INPUT_RESOURCE { ResourceName = ElectricCharge - Ratio = 0.4 - FlowMode = STAGE_PRIORITY_FLOW - } - - OUTPUT_RESOURCE - { - ResourceName = FreshAir - Ratio = 0.000296 - FlowMode = ALL_VESSEL - } - } - - RESOURCE - { - name = StaleAir - amount = 0 - maxAmount = 64 - } -} - -//These parts help clear the air -@PART[MK1CrewCabin] -{ - MODULE - { - name = SnacksConverter - ConverterName = Air Scrubber - StartActionName = Start Air Scrubber - StopActionName = Stop Air Scribber - AutoShutdown = false - GeneratesHeat = false - UseSpecialistBonus = false - - INPUT_RESOURCE - { - ResourceName = StaleAir - Ratio = 0.00037 - FlowMode = ALL_VESSEL - } - - INPUT_RESOURCE - { - ResourceName = ElectricCharge - Ratio = 0.2 + Ratio = 0.1 + @Ratio *= #$../../CrewCapacity$ FlowMode = STAGE_PRIORITY_FLOW } OUTPUT_RESOURCE { ResourceName = FreshAir - Ratio = 0.000148 + Ratio = 0.000074 + @Ratio *= #$../../CrewCapacity$ FlowMode = ALL_VESSEL } -} - - RESOURCE - { - name = StaleAir - amount = 0 - maxAmount = 32 - } -} - -@PART[mk3CrewCabin] -{ - MODULE - { - name = SnacksConverter - ConverterName = Air Scrubber - StartActionName = Start Air Scrubber - StopActionName = Stop Air Scribber - AutoShutdown = false - GeneratesHeat = false - UseSpecialistBonus = false - - INPUT_RESOURCE - { - ResourceName = StaleAir - Ratio = 0.00296 - FlowMode = ALL_VESSEL - } - - INPUT_RESOURCE - { - ResourceName = ElectricCharge - Ratio = 1.6 - FlowMode = STAGE_PRIORITY_FLOW - } - - OUTPUT_RESOURCE - { - ResourceName = FreshAir - Ratio = 0.001184 - FlowMode = ALL_VESSEL - } } RESOURCE { name = StaleAir amount = 0 - maxAmount = 256 + maxAmount = #$../CrewCapacity$ + @maxAmount *= 16 } } @@ -602,4 +521,4 @@ SNACKS_RESOURCE_PROCESSOR } } } -} \ No newline at end of file +} From 71a1be66be8e5f9b7167dcba3372770cdcfd912f Mon Sep 17 00:00:00 2001 From: RafaelDominiquini <61922887+RafaelDominiquini@users.noreply.github.com> Date: Wed, 16 Jun 2021 02:14:48 -0300 Subject: [PATCH 2/2] Refactor --- .../Snacks/ModuleManagerPatches/MM_Stock.cfg | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/GameData/WildBlueIndustries/Snacks/ModuleManagerPatches/MM_Stock.cfg b/GameData/WildBlueIndustries/Snacks/ModuleManagerPatches/MM_Stock.cfg index 8ce34bf..e527091 100644 --- a/GameData/WildBlueIndustries/Snacks/ModuleManagerPatches/MM_Stock.cfg +++ b/GameData/WildBlueIndustries/Snacks/ModuleManagerPatches/MM_Stock.cfg @@ -84,13 +84,13 @@ MODULE:NEEDS[BARIS] { name = ModuleQualityControl - quality = 65 + quality = 75 mtbf = 100 monitorConverters = true //WARNING: this is a performance hit. } } -@PART[crewCabin,mk3Cockpit_Shuttle,mk2CrewCabin] +@PART[crewCabin,MK1CrewCabin,mk2CrewCabin,mk3CrewCabin,mk3Cockpit_Shuttle,Large_Crewed_Lab]:FOR[Snacks] { // Adds suffix @tags ^= :$: cck-lifesupport: @@ -143,7 +143,7 @@ MODULE:NEEDS[BARIS] { name = ModuleQualityControl - quality = 65 + quality = 75 mtbf = 100 monitorConverters = true //WARNING: this is a performance hit. } @@ -152,6 +152,7 @@ { name = Soil amount = 0 - maxAmount = 200 + maxAmount = #$../CrewCapacity$ + @maxAmount *= 200 } -} \ No newline at end of file +}