Page 1 of 7

Save game@non-main stations(nms) & contracts@nms bug

Posted: Thu Aug 12, 2010 8:25 am
by mcarans
Not sure if this has been mentioned before, but I found that while you cannot access the contracts page using F8-F8 at a non-main station like the convenience store, it is possible to go to the local or galactic chart, then press the contract info button to get to it.

Posted: Thu Aug 12, 2010 8:38 am
by Kaks
Cool, will bugfix it asap! :)

Edit: Ok, it's fixed in trunk. Pressing '?' on the long range chart when docked at the main station still shows the passengers/cargo contracts. Doing so at any other station does diddly squat... :P

Posted: Thu Aug 12, 2010 10:59 am
by mcarans
Thanks.

On a related note, there is an OXP that seems to have stalled that allows saving the game in any station. (https://bb.oolite.space/viewtopic.php?t=5095)

How difficult would it be to make this standard in Oolite? The reason I need it is because my computer keeps crashing and if I have gone between con stores for a while, I lose everything since I was last at a main station.

Posted: Thu Aug 12, 2010 11:36 am
by Lestradae
mcarans wrote:
... an OXP that seems to have stalled that allows saving the game in any station. (https://bb.oolite.space/viewtopic.php?t=5095)

How difficult would it be to make this standard in Oolite? ...
Seconded.

Posted: Thu Aug 12, 2010 4:02 pm
by Kaks
mcarans wrote:
How difficult would it be to make this standard in Oolite?
Fairly fiddly & could introduce untold number of bugs.

Any change to the load/save routine so far resulted in about 8-9 separate commits before each change was reasonably bug free, and the loss of autoloading the last savegame for a couple of years...

Or you can submit a properly bugtested patch & the answer changes to not very at all, at least from the dev team's point of view... :D

Posted: Thu Aug 12, 2010 4:27 pm
by Eric Walch
Kaks wrote:
mcarans wrote:
How difficult would it be to make this standard in Oolite?
Fairly fiddly & could introduce untold number of bugs..... :D
And probably a rewrite of a great deal off the current oxps. To name one of the problems:

There are no oxp's installed and the player saves at a rock hermit. These hermits have no fixed position, so on restoring the game, Oolite can only add the hermit at the last known position. But on launch you will miss the asteroid field because Oolite has no way to determine which objects around the station belong to the station and which are just passing ships. There goes the whole illusion of a saved game.

With oxp's installed it becomes far more complicated as some missions have stations with very special setups of surrounding ships. Oolite cannot restore it so the oxp's need a rewrite to set up their own surroundings after a restore.

Posted: Thu Aug 12, 2010 4:52 pm
by Kaks
Very good point, Eric: to do a proper job, save anywhere would need to save & correctly restore each and every object within the system, its AI state, position, speed, equipment, js variables, overridden properties (texture & decals for example), and assorted variable properties (fuel, temperature, collected cargo, subentities positions, etc...) and a bazillion of other things...

That way, we won't break any oxps, all we'd have is a slightly melted developer's brain or two! :)

There's a lot of half-formed plans for Oolite 2. We might refactor all objects to allow for proper & 'easy' (it's never easy) de/serialisation. That could lead to a (buggy - oh noes, Oolite crashed as I was saving the game, woe is me!) save anywhere capability, at the expense of a lot of time 'thinking' while saving/loading games, and a pretty hefty increase in savegame sizes, but we haven't even got to Oolite 1.75 yet...

Posted: Thu Aug 12, 2010 7:32 pm
by Eric Walch
Kaks wrote:
to do a proper job, save anywhere would need to save & correctly restore each and every object within the system, its AI state, position, speed, equipment, js variables, overridden properties (texture & decals for example), and assorted variable properties (fuel, temperature, collected cargo, subentities positions, etc...) and a bazillion of other things...
Probably the only realistic approach would be to let the station generate its own surroundings and initialisation by a custom JS script. But that would only work for stations that are prepared to do that. That means only in stations that have a flag set that they allow saving there. However, that is not save-anywhere but save-somewhere-sometimes :wink:

Posted: Thu Aug 12, 2010 8:20 pm
by Cmd. Cheyd
Something like this does need to become an option though. Life as a long-term pirate/fugitive in Oolite otherwise suffers from an unrealistic necessity to visit a main station. The need to visit that station is not one imposed by the game universe, but rather by the real world requiring us to log off.

I realize it is not canonical Elite, but we've already proven Oolite is an expansion beyond that original universe. The move away from a player-centric universe is a key example.

Posted: Thu Aug 12, 2010 10:03 pm
by Commander McLane
Kaks wrote:
Very good point, Eric: to do a proper job, save anywhere would need to save & correctly restore each and every object within the system, its AI state, position, speed, equipment, js variables, overridden properties (texture & decals for example), and assorted variable properties (fuel, temperature, collected cargo, subentities positions, etc...) and a bazillion of other things...
I think we could get away with a little sloppiness here. First, the player is probably not aware of the objects outside his scanner range anyway, and second, launching takes 10 minutes game-time, so moving objects don't need to be exactly where they were before (actually it would be odd if they were).

Which doesn't mean that I would support a save-anywhere feature. It seems just a little too convenient to me, somehow cheaty... :roll:

..

Posted: Fri Aug 13, 2010 4:38 am
by Lestradae
Kaks wrote:
... to do a proper job, save anywhere would need to save & correctly restore each and every object within the system, its AI state, position, speed, equipment, js variables, overridden properties (texture & decals for example), and assorted variable properties (fuel, temperature, collected cargo, subentities positions, etc...) and a bazillion of other things ...
How big would a savegame file become if the whole system state was saved?

Because doing that when saving would make everything in a "save in any station" backwards compatible and not break anything, wouldn't it?

I think that "save anywhere" should, however, be restricted to stations and carriers when docked (I am aware that the above solution could allow saving everywhere, including outside stations). Perhaps an autosave might be added when coming out of witchspace. If one could save outside stations it would make the game massively easier - too easy, perhaps.

If it is at all doable, I would therefore suggest to make saving at any station or carrier possible when docked and perhaps as autosave at entering a new system with the whole game state stored.

That's my 0.2Cr.

Re: ..

Posted: Fri Aug 13, 2010 8:23 am
by Cmdr James
Lestradae wrote:
How big would a savegame file become if the whole system state was saved?
I dont think that would be easy to do, lots of things are not currently stored, so there would be a fair amnount of work changing the file structure, that is both effort and risk (get it wrong and things will break), also problems with compatability between versions...

It would probably be enough to store just the location of the current station together with what it is. At least for static stations, for carriers it might be more complex.

EDIT: It really depends what you mean by "the whole system state", clearly there would be a lot to store if we include all ships with all stats and all ai states so that the system can be frozen and rethawed exactly.

Re: ..

Posted: Fri Aug 13, 2010 9:00 pm
by Kaks
I would be very surprised if any save game using this kind of idea is going to be less than 15Mb... :)
Lestradae wrote:
If it is at all doable, I would therefore suggest to make saving at any station or carrier possible when docked and perhaps as autosave at entering a new system with the whole game state stored.
The technical point is that it isn't doable unless we make a lot of changes. It would literally affect/break everything the player can see & interact with in the game. We're talking an enormous amount of work to refactor huge parts of Oolite for relatively minor advantages.
In comparison, shaderifying planets feels like a pretty trivial thing, and it's something we're not going to see in stable, given the amount of potential bugs & incompatibilities that would take forever to sort out.


