Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // USI Life Support habitat functions
- // Authored by KSP forum user Pulsar
- // Special thanks to KSP forum user Domfluff for advices!
- // Experimental edit by Boamere for use with the new USI modules (1.5.1)
- // Edited PXL-10 PPD-8 and PTD-8R to have 0.125EC/Crew Capacity recyclers (Boamere 11/03/2019)
- //RIGID HABITATS
- //PTD-5 'Sunrise' Habitation Module
- @PART[sspx-habitation-125-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 5
- CrewCapacity = 2
- BaseHabMultiplier = 0
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.125
- }
- }
- }
- //PPD-20 'Shanty' Habitation Module
- @PART[sspx-habitation-25-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 28
- CrewCapacity = 6
- BaseHabMultiplier = 1
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 1.2
- }
- }
- }
- //PXL-1 'Hostel' Deep-Space Habitation Module
- @PART[sspx-habitation-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 95
- CrewCapacity = 12
- BaseHabMultiplier = 1.9
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 3.325
- }
- }
- }
- //PXL-2 'Shelter' Deep-Space Habitation Module
- @PART[sspx-habitation-375-2]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 47
- CrewCapacity = 6
- BaseHabMultiplier = 0
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 1.175
- }
- }
- }
- //PXL-3 'Asylum' Storm Cellar Module
- @PART[sspx-habitation-375-3]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 11
- CrewCapacity = 6
- BaseHabMultiplier = 2.6
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 1.575
- }
- }
- }
- //PPD-24 'Panorama' Observation Module
- //PXL-9 Astrogation Module
- @PART[sspx-observation-25-1|sspx-cupola-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- BaseKerbalMonths = 0
- %CrewCapacity = #$/CrewCapacity$
- @CrewCapacity *= 2
- %BaseHabMultiplier = #$/mass$
- @BaseHabMultiplier *= .9
- %ConverterName = Habitat
- %StartActionName = Start Habitat
- %StopActionName = Stop Habitat
- %INPUT_RESOURCE[ElectricCharge]
- {
- %Ratio = #$../BaseHabMultiplier$
- @Ratio *= .5
- }
- }
- }
- //PTD-C Observation Window
- @PART[sspx-cupola-125-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 0
- CrewCapacity = 1
- BaseHabMultiplier = 0.7
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.1
- }
- }
- }
- //STATION CORES
- //PTD-8R 'Pier' Station Core
- @PART[sspx-core-125-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 2
- RecyclePercent = 0.25
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.25
- }
- }
- }
- //PPD-8 'Wharf' Station Core
- @PART[sspx-core-25-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 4
- RecyclePercent = 0.25
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.5
- }
- }
- }
- //PXL-10 'Harbour' Station Control Centre
- @PART[sspx-core-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 5
- RecyclePercent = 0.25
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.625
- }
- }
- }
- //RECYCLERS
- //PTD-6 'Star' Utility Module
- @PART[sspx-utility-125-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 2
- RecyclePercent = 0.5
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.5
- }
- }
- }
- //PXL-2 'Fate' Deep-Space Laboratory Module
- @PART[sspx-lab-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 6
- RecyclePercent = 0.5
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 1.5
- }
- }
- }
- //PXL-F15H Aquaculture Module
- @PART[sspx-aquaculture-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 4
- RecyclePercent = 0.81
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 36.25
- }
- }
- }
- //INFLATABLES
- //PTD-E-2 'Eclair' Inflatable Habitation Module
- @PART[sspx-inflatable-hab-125-1]:NEEDS[USILifeSupport]
- { MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 19
- CrewCapacity = #$../MODULE[ModuleDeployableHabitat]/DeployedCrewCapacity$
- BaseHabMultiplier = 0.6
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 1.55
- }
- }
- }
- //PTD-E-1A 'Winston' Inflatable Habitation Module
- @PART[sspx-inflatable-hab-125-2]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 7
- CrewCapacity = #$../MODULE[ModuleDeployableHabitat]/DeployedCrewCapacity$
- BaseHabMultiplier = 0.3
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.65
- }
- }
- }
- //PTD-E-1B 'Winston' Inflatable Habitation Module
- @PART[sspx-inflatable-hab-125-3]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 7
- CrewCapacity = #$../MODULE[ModuleDeployableHabitat]/DeployedCrewCapacity$
- BaseHabMultiplier = 0.3
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 0.65
- }
- }
- }
- //PFD-A Inflatable Habitation Module
- @PART[sspx-inflatable-hab-25-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 209
- CrewCapacity = #$../MODULE[ModuleDeployableHabitat]/DeployedCrewCapacity$
- BaseHabMultiplier = 2
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 12.45
- }
- }
- }
- //PFD-B Inflatable Habitation Module
- @PART[sspx-inflatable-hab-25-2]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 93
- CrewCapacity = #$../MODULE[ModuleDeployableHabitat]/DeployedCrewCapacity$
- BaseHabMultiplier = 1
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 5.65
- }
- }
- }
- //CENTRIFUGES
- //CTD-10 Inflatable Centrifuge Module
- @PART[sspx-inflatable-centrifuge-125-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 30
- CrewCapacity = #$../MODULE[ModuleDeployableCentrifuge]/DeployedCrewCapacity$
- BaseHabMultiplier = 1.2
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 8.5375
- }
- }
- }
- //CTD-5 Compact Inflatable Centrifuge Module
- @PART[sspx-inflatable-centrifuge-125-2]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 10
- CrewCapacity = #$../MODULE[ModuleDeployableCentrifuge]/DeployedCrewCapacity$
- BaseHabMultiplier = 0.6
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 2.65
- }
- }
- }
- //PFD-C Inflatable Centrifuge Module
- @PART[sspx-inflatable-centrifuge-25-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 121
- CrewCapacity = #$../MODULE[ModuleDeployableCentrifuge]/DeployedCrewCapacity$
- BaseHabMultiplier = 1.6
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 23.825
- }
- }
- }
- //PXL-E 'Mercury' Extensible Centrifuge
- @PART[sspx-expandable-centrifuge-375-1]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 288
- CrewCapacity = #$../MODULE[ModuleDeployableCentrifuge]/DeployedCrewCapacity$
- BaseHabMultiplier = 3.9
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 56.4
- }
- }
- }
- //PXL-F 'Pilgrim' Extensible Centrifuge
- @PART[sspx-expandable-centrifuge-375-2]:NEEDS[USILifeSupport]
- {
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USILS_HabitationSwapOption
- ConverterName = Habitat
- StartActionName = Start Habitat
- StopActionName = Stop Habitat
- BaseKerbalMonths = 108
- CrewCapacity = #$../MODULE[ModuleDeployableCentrifuge]/DeployedCrewCapacity$
- BaseHabMultiplier = 2.8
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 15.35
- }
- }
- }
- //Greenhouses
- //PPD-F412M Hydroponics Module
- @PART[sspx-greenhouse-25-1]:NEEDS[USILifeSupport]
- {
- RESOURCE
- {
- name = Mulch
- amount = 0
- maxAmount = 300
- }
- RESOURCE
- {
- name = Supplies
- amount = 0
- maxAmount = 300
- }
- RESOURCE
- {
- name = Fertilizer
- amount = 0
- maxAmount = 300
- }
- RESOURCE
- {
- name = ElectricCharge
- amount = 600
- maxAmount = 600
- }
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 2
- moduleIndex = 1
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USI_ConverterSwapOption
- ConverterName = Agroponics
- StartActionName = Start Agroponics
- StopActionName = Stop Agroponics
- INPUT_RESOURCE
- {
- ResourceName = Mulch
- Ratio = 0.00150000
- }
- INPUT_RESOURCE
- {
- ResourceName = Fertilizer
- Ratio = 0.00015000
- }
- OUTPUT_RESOURCE
- {
- ResourceName = Supplies
- Ratio = 0.00165000
- DumpExcess = False
- }
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 3.30
- }
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 2
- RecyclePercent = 0.7
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 3.5
- }
- }
- }
- //PXL-R4NCH-3R Hydroponics Module
- @PART[sspx-greenhouse-375-1]:NEEDS[USILifeSupport]
- {
- RESOURCE
- {
- name = Mulch
- amount = 0
- maxAmount = 500
- }
- RESOURCE
- {
- name = Supplies
- amount = 0
- maxAmount = 500
- }
- RESOURCE
- {
- name = Fertilizer
- amount = 0
- maxAmount = 500
- }
- RESOURCE
- {
- name = ElectricCharge
- amount = 1000
- maxAmount = 1000
- }
- MODULE
- {
- name = USI_SwapController
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_SwappableBay
- bayName = Bay 1
- moduleIndex = 0
- }
- MODULE
- {
- name = USI_Converter
- UseSpecialistBonus = false
- }
- MODULE
- {
- name = USI_ConverterSwapOption
- ConverterName = Agroponics
- StartActionName = Start Agroponics
- StopActionName = Stop Agroponics
- INPUT_RESOURCE
- {
- ResourceName = Mulch
- Ratio = 0.00250000
- }
- INPUT_RESOURCE
- {
- ResourceName = Fertilizer
- Ratio = 0.00025000
- }
- OUTPUT_RESOURCE
- {
- ResourceName = Supplies
- Ratio = 0.00275000
- DumpExcess = False
- }
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 5.25
- }
- }
- MODULE
- {
- name = USILS_LifeSupportRecyclerSwapOption
- ConverterName = Life Support
- StartActionName = Start Life Support
- StopActionName = Stop Life Support
- CrewCapacity = 3
- RecyclePercent = 0.7
- INPUT_RESOURCE
- {
- ResourceName = ElectricCharge
- Ratio = 5.25
- }
- }
- }
Add Comment
Please, Sign In to add comment