Jump to content

How to edit persistence file?


Recommended Posts

I've just been doing some rooting around in my save and I was wondering if anybody knew how to edit the persistence file? I know it's possible to spawn a new ship into a particular orbit or even change the orbit/position of a ship already up there, but I have yet to see how to actually do that or figure it out for myself. Is there a guide somewhere to what each variable needs/what it does?

I would love to be able to set up all my communications satellites into exactly identical, perfectly spaced kerbo-synchronous orbits but I could see this being useful for spawning a huge/unusually designed craft into orbit and I'm just kinda curious.

Thanks!

Link to comment
Share on other sites

All I have done is vessel substitution.

So lets say you want to insta-orbit something. So pick something already in orbit you don't care about (warning: it will be deleted). Copy the relevant vessel details, which is everything you see in the example below in bold. This is all the non-part details, except for pid, name and stg. Then delete that whole vessel entry and save the file. Now put the vessel you want on the launch pad or runway. Now exit the game and open the persistence file again. Find the vessel by name, the sit should show it being on the pad or runway. Now paste in all the details you copied, preserving the pid, name and stg of your new vessel. Save the file and enter the game again, and hey-presto, the craft is now in the orbit the other craft was.

If you want to specify a particular orbit then you need to adjust the ORBIT data. However, IMO, if you want something in Kerbo-stationary orbit, then you should do that playing the game :)

I only insta-orbit vessels rarely to test balance. I don't use it for real missions. With the center-of-X features in 0.17, i won't need to any more.


VESSEL
{
pid = 40fc91647b624f678398abaa74822a54
name = Galileo - Epsilon KL
[b]sit = ORBITING
landed = False
landedAt =
splashed = False
met = 2733736.78637049
lct = 10242454.713972
root = 0
lat = -0.0978857632452315
lon = -523.201267830071
alt = 2867790.71383903
hgt = -1
nrm = -0.5125027,-0.8196898,0.2558319
rot = 0.6101579,0.08489279,-0.3731015,0.693755
CoM = -0.0004872347,-1.463317,-0.01370263[/b]
stg = 0
[b]prst = False
eva = False
ORBIT
{
SMA = 3466647.98308393
ECC = 0.000536371356336351
INC = 0.0984309557060202
LPE = 44.0289865801569
LAN = 280.61945542462
MNA = 4.05016023592667
EPH = 12976191.5003425
REF = 1
OBJ = 0
}[/b]
...

Link to comment
Share on other sites

Some time ago, I wrote up a KSP Orbital Parameters Google Doc that discusses what the various values in the Orbit section of the persistence file mean, and how to adjust them to produce various results, as well as what needs to be adjusted if teleporting spacecraft off the launchpad is desired.

For on-rails circular orbits, the least complicated way to space things out evenly through file-editing would be to adjust the Argument of Periapsis (LPE), which is the in-orbital plane angle measured in degrees from the ascending node to the periapsis. If the seven other Keplerian parameters (SMA, ECC, INC, LAN, MNA, and EPH) are the same , and the orbit is circular (ECC = 0) , distributing LPE evenly around 360 degrees (e.g., for each of three satellites, 0, 120, and 240 for EPH) will result in even angular spacing.

Note: Back up the persistence file before editing. If you accidentally edit it in a manner that makes the file unreadable to the game, the game will blank the entire file.

Edited by maltesh
Link to comment
Share on other sites

  • 3 weeks later...
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...