Preloading

Preloading

Discuss development of lobby clients, server, autohosts and auto-download software.

Moderators: Moderators, Lobby Developers

Post Reply
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Preloading

Post by AF »

Is there a way to launch the engine and preload a game, then pass it a start script later on for the final load/initialisation?
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Preloading

Post by Silentwings »

Load up the game sdz (or some proxy pre-game menu sdz) with a predefined "default" script.txt, then manufacture the script.txt you actually want and use Spring.Reload(...).

It's not exactly what you asked for, but hopefully close enough.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Preloading

Post by gajop »

Doing as Silentwings suggested should help update the engine cache (otherwise the caching process can be incredibly slow for the first run), and might also do some OS-level disk caching for the game, but afaik, Spring will still have to load the game for the second time once you pass the new startscript params.
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Preloading

Post by Silentwings »

Although, if you're using a separate sdz for your ingame menu part, that will be small in size and loading it will be very fast.
Post Reply

Return to “Lobby Clients & Server”