Jump to content

persistent.sfs CONTRACT_FINISHED vs ?


Recommended Posts

I'm wondering if anyone knows how the data that drives the checkbox is stored?

I'm finding the count doesn't map directly to the CONTRACT_FINISHED entries.

ScreenShot2014-09-02at221126_zps3d1c9364.png

Thanks.

EDIT: updated to 'answered'.

Edited by Trann
Link to comment
Share on other sites

In walking through things, all CONTRACT_FINISHED entries have "state = Completed" and the nested PARAMs have "state = Complete" while all CONTRACT entries have either "state = Offered" or "state = Accepted".

I'm sure CONTRACT gets changed to CONTRACT_FINISHED when appropriate which makes sense.

The issue I see is that there are 22 finished contracts in the persistent.sfs file while there are 29 checks in the GUI. I suspect a mod is clobbering the completed contracts somehow so I'm trying to figure out what I can search for in the file (and in backups of the file) to discover the mismatch.

...

But this is all academic. If no one knows, that's fine, too.

Link to comment
Share on other sites

CONTRACT_FINISHED entries are your stored completed contracts. If you go into Mission Control and click on the "Archives" tab, you'll see them listed there.

The checkmarks you've pictured in your screenshot are messages from completing contracts. Most contracts only generate one message when you complete them; the exception is the "Explore Mun"-type contract, which has four separately-completed objectives, each of which generates its own message. Certain mods (e.g. DebRefund or StageRecovery) also create messages; I daresay KSP itself will create more messages itself as more functionality gets added.

If you look at the bottom of your persistent.sfs, you'll find a block labeled MESSAGESYSTEM, with MESSAGE sub-blocks inside. That's where your "29 checks" are stored.

Link to comment
Share on other sites

The MESSAGESYSTEM block is where it's at. Inside were messages with "Contract Complete" vs "Contract Parameter Complete". A count of the former matches the number of CONTRACT_FINISHED entries; adding the latter accounts for the number of overall checkmarks displayed in the GUI (29).

Thanks muchly.

And for the sake of sharing...

Searching for the PARAM "state = Complete" gives a much higher number because its sub-PARAMs are conditions that must be met before the test can be considered a success. For example, a part test might have

PARAM
{
name = PartTest
PARAM
{
name = ReachDestination
}
PARAM
{
name = ReachSituation
}

So it would be more accurate to exclude those sub-PARAMs in the count of completed contracts.

If you're so inclined. :)

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