Instead of that save at any station thing - & if you want to be a career criminal - you can much more easily create an OXP providing a temporary amnesty seller, for example. The temporary amnesty could be one use only & set to expire in 5 minutes after the player undocks from the main station. It would allow the player to dock at main stations without any alarm or fines, conduct their business - buying and selling, save game - and launch from the station. Once launched the player could be notified that the amnesty will expire soon, then at the appointed time show "your amnesty is officially over" & reinstate the player's original bounty.

Posted: Sat Aug 14, 2010 9:21 am
by Disembodied
This may be (in fact, probably is) a dumb question, but is there an intermediate option? Instead of "save anywhere", is it possible to make, say, one other very specific type of station, e.g. pirate bases, which only exist in specific systems, and permit players to save there as well as in main stations, but nowhere else? Or is "save somewhere else" functionally the same as "save anywhere else"?

Posted: Sat Aug 14, 2010 9:50 am
by caracal
Disembodied wrote:
This may be (in fact, probably is) a dumb question, but is there an intermediate option? Instead of "save anywhere", is it possible to make, say, one other very specific type of station, e.g. pirate bases, which only exist in specific systems, and permit players to save there as well as in main stations, but nowhere else? Or is "save somewhere else" functionally the same as "save anywhere else"?
A short time ago when this topic came up, I suggested having a main station in certain Anarchy systems that would allow less-than-law-abiding commanders to dock unmolested, at least by the police. The idea got crapped on pretty soundly, but contrarian that I am, I tried it, it worked, and I have continued to develop it. I'll be releasing an "Anarchy Station OXP" before long, but given the reception the idea got initially, I'll probably only hand it out on certain street corners to the shadier-looking perverts who happen by and know the code word. ;)