zer0Kerbal / SimpleConstruction

Provides simple craft building capability in flight mode to stock parts for Kerbal Space Program.
https://forum.kerbalspaceprogram.com/index.php?/topic/191424-*/
GNU General Public License v3.0
6 stars 7 forks source link

[Bug 🐞]: KPBS Smelter not heating #63

Closed histalonia closed 2 years ago

histalonia commented 2 years ago

Brief description of your issue

When using this with Kerbal Planetary Base Systems (KPBS), I found everything worked great except the Smelter. The smelter was not heating, and had 2 heat core settings. (thus only 6% production)

I found a workaround by modifying the smelter.cfg file that comes with KPBS and changed line 82 from:
name = ELCoreHeat to: name = ModuleCoreHeat

And adjusting the value on lines 61, 75, and 83 from: 1873 to: 993

It now heats to 993, but the target efficiency goal is still 1000. I suspect with more tweeks I can make a new smelter.cfg that will work and that could be turned into a module manager patch.

Steps to reproduce

When making changes to smelter.cfg, the module needs to be removed from the craft design and then a new one readded, otherwise the changed settings will not take effect. The smelter file can be found at:
GameData\PlanetaryBaseInc\ModSupport\Parts\Extraplanetary Launchpads\smelter.cfg

Expected behavior

The KPBS smelter should heat and operate at an optimal temperature.

Actual behavior

The smelter was not heating, and had 2 heat core settings. (thus only 6% production)

Environment

KSP 1.12.3  w/Breaking Ground and Making History

Mods: 
Kerbal_Planetary_Base_Systems-1.6.14
ExtraplanetaryLaunchpads_v6.99.1
SimpleConstruction-4.0.99.1-prerelease   (overlayed on top of EL)

I also have (Heat_Control-0.6.1) but removing it didn't change any of the smelter's behavior.

My KSP install and mods are at c:\F\KSP1203\GameData

How did you download and install this?

SpaceDock (manual install)

github-actions[bot] commented 2 years ago

Thank you. Kindly read contributiing.md, code_of_conduct.md and styleguide.md. These are boilerplate.

zer0Kerbal commented 2 years ago

@histalonia Forum: histalona thank you for the bug report. This is a seriously hot topic... (pun intended) image

I believe this is the file and section of that file that needs to be addressed, especially since it probably is the culprit along with the fact that I can effect change on it but not on the KPBS file. 👍

https://github.com/zer0Kerbal/SimpleConstruction/blob/6efe50f4e2207f5c75cdf1e56148a9e6cb0f2164/GameData/SimpleConstruction/Compatibility/SimpleConstruction/KPBS.cfg#L83-L172

zer0Kerbal commented 2 years ago

@histalonia tracking the root cause - one is above, the other is was being patched twice - once from Compatibility/ISRU.cfg and again by Compatibility/KPBS.cfg

zer0Kerbal commented 2 years ago

@histalonia incoming changes seem to have taken:

parentUrl = PlanetaryBaseInc/ModSupport/Parts/Extraplanetary Launchpads/Smelter.cfg
    PART
    {
        name = KKAOSS_Smelter
        module = Part
        author = Nils277
        scale = 1
        rescaleFactor = 1
        node_stack_top = 0, 1.5580, 0, 0, 1, 0, 1
        node_stack_bottom = 0, -1.5580, 0, 0, -1, 0, 1
        node_stack_front = 0, 0, -0.73494, 0, 0, -1, 0
        node_stack_back = 0, 0, 0.6266, 0, 0, 1, 0
        TechRequired = advConstruction
        entryCost = 40000
        cost = 18000
        category = Utility
        subcategory = 0
        title = K&K Smelter
        manufacturer = K&K Advanced Orbit and Surface Structures
        description = The smelter can be used to process ore into useful metal. Do not touch! HOT!
        attachRules = 1,0,1,1,0
        mass = 2
        dragModelType = default
        maximum_drag = 0.2
        minimum_drag = 0.2
        angularDrag = 2
        crashTolerance = 15
        maxTemp = 2000
        bulkheadProfiles = PlanetaryBase
        tags = smelter metal ore launchpad planetary base
        MODEL
        {
            model = PlanetaryBaseInc/ModSupport/Parts/Extraplanetary Launchpads/Smelter
        }
        RESOURCE
        {
            name = Metal
            amount = 0
            maxAmount = 25
        }
        MODULE
        {
            name = ModuleResourceConverter
            ConverterName = Metal
            StartActionName = Start Metal Refining
            StopActionName = Stop Metal Refining
            AutoShutdown = true
            GeneratesHeat = true
            DefaultShutoffTemp = .8
            UseSpecialistBonus = true
            SpecialistEfficiencyFactor = 0.2
            SpecialistBonusBase = 0.05
            UseSpecialistHeatBonus = true
            SpecialistHeatFactor = 0.1
            ExperienceEffect = ConverterSkill
            EfficiencyBonus = 1
            resourceOutputName = Metal
            TemperatureModifier
            {
                key = 0 50000
                key = 750 25000
                key = 1000 5000
                key = 1250 2500
                key = 2000 2500
                key = 4000 0
            }
            ThermalEfficiency
            {
                key = 0 0 0 0
                key = 500 0.9 0 0
                key = 1000 1.0 0 0
                key = 1250 0.9 0 0
                key = 1500 0.5 0 0
                key = 3000 0.0 0 0
            }
            INPUT_RESOURCE
            {
                ResourceName = Ore
                Ratio = 1.0
                FlowMode = STAGE_PRIORITY_FLOW
            }
            INPUT_RESOURCE
            {
                ResourceName = ElectricCharge
                Ratio = 96
            }
            OUTPUT_RESOURCE
            {
                ResourceName = Metal
                Ratio = 1.0
                DumpExcess = false
                FlowMode = STAGE_PRIORITY_FLOW
            }
        }
        MODULE
        {
            name = ModuleOverheatDisplay
        }
        MODULE
        {
            name = ModuleCoreHeat
            CoreTempGoal = 1000
            CoreToPartRatio = 0.1
            CoreTempGoalAdjustment = 0
            CoreEnergyMultiplier = 0.1
            HeatRadiantMultiplier = 0.05
            CoolingRadiantMultiplier = 0
            HeatTransferMultiplier = 0
            CoolantTransferMultiplier = 0.01
            radiatorCoolingFactor = 1
            radiatorHeatingFactor = 0.01
            MaxCalculationWarp = 1000
            CoreShutdownTemp = 4000
            MaxCoolant = 500
        }
        RESOURCE
        {
            name = Ore
            amount = 0
            maxAmount = 50
        }
    }
}