diff options
author | peter1138 <peter1138@openttd.org> | 2006-11-24 18:39:22 +0000 |
---|---|---|
committer | peter1138 <peter1138@openttd.org> | 2006-11-24 18:39:22 +0000 |
commit | c079c83eb65e8365680523f6fba676f9c41ec10a (patch) | |
tree | 55d15b28e028ea338db8ec11d3266151027da760 /genworld.c | |
parent | 8d175ccb136581de4fb77931b029841144fe3f52 (diff) | |
download | openttd-c079c83eb65e8365680523f6fba676f9c41ec10a.tar.xz |
(svn r7250) -Codechange: Shuffle sprite loading and character width caching around a bit. This reduces the number of times the sprites are loaded from 5 to 2, just for the intro game.
Diffstat (limited to 'genworld.c')
-rw-r--r-- | genworld.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/genworld.c b/genworld.c index 2e1f003d5..9872270b0 100644 --- a/genworld.c +++ b/genworld.c @@ -252,18 +252,19 @@ void GenerateWorld(int mode, uint size_x, uint size_y) /* Make sure everything is done via OWNER_NONE */ _current_player = OWNER_NONE; + /* Load the right landscape stuff */ + GfxLoadSprites(); + LoadStringWidthTable(); + InitializeGame(IG_DATE_RESET, _gw.size_x, _gw.size_y); PrepareGenerateWorldProgress(); /* Re-init the windowing system */ ResetWindowSystem(); - LoadStringWidthTable(); /* Create toolbars */ SetupColorsAndInitialWindow(); - /* Load the right landscape stuff */ - GfxLoadSprites(); if (_network_dedicated || (_gw.thread = OTTDCreateThread(&_GenerateWorld, NULL)) == NULL) { DEBUG(misc, 1) ("[Sl] Cannot create savegame thread, reverting to single-threaded mode..."); |