Space Engineers

Space Engineers

Projector Preview - miniature blueprint display + damage status
This topic has been locked
sharkle 4 Aug, 2019 @ 5:07am
Previews causing large file size
This seems unsuited for anything with a bit more complexity currently. For example I just removed the projection of a medium sized station and thus reduced my save file size from 460mb to 113mb.

It looks to me like there is some nesting going on where the projection sometimes stores the projection itself. This may recurse in some circumstances.

I just looked at my gigantic save (sanbox_0_0_0.sbs) to figure out what was causing it and a simple example is a small craft that has exactly 1 remote control block. But in the save this remote control block's unique name was stored 8 times, 3 of which were the remote control block in projection storage. This remote control was also targeted by a programmable block via its unique name, so 3 more of those were programmable block code stored in a projection. And the remaining 2 were the real block and the real code.

Usually I would expect there to be exactly 4 instances of the name with the projection having just one copy of the original each. Ideally maybe the projector preview also wouldn't store the programmable block code, but I guess that's just normal projection behavior for projection building.

I'm not sure whether this is a problem with the way projections work in the game or with the mod.
< >
Showing 1-6 of 6 comments
Digi  [developer] 4 Aug, 2019 @ 6:29am 
Hmm, I guess this is the inherit flaw of "use this ship" while it already projects something, it stacks on top and can go on forever.

I think the least intrusive fix for this is to force the projector to remove blueprint before adding the ship to it, all other projectors on the ship wouldn't be affected...
(Edit: actually I am already removing the vanilla stored projection but not this mods' stored projection, that's certainly something that I'll be fixing)

Still, someone could still abuse it by using 2 projectors and ping-pong stack stored projections? xD
Not sure how to deal with that part.
Last edited by Digi; 4 Aug, 2019 @ 6:37am
sharkle 4 Aug, 2019 @ 9:42am 
Maybe set an upper bound of how large a projection storage can be, before creating the projection based on how many blocks there are? But that's not foolproof by any means, since contents of blocks can be rather large (especially programmable blocks).
Digi  [developer] 4 Aug, 2019 @ 5:56pm 
I could limit on the final converted size in characters.

Hmm does the game itself have a limit?
Because one could do the same issue with 2 vanilla projectors, only difference is you have to blueprint the ship manually which means client has to store and stream the blueprint to the server, unlike here where it's done server side.
sharkle 5 Aug, 2019 @ 7:20am 
Actually, as you said this is a problem in vanilla projections as well but you only need one projector to do it. Make a new blueprint of the grid that has the projection, display that projection and it's not duplicated.
sharkle 6 Aug, 2019 @ 9:47am 
For completeness: It's fixed as far as I can tell! :steamhappy:

Reloading the blueprint for a medium sized station now also doesn't lag the server anymore at all.

Thank you very much!
< >
Showing 1-6 of 6 comments
Per page: 1530 50