Jump to content

[WIN] KML - Persistence file editor


Mythos

Recommended Posts

Hi @Mythos, if you add the search functionality, would you mind making it for vessels and kerbals the same type as the part search bar in  KSP 1.1 editors. You type stuff into the searchbar and the list automatically filters on the fly.

Link to comment
Share on other sites

  • 4 weeks later...

Released v0.7, see OP

 

On ‎05‎.‎04‎.‎2016 at 8:38 PM, Enceos said:

if you add the search functionality, would you mind making it for vessels and kerbals the same type as the part search bar in  KSP 1.1 editors. You type stuff into the searchbar and the list automatically filters on the fly

The search was not intended to be a filter, so it does not change the usual view. But the search window accepts instantaneous text input and will start to search on the fly. Current limitations: Type at least 3 letters, wait a second after last keystroke, display only first 100 results. 

Edited by Mythos
Link to comment
Share on other sites

7 hours ago, Mythos said:

No (not yet)

That's gonna be very difficult I think. There's only one mod which could pull that off, the "recover to VAB" option of Kerbal Construction Time. Works fine for stock vessels and simple parts, but not friendly with heavily modded installs.

Edited by Enceos
Link to comment
Share on other sites

@Mythos Really love the new search feature. There's just one more thing which forces me to go and edit the save in Notepad++.  Have you thought of adding the copy/paste/duplicate options to the rightclick menu of the nodes in the KML tree?

Edited by Enceos
Link to comment
Share on other sites

28 minutes ago, Enceos said:

Have you thought of adding the copy/paste/duplicate options to the rightclick menu of the nodes in the KML tree?

Yes, I think I've listed that first on the TODO

Link to comment
Share on other sites

Best tool ever!  Must-have for heavily modded games.  In just the last few hours of game-play I've fixed multiple broken docking ports, several ghost clone EVA kerbals, and a borked engine / tank combo.  No usability or corruption issues at all.  10*'s would buy again.

I can't thank you enough!

Link to comment
Share on other sites

  • 4 weeks later...

Fixed a bug about blank message and not doing anything on repair of a one-sided same-vessel docking problem. Now it will reset that dock to ready. In his case this was one small step to resolve his misconstruction problem, but I did the rest by hand - using KML as editor of course :):

On ‎02‎.‎06‎.‎2016 at 4:49 PM, schneida said:

but If I right click and say "Repair docking" I get a blank message and after saving the problem still exists...

Besides that I'm still writing unit tests to prepare fore some code cleanup and my time is rare at the moment. Next feature will still be copy & paste.

Link to comment
Share on other sites

17 hours ago, Enceos said:

how do I change the PreAttached docking ports to the Docked state?

Does it not detach in game?

