Jump to content

Editing a craft file to remove fuel?


Recommended Posts

If it's not a lot of parts that need emptying, then you can actually zoom the camera inside any parts of your craft -- then select the proper tank and empty it, in the normal fashion. It's disorienting, so it takes extra time to do.

Link to comment
Share on other sites

It's 2 2.5m short tanks containing between 30-50 part clipped tanks inside each.  Zooming the camera inside the parts is near impossible compared to setting some numbers in the craft file to 0. I also don't want to reconstruct it as balancing it took 6-8 hours, I really just need to know how to manually edit fuel values in the craft file. 

Link to comment
Share on other sites

While I would love to be able to give you a direct answer ("Go to X position, change Y value"), the information I can give you is this: If manipulating the KSP GUI is too difficult, you may find editing .CRAFT files (or possibly the .SFS file that contains the particular instance of your vessel) to be more onerous to deal with - if you have "30-50 part clipped tanks inside each...2.5m short tank", you will have a difficult time identifying which tank is which - they have long, arbitrarily assigned ID numbers that computers are well-suited to process but not humans... and if the tanks you wish to empty are only in specific positions, well, the task will become an exercise in futility as you would have to look at data that numerically indicates how each clipped tank is offset from the parent part... << s h u d d e r >>

If you're "Rain Man", please proceed. If you're like most of us here, @bewing's advice is probably your best bet.

As an aside, if the amount of fuel is a constant, I would figure out how and where to place an equivalent tank or two that would imitate the CoM effect; if the fuel removal is dynamic (i.e. has to change during operation), at the very least I would reduce the number of tanks required (by a lot) so that I could use the "Fuel Tab" to open ALL the tanks' PAWs, pin the ones I need to manipulate and remove the rest...

Link to comment
Share on other sites

easy enough. you open the file, there you have a list of parts. parts that can store stuff that can be consumed (fuel, ore, electricity) have a "resource" tab. there you can set your value as you will. under the spoiler you will find such a part, with the relevant resource parts highlighted.

what's actually difficult is figuring out on which tank you are actually removing resources. it may be more convenient to empty all of them and refill manually those you want filled

Spoiler

PART
{
    part = adapterMk3-Size2_4294367610
    partName = Part
    persistentId = 4389373
    pos = -1.36545908,9.23618221,0.32553196
    attPos = 0,0,0
    attPos0 = 7.10543278E-14,-1.87500072,5.96039627E-08
    rot = 0.707106829,0,0,0.707106829
    attRot = 0,0,0,1
    attRot0 = 1.5529411E-22,-3.55271326E-15,7.1054299E-15,1
    mir = 1,1,1
    symMethod = Mirror
    autostrutMode = Off
    rigidAttachment = False
    istg = -1
    resPri = 0
    dstg = 0
    sidx = -1
    sqor = -1
    sepI = -1
    attm = 0
    sameVesselCollision = False
    modCost = 0
    modMass = 0
    modSize = 0,0,0
    link = asasmodule1-2_4294591422
    link = dockingPort2_4289180362
    attN = top,asasmodule1-2_4294591422_0|1.875|0_0|1|0_0|1.875|0_0|1|0
    attN = bottom,mk3FuselageLF.50_4294470278_0|-1.875|0_0|-1|0_0|-1.875|0_0|-1|0
    EVENTS
    {
    }
    ACTIONS
    {
        ToggleSameVesselInteraction
        {
            actionGroup = None
            wasActiveBeforePartWasAdjusted = False
        }
        SetSameVesselInteraction
        {
            actionGroup = None
            wasActiveBeforePartWasAdjusted = False
        }
        RemoveSameVesselInteraction
        {
            actionGroup = None
            wasActiveBeforePartWasAdjusted = False
        }
    }
    PARTDATA
    {
    }
    RESOURCE
    {
        name = LiquidFuel
        amount = 1125
        maxAmount = 1125

        flowState = True
        isTweakable = True
        hideFlow = False
        isVisible = True
        flowMode = Both
    }
    RESOURCE
    {
        name = Oxidizer
        amount = 0
        maxAmount = 1375

        flowState = True
        isTweakable = True
        hideFlow = False
        isVisible = True
        flowMode = Both
    }
}

 

 

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...