summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorglx <glx@openttd.org>2008-09-27 22:19:34 +0000
committerglx <glx@openttd.org>2008-09-27 22:19:34 +0000
commitf2d7c48b319f01bc91a51669630e0e024724b4f9 (patch)
tree8129d168a9841653eabbfa3f489600473eee1fa8 /src
parent76c13beef0099a8e9677ddd10cb1a96aab1fb1ae (diff)
downloadopenttd-f2d7c48b319f01bc91a51669630e0e024724b4f9.tar.xz
(svn r14408) -Fix (r9205): generation seed set using -G was always overwritten by -g
Diffstat (limited to 'src')
-rw-r--r--src/openttd.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/openttd.cpp b/src/openttd.cpp
index ab6c44553..edb65df79 100644
--- a/src/openttd.cpp
+++ b/src/openttd.cpp
@@ -481,8 +481,10 @@ int ttd_main(int argc, char *argv[])
}
_switch_mode = SM_NEWGAME;
- /* Give a random map */
- generation_seed = InteractiveRandom();
+ /* Give a random map if no seed has been given */
+ if (generation_seed == GENERATE_NEW_SEED) {
+ generation_seed = InteractiveRandom();
+ }
break;
case 'G': generation_seed = atoi(mgo.opt); break;
case 'c': _config_file = strdup(mgo.opt); break;