// Compatibility patches for IndicatorLights and ReStock // Thanks to UnanimousCoward on the KSP forums for supplying this patch! // Mod thread for ReStock: // https://forum.kerbalspaceprogram.com/index.php?/topic/182679-17x-restock-revamping-ksps-art-may-10-ksp-17-fixes/ // // Many of the light locations defined by the base IL mod for a stock game // are poorly placed for ReStock and still need work. The ReStock patch // is a work in progress // -Tonka Crash // //---------------------------------------------------------------------------// // Fix duplicate models where IL added a model based on the original parts // having a mesh=model syntax. Restock does this too, so parts end up with // duplicate models for the basic part. Sometimes it's not obvious if the // stock part was not whitelisted. But this will throw an error since the // model was removed by ReStock. The worst case is the part was whitelisted, // so both models overlay each other. The simplest fix is to just delete the // reduncdant model nodes. -Tonka Crash //---------------------------------------------------------------------------// @PART[advSasModule]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Command/inlineAdvancedStabilizer/model]] { } } @PART[asasmodule1-2]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Command/advancedSasModuleLarge/model]] { } } @PART[cupola]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Command/cupola/model]] { } } @PART[crewCabin]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Command/hitchhikerStorageContainer/model]] { } } @PART[landerCabinSmall]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Command/mk1LanderCan/model]] { } } @PART[ISRU]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Resources/ISRU/ISRU]] { } } @PART[SurfaceScanner]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Resources/SurfaceScanner/SurfaceScanner]] { } } @PART[Large_Crewed_Lab]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Science/LargeCrewedLab/large_crewed_lab]] { } } //---------------------------------------------------------------------------// // Antennas // //---------------------------------------------------------------------------// // RA-2, RA-15 and RA-100 Relay Antennas have model variants that change // the position of the feed horn. The IL position is a compromise that // is designed to be visible in both positions. // // RA-2 Relay Antenna @PART[RelayAntenna5]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0, .38, 0 scale = 2.0, 2.0, 1 rotation = -90, 0, 0 } } // RA-15 Relay Antenna @PART[RelayAntenna50]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0, 1.125, 0 scale = 2, 2, 2.5 rotation = -90, 0, 0 } } // RA-100 Relay Antenna @PART[RelayAntenna100]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0, 1.18, 0 scale = 1.5, 1.5, 5 rotation = -90, 0, 0 } } // Communotron 16 @PART[longAntenna]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Utility/commsDish16/model]] { } !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0, 0, 0 scale = 1.6, 1.6, 2.5 rotation = -90, 0, 0 } } // Communotron 16-S @PART[SurfAntenna]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp2]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp2 position = 0, 0.065, -0.003 scale = 1.6, 0.5, 0.7 rotation = 0, 0, 0 } } // Communotron 88-88 @PART[commDish]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Utility/commDish88-88/model]] { } !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0, 0.17, 0 scale = 5.7, 5.7, 6 rotation = -90, 0, 0 } } // Communotron DTS-M1 @PART[mediumDishAntenna]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[Squad/Parts/Utility/commsAntennaDTS-M1/mediumDishAntenna]] { } !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp2]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp2 position = 0, 0.061, -0.5 scale = 1.8, 0.5, 0.5 rotation = -25, 0, 0 } } // Communotron HG-5 High Gain Antenna @PART[HighGainAntenna5]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp2]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp2 position = -0.162, 0.036, -0.007 scale = 1, 0.5, 1.15 rotation = 0, 0, 90 } } // Communotron HG-55 @PART[HighGainAntenna]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp2]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp2 position = 0.045, 0.121, 0.1 scale = 2.5, 1, 0.8 } } //---------------------------------------------------------------------------// // Batteries // //---------------------------------------------------------------------------// // ReStock batteries have a green emissive glow that doesn't change with the // colour of the lamp. Fixing this requires modifying // GameData\ReStock\Assets\Electrical\restock-batteries-1-e.dds and // restock-batteries-2-e.dds,but the ReStock licence doesn't permit this. // // Ideal light location would be to put a IL over the green emissive spot // to make it appear active, but original writer of this patch decided to // just add lights to mimic stock part locations. I haven't had time or // desire to sort this out for all cases. // - Tonka Crash // // 0.625m battery bank @PART[batteryBankMini]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Electrical/restock-battery-0625-1 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.6, 0.6, 1 position = -0.141, -0.003, -0.245 rotation = 0, 207, 0 } @MODULE[ModuleControllableEmissive] { @target = IndicatorLights/Meshes/nubbinLamp } } // 1.25m battery bank @PART[batteryBank]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Electrical/restock-battery-125-1 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.65, 0.65, 1 position = 0.49, 0.03, -0.34 rotation = 0, 130, 0 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.65, 0.65, 1.1 position = 0.554, 0.03, -0.22 rotation = 0, 120, 0 } @MODULE[ModuleControllableEmissive] { @target = IndicatorLights/Meshes/nubbinLamp } } // 2.5m battery bank @PART[batteryBankLarge]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Electrical/restock-battery-25-1 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.65, 0.65, 1 position = 0.815, -0.028, -0.88 rotation = 0, 130, 0 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.65, 0.65, 1 position = 0.775, 0.027, -0.92 rotation = 0, 135, 0 } @MODULE[ModuleControllableEmissive] { @target = IndicatorLights/Meshes/nubbinLamp } } // Small radial battery @PART[batteryPack]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Electrical/restock-battery-radial-small-1 } MODEL { // Cover ReStock Emissive - TonkaCrash // have to keep z100lamp or rewrite more of the stock patch model = IndicatorLights/Meshes/z100lamp scale = 0.75, 0.5, 0.75 position = 0.0405,0.211,-.104 rotation = 270, 0, 0 } } // Large radial battery @PART[ksp_r_largeBatteryPack]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Electrical/restock-battery-radial-med-1 } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = -0.0228, 0.2725, -0.115 scale = 0.58, 0.58, 0.58 rotation = 180, 0, 0 } MODEL { model = IndicatorLights/Meshes/nubbinLamp position = 0.0228, 0.2725, -0.115 scale = 0.58, 0.58, 0.58 rotation = 180, 0, 0 } } //---------------------------------------------------------------------------// // Crewable // //---------------------------------------------------------------------------// //Cupola @PART[cupola]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, -0.147, -1.37 rotation = 0, 180, 0 } } //Hitchhiker @PART[crewCabin]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } !MODULE[ModuleControllableEmmissive] {} MODEL { model = IndicatorLights/Meshes/squareLamp position = -0.1, 0.215, -1.28 scale = 1, 0.25, 0.5 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp position = 0.08, 0.215, -1.28 scale = 1, 0.25, 0.5 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp position = -0.1, -0.215, -1.28 scale = 1, 0.25, 0.5 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp position = 0.08, -0.215, -1.28 scale = 1, 0.25, 0.5 rotation = 0, 180, 0 } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp:0 emissiveName = indicator0 } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp:1 emissiveName = indicator1 } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp:2 emissiveName = indicator2 } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp:3 emissiveName = indicator3 } } //Mk1-3 pod @PART[mk1-3pod]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/nubbinLamp]],* { } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.6, 0.6, 0.5 position = -0.272, 0.825, -0.736 rotation = -160, 15, 0 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.6, 0.6, 0.5 position = -0.2875, 0.745, -0.764 rotation = -160, 15, 0 } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 0.6, 0.6, 0.5 position = -0.303, 0.665, -0.793 rotation = -160, 15, 0 } } //Mk1 Lander Can @PART[landerCabinSmall]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, -0.215, -0.85 rotation = 0, 180, 0 } } //Mk1 Pod (v2) @PART[mk1pod_v2]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1.15, 0.25, 0.5 position = 0, 0.25, -0.435 rotation = -160, 0, 0 } } //Mk2 lander can (V2) @PART[mk2LanderCabin_v2]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0.0, 0.365, -1.378 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1.0, 0.25, 0.5 position = 0, 0.745, 0.245 rotation = -90, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0.0, -0.065, -1.378 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, 0.745, -0.245 rotation = -90, 0, 0 } } //Large science lab @PART[Large_Crewed_Lab]:AFTER[ReStock]:NEEDS[IndicatorLights] { !MODEL:HAS[#model[IndicatorLights/Meshes/squareLamp]],* { } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, -0.225, -1.3 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, -0.225, 1.3 rotation = 0, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, 0.21, -1.3 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.25, 0.5 position = 0, 0.21, 1.3 rotation = 0, 0, 0 } } //---------------------------------------------------------------------------// //Docking // //---------------------------------------------------------------------------// //Large docking port @PART[dockingPortLarge]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} -MODULE[ModuleColorChanger]{} -MODULE[ModuleControllableEmissive]{} -MODULE[ModuleToggleLED]{} -MODULE[ModuleDockingCrossfeedIndicator]{} -MODULE[ModuleDockingStateIndicator]{} MODEL { model = ReStock/Assets/Coupling/restock-docking-25-1 } MODEL { model = ReStock/Assets/Command/restock-hatch-common-round-white-1 position = 0.0, -0.085, 0.0 scale = 0.821,0.821,0.821 rotation = 180, 0, 0 } %rescaleFactor = 1 MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 2 position = 0.0, 0.25, 1.13 rotation = 12, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 2 position = 0.0, 0.26, -1.13 rotation = 0, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 2.0, 1, 0.3 position = -0.8, 0.25, 0.8 rotation = 0, 46.5, 12 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 2.0, 1, 0.3 position = 0.8, 0.25, 0.8 rotation = 0, -46.5, -12 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.3, 1.6, 1 position = 0, 0.18, -1.3 rotation = 0, 180, 90 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.3, 1.6, 1 position = 1.117, 0.18, 0.6475 rotation = 0, 60, 90 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.3, 1.6, 1 position = -1.117, 0.18, 0.6475 rotation = 0, -60, 90 } MODULE { name = ModuleColorChanger shaderProperty = _EmissiveColor animRate = 0.8 animState = false useRate = true toggleInEditor = true toggleInFlight = true toggleInFlight = true unfocusedRange = 5 toggleName = #autoLOC_502011 //#autoLOC_502011 = Toggle Lights eventOnName = #autoLOC_502012 //#autoLOC_502012 = Lights On eventOffName = #autoLOC_502013 //#autoLOC_502013 = Lights Off toggleAction = True defaultActionGroup = Light redCurve { key = 0 0 0 3 key = 1 1 0 0 } greenCurve { key = 0 0 0 1 key = 1 1 1 0 } blueCurve { key = 0 0 0 0 key = 1 0.7 1.5 0 } alphaCurve { key = 0 1 } } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp emissiveName = indicator } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp2 emissiveName = indicator } MODULE { name = ModuleToggleLED activeColor = ModuleDockingCrossfeedIndicator inactiveColor = $Off defaultActionGroup = Light } MODULE { name = ModuleDockingCrossfeedIndicator } MODULE { name = ModuleDockingStateIndicator emissiveName = indicator readyColor = ModuleToggleLED acquireColor = blink(ModuleDockingCrossfeedIndicator, 100, $Off, 100) disengageColor = blink(ModuleDockingCrossfeedIndicator, 120, $Off, 1080) } } //Shielded docking port @PART[dockingPort1]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} -MODULE[ModuleColorChanger]{} -MODULE[ModuleControllableEmissive]{} -MODULE[ModuleToggleLED]{} -MODULE[ModuleDockingCrossfeedIndicator]{} -MODULE[ModuleDockingStateIndicator]{} // Rotate shielded port so it opens with bilateral symmetry not sure // why Nertea has default placement for this rotatated 90 deg around // ship's longitudinal axis. It looks sloppy to me. // // Patch opens 1 down two up because this works best for my most used // pods. For stock mk1-3 opposite orientation probably works better. // - TonkaCrash MODEL { model = ReStock/Assets/Coupling/restock-docking-shielded-125-1 rotation = 0, 90, 0 // 1 down, two up //rotation = 0, -90, 0 // 1 up, two down } MODEL { model = ReStock/Assets/Command/restock-hatch-common-round-white-1 position = 0.0, -0.072, 0.0 scale = 0.908,0.908,0.908 rotation = 180, 0, 0 } %rescaleFactor = 1 MODEL //left { model = IndicatorLights/Meshes/squareLamp2 scale = 0.7, 1, 0.3 position = -0.24395, 0.271, 0.24395 rotation = 0, 46.5, 0 } MODEL //right { model = IndicatorLights/Meshes/squareLamp2 scale = 0.7, 1, 0.3 position = 0.24395, 0.271, 0.24395 rotation = 0, -46.5, 0 } MODEL //bottom { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 0.7 position = 0, 0.271, -0.35 rotation = 0, 0, 0 } MODEL //top { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 0.7 position = 0, 0.271, 0.345 rotation = 0, 0, 0 } MODULE { name = ModuleColorChanger shaderProperty = _EmissiveColor animRate = 0.8 animState = false useRate = true toggleInEditor = true toggleInFlight = true toggleInFlight = true unfocusedRange = 5 toggleName = #autoLOC_502011 //#autoLOC_502011 = Toggle Lights eventOnName = #autoLOC_502012 //#autoLOC_502012 = Lights On eventOffName = #autoLOC_502013 //#autoLOC_502013 = Lights Off toggleAction = True defaultActionGroup = Light redCurve { key = 0 0 0 3 key = 1 1 0 0 } greenCurve { key = 0 0 0 1 key = 1 1 1 0 } blueCurve { key = 0 0 0 0 key = 1 0.7 1.5 0 } alphaCurve { key = 0 1 } } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp2 emissiveName = indicator } MODULE { name = ModuleToggleLED activeColor = ModuleDockingCrossfeedIndicator inactiveColor = $Off defaultActionGroup = Light } MODULE { name = ModuleDockingCrossfeedIndicator } MODULE { name = ModuleDockingStateIndicator emissiveName = indicator readyColor = ModuleToggleLED acquireColor = blink(ModuleDockingCrossfeedIndicator, 100, $Off, 100) disengageColor = blink(ModuleDockingCrossfeedIndicator, 120, $Off, 1080) } } //Medium docking port @PART[dockingPort2]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} -MODULE[ModuleColorChanger]{} -MODULE[ModuleControllableEmissive]{} -MODULE[ModuleToggleLED]{} -MODULE[ModuleDockingCrossfeedIndicator]{} -MODULE[ModuleDockingStateIndicator]{} MODEL { model = ReStock/Assets/Coupling/restock-docking-125-1 } MODEL { model = ReStock/Assets/Command/restock-hatch-common-round-white-1 position = 0.0, -0.072, 0.0 scale = 0.908,0.908,0.908 rotation = 180, 0, 0 } %rescaleFactor = 1 MODEL //left { model = IndicatorLights/Meshes/squareLamp2 scale = 1.5, 1, 0.3 position = -0.37696, 0.08, 0.37696 rotation = 0, 46.5, 18 } MODEL //right { model = IndicatorLights/Meshes/squareLamp2 scale = 1.5, 1, 0.3 position = 0.37696, 0.08, 0.37696 rotation = 0, -46.5, -18 } MODEL //bottom { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 1.5 position = 0, 0.08, -0.5331 rotation = -18, 0, 0 } MODEL //top { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 1, 1.5 position = 0, 0.08, 0.5331 rotation = 18, 0, 0 } MODULE { name = ModuleColorChanger shaderProperty = _EmissiveColor animRate = 0.8 animState = false useRate = true toggleInEditor = true toggleInFlight = true toggleInFlight = true unfocusedRange = 5 toggleName = #autoLOC_502011 //#autoLOC_502011 = Toggle Lights eventOnName = #autoLOC_502012 //#autoLOC_502012 = Lights On eventOffName = #autoLOC_502013 //#autoLOC_502013 = Lights Off toggleAction = True defaultActionGroup = Light redCurve { key = 0 0 0 3 key = 1 1 0 0 } greenCurve { key = 0 0 0 1 key = 1 1 1 0 } blueCurve { key = 0 0 0 0 key = 1 0.7 1.5 0 } alphaCurve { key = 0 1 } } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp2 emissiveName = indicator } MODULE { name = ModuleToggleLED activeColor = ModuleDockingCrossfeedIndicator inactiveColor = $Off defaultActionGroup = Light } MODULE { name = ModuleDockingCrossfeedIndicator } MODULE { name = ModuleDockingStateIndicator emissiveName = indicator readyColor = ModuleToggleLED acquireColor = blink(ModuleDockingCrossfeedIndicator, 100, $Off, 100) disengageColor = blink(ModuleDockingCrossfeedIndicator, 120, $Off, 1080) } } //Small docking port @PART[dockingPort3]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} -MODULE[ModuleColorChanger]{} -MODULE[ModuleControllableEmissive]{} -MODULE[ModuleToggleLED]{} -MODULE[ModuleDockingCrossfeedIndicator]{} -MODULE[ModuleDockingStateIndicator]{} MODEL { model = ReStock/Assets/Coupling/restock-docking-0625 } %rescaleFactor = 1 MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 0.6, 0.3 position = 0.000, 0.05, -0.275 rotation = -40, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.9, 0.6, 0.3 position = 0.000, 0.065, -0.255 rotation = -40, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 0.6, 0.3 position = -0.275, 0.05, 0 rotation = 0, 0, 40 } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.3, 0.6, 0.3 position = 0.275, 0.05, 0 rotation = 0, 0, -40 } MODULE { name = ModuleColorChanger shaderProperty = _EmissiveColor animRate = 0.8 animState = false useRate = true toggleInEditor = true toggleInFlight = true toggleInFlight = true unfocusedRange = 5 toggleName = #autoLOC_502011 //#autoLOC_502011 = Toggle Lights eventOnName = #autoLOC_502012 //#autoLOC_502012 = Lights On eventOffName = #autoLOC_502013 //#autoLOC_502013 = Lights Off toggleAction = True defaultActionGroup = Light redCurve { key = 0 0 0 3 key = 1 1 0 0 } greenCurve { key = 0 0 0 1 key = 1 1 1 0 } blueCurve { key = 0 0 0 0 key = 1 0.7 1.5 0 } alphaCurve { key = 0 1 } } MODULE { name = ModuleControllableEmissive target = IndicatorLights/Meshes/squareLamp2 emissiveName = indicator } MODULE { name = ModuleToggleLED activeColor = ModuleDockingCrossfeedIndicator inactiveColor = $Off defaultActionGroup = Light } MODULE { name = ModuleDockingCrossfeedIndicator } MODULE { name = ModuleDockingStateIndicator emissiveName = indicator readyColor = ModuleToggleLED acquireColor = blink(ModuleDockingCrossfeedIndicator, 100, $Off, 100) disengageColor = blink(ModuleDockingCrossfeedIndicator, 120, $Off, 1080) } } //---------------------------------------------------------------------------// // SAS // //---------------------------------------------------------------------------// //Medium and large reaction wheels don't need patching. //Small reaction wheel @PART[sasModule]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Control/restock-reactionwheel-625-1 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.65, 0.65, 1 position = 0, 0, 0.31 rotation = 0, 0, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.65, 0.65, 1 position = 0, 0, -0.31 rotation = 0, 180, 0 } } //---------------------------------------------------------------------------// // Science // //---------------------------------------------------------------------------// //Surface scanning module doesn't need patching. //Accelerometer @PART[sensorAccelerometer]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-accelerometer } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 1, 1, 0.5 position = -0.0345, 0.085, -0.125 rotation = -90, 0, 0 } } //Barometer @PART[sensorBarometer]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-barometer } MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 1, 1, 0.5 position = -0.0445, 0.115, -0.077 rotation = -90, 0, 0 } } //Goo @PART[GooExperiment]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-goocanister-radial-1 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.5, 1.7, 0.5 position = -0.1842, 0, -0.325 rotation = 0, -90, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.5, 1.7, 0.5 position = 0.1842, 0, -0.325 rotation = 0, 90, 0 } } //Gravioli @PART[sensorGravimeter]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-gravimeter } MODEL { model = IndicatorLights/Meshes/squareLamp2 scale = 0.6, 0.6, 0.6 position = 0.0355, -0.0683, -0.1367 rotation = -90, 0, 0 } } //Science Box @PART[ScienceBox]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-sciencebox-radial-1 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.2, 4, 0.5 position = -0.2245, -0.09, -0.225 rotation = 0, 225, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.2, 4, 0.5 position = 0.2245, -0.09, -0.225 rotation = 0, 135, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.2, 4, 0.5 position = 0.2245, -0.09, 0.225 rotation = 0, 45, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.2, 4, 0.5 position = -0.225, -0.09, 0.225 rotation = 0, 315, 0 } } //Materials @PART[science_module]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-materialbay-125-1 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.4, 0.5 position = 0, -0.475, -0.6275 rotation = 0, 180, 0 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 1, 0.4, 0.5 position = 0, -0.475, 0.6275 rotation = 0, 0, 0 } } //Thermometer @PART[sensorThermometer]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-thermometer } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.6, 0.2, 0.5 position = 0, 0.11616, -0.05018 rotation = 0, 180, 0 } } //Atmosphere sensor (variometer) @PART[sensorAtmosphere]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-GCMS-1 } MODEL { model = IndicatorLights/Meshes/squareLamp scale = 0.3, 2, 0.3 position = 0, 0.11416, -0.30133 rotation = 0, 180, 90 } } //Sentinel Sensor @PART[InfraredTelescope]:AFTER[ReStock]:NEEDS[IndicatorLights] { -MODEL,* {} MODEL { model = ReStock/Assets/Science/restock-sentinel-1 } MODEL { // Was a ring around the lens, but to avoid obsuring // telescope tube and sensor move to 2nd small indicator model = IndicatorLights/Meshes/nubbinLamp scale = 1.5, 1.5, 1 position = -.30, 1.06, -0.42 rotation = -30, 180, 0 } // small side lamp, shows science availability MODEL { model = IndicatorLights/Meshes/nubbinLamp scale = 1.5, 1.5, 1 position = -.30, 0.96, -0.47 rotation = -30, 180, 0 } }