You need to edit both ports:

  1. MODULE (ModuleDockingNode) -> state = PreAttached -> one goes to "Docked (dockee)" and the other one to "Docked (docker)" (I'd prefer the one who's parent to be dockee)
  2. Lookup the uid attribute from each part. Put the opposite one to MODULE (ModuleDockingNode) -> dockUId = <insert here>
  3. Create a new node "DOCKEDVESSEL" under MODULE (ModuleDockingNode) and provide the attributes, describing the vessel on same side as the dock:
    • vesselName = <dockee should have the name of your vessel, docker should have the name of docked vessel (since it's still preattached be creative)>

    • vesselType = <sorry can't use the "type = Ship" from vessel node, you need to give numbers>

                      0: Debris, 1: SpaceObject, 2: Unknown, 3: Probe, 4: Rover,

                      5: Lander, 6: Ship, 7: Station, 8: Base, 9: EVA

    • rootUid = <the root part uid of the vessel on this side of docking, on dockee side put uid of part [0], on docker side put uid of the docker part>

  4. On docker side go to MODULE (ModuleDockingNode) -> EVENTS -> Let Undock have "active = True" and Decouple have "active = False"
  5. Delete the node attachment to the other dock on both sides. Each one should have in the part "attN = <top, bottom or whatever>, <part number of the opposite dock part>". Delete that whole attribute and only that one.

You can skip part 3 and 4 but need to do 1, 2, 5 to let KML realize how it should look like. KML can then fix part 3 and 4 for you (using not very creative docked vessel name and type - should be changed in game afterwards).

 

Edit: Well, I said delete the attribute that says "attn = ..." but you can't do with current KML because it's not able to rebuild the structure yet and therefor delete is disabled. But you can change the number to -1. KML will then advise to save and reload, which you should do, and afterwards you will be able to delete that attribute in KML. 

Edited by Mythos
Was a little confused obout sides of DOCKEDVESSEL
Link to comment
Share on other sites

Can you guys help me or just give a little hand?

 

I cant dock a station with a small crew vessel in my current campaign. I tried to fix the docking ports, but when I look into the save file, both docking ports are already tagged as "Ready".

I dont know what to do now, I really don't want to lose that save file...

Link to comment
Share on other sites

5 hours ago, Trevisan said:

I cant dock a station with a small crew vessel

Can you give some more details?

It sounds like you have 2 vessels, than can not dock together. Such kind of problems often happen because of clipping or having another part attached to the dock (and visually moved by offset tool), construction problems in general. Docking problems caused by corrupted game status usually look like having some vessels docked and undock is either unable to click or just doing nothing.

Link to comment
Share on other sites

Sure. Thanks for your help

Bellow is a couple of screenshots of the current situation:

 

3KqUkhs.png?1

7UqBNWq.png

The station and the resupply ship are aligned and ready to dock, but they just bump into each other and keep at it. I haven't clipped any part on both vessels. The only "unusual" thing about the station is that the docking port is the root part. And looking into the save file, both ports are already marked as "state = Ready" but still they wont dock.

This is the Station docking port Module straight from my current save:

MODULE
                {
                    name = ModuleDockingNode
                    isEnabled = True
                    crossfeed = True
                    stagingEnabled = False
                    state = Ready
                    dockUId = 0
                    dockNodeIdx = 0
                    EVENTS
                    {
                        Undock
                        {
                            active = False
                            guiActive = True
                            guiActiveUncommand = False
                            guiIcon = Undock
                            guiName = Undock
                            category = Undock
                            guiActiveUnfocused = True
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        UndockSameVessel
                        {
                            active = False
                            guiActive = True
                            guiActiveUncommand = False
                            guiIcon = Undock
                            guiName = Undock
                            category = Undock
                            guiActiveUnfocused = True
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        Decouple
                        {
                            active = False
                            guiActive = True
                            guiActiveUncommand = False
                            guiIcon = Decouple Node
                            guiName = Decouple Node
                            category = Decouple Node
                            guiActiveUnfocused = True
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        SetAsTarget
                        {
                            active = True
                            guiActive = False
                            guiActiveUncommand = False
                            guiIcon = Set as Target
                            guiName = Set as Target
                            category = Set as Target
                            guiActiveUnfocused = True
                            unfocusedRange = 200
                            externalToEVAOnly = False
                        }
                        UnsetTarget
                        {
                            active = False
                            guiActive = False
                            guiActiveUncommand = False
                            guiIcon = Unset Target
                            guiName = Unset Target
                            category = Unset Target
                            guiActiveUnfocused = True
                            unfocusedRange = 200
                            externalToEVAOnly = False
                        }
                        EnableXFeed
                        {
                            active = False
                            guiActive = True
                            guiActiveEditor = True
                            guiActiveUncommand = False
                            guiIcon = Enable Crossfeed
                            guiName = Enable Crossfeed
                            category = Enable Crossfeed
                            guiActiveUnfocused = False
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        DisableXFeed
                        {
                            active = True
                            guiActive = True
                            guiActiveEditor = True
                            guiActiveUncommand = False
                            guiIcon = Disable Crossfeed
                            guiName = Disable Crossfeed
                            category = Disable Crossfeed
                            guiActiveUnfocused = False
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        MakeReferenceTransform
                        {
                            active = True
                            guiActive = True
                            guiActiveUncommand = False
                            guiIcon = Control from Here
                            guiName = Control from Here
                            category = Control from Here
                            guiActiveUnfocused = False
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                        ToggleStaging
                        {
                            active = True
                            guiActive = False
                            guiActiveEditor = True
                            guiActiveUncommand = False
                            guiIcon = Disable Staging
                            guiName = Port: Enable Staging
                            category = Disable Staging
                            guiActiveUnfocused = False
                            unfocusedRange = 2
                            externalToEVAOnly = True
                        }
                    }
                    ACTIONS
                    {
                        UndockAction
                        {
                            actionGroup = None
                        }
                        DecoupleAction
                        {
                            actionGroup = None
                        }
                        EnableXFeedAction
                        {
                            actionGroup = None
                        }
                        DisableXFeedAction
                        {
                            actionGroup = None
                        }
                        ToggleXFeedAction
                        {
                            actionGroup = None
                        }
                    }
                }

I noticed the dockUId = 0 value, is it normal?

Link to comment
Share on other sites

@Trevisan Actually the fastest way to solve this problem is to detach these ports via KIS and place them into a KIS container. They will reset their settings and be ready for reattaching and docking. If the station docking port is a root part you can hover over its first child part and cut it from the docking port via "H" button. It will become a parent part and the docking port will come off, ready for grabbing.

Link to comment
Share on other sites

5 hours ago, Trevisan said:

I noticed the dockUId = 0 value, is it normal?

I've often seen old dockUId values hanging around from previous docking situations. That's no problem when the state is ready. But you are right, that is not necessary and you could try to delete it. The rest of your MODULE content looks fine. Having the dock as root part should also be no problem. Can you upload the savefile anywhere? Or you should try what Enceos said.

Link to comment
Share on other sites

Thanks again, guys.

Finally got some time to play KSP did what Enceos said and it worked. But before stowing the ports in a KIS container, I uninstalled two mods, and I guess they must be to blame for that (mod Incompatibility). One Mod adds a Mechjeb module to every command pod and the other adds a Kerbal Engineering Remix module to them. I'll have to do m]further testing in order to figure out what happening and to make sure this issue does not happen again.

MPJvBm1.png

@Mythos Do you have any suggestion? Pastebin wont allow due to the size limitation for free accounts

Link to comment
Share on other sites

On ‎19‎.‎06‎.‎2016 at 5:23 PM, Trevisan said:

Do you have any suggestion?

Sorry for my late answer. As long as your problem is solved now I'm happy. I'd rather not dig into analysis of a solved problem as my time is rare at the moment. 

Link to comment
Share on other sites

On 6/25/2016 at 7:48 PM, Mythos said:

Sorry for my late answer. As long as your problem is solved now I'm happy. I'd rather not dig into analysis of a solved problem as my time is rare at the moment. 

No problem at all. I literally know that feel. Tried to dock another ship after and the issue still persists, it must have been something to do with the docking ports themselves. 

Link to comment
Share on other sites

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...