[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-28 Thread Marko Lindqvist
Follow-up Comment #8, bug #20567 (project freeciv): if the mapseed triggered a retry. Note that there's retry only if random mapseed is requested in the first place. No point in retrying with same set seed. If user explicitly set mapseed, (s)he probably did it for a reason and providing map

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-28 Thread Marko Lindqvist
Follow-up Comment #9, bug #20567 (project freeciv): wanted players to study in advance I was that close to commit my patch when it sink in that this use-case might be the reason startposition assignment has not been using mapseed. While you may want terrain to be known to everyone, at the same

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-24 Thread Marko Lindqvist
Follow-up Comment #5, bug #20567 (project freeciv): My patch has reproducibility problem in my own regression testing use-case. I use random seeds to get different games, but log those seeds carefully for using in reproduction of the problems encountered. But with my patch main random state goes

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-24 Thread Marko Lindqvist
Update of bug #20567 (project freeciv): Category:None = general ___ Follow-up Comment #6: - Game random state proceeds the same way for same map seed regradless if it the map seed was

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-24 Thread Jacob Nevins
Follow-up Comment #7, bug #20567 (project freeciv): But why do you think games where first map generation success with random seed are reproducible? I think I must have been thinking of games with explicitly set mapseed, although I didn't make that clear. For some reason in my autogame script

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-04 Thread Jacob Nevins
Follow-up Comment #3, bug #20567 (project freeciv): Hm. Not directly relevant to the patch (which seems like a fine idea), but the random Lua-generated labels, it would be kind of nice if they were generated from mapseed rather than gameseed, so that if I pick a mapseed I like, I get fixed labels

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-03-04 Thread Jacob Nevins
Follow-up Comment #4, bug #20567 (project freeciv): The map generation random seed would be the same on the second attempt as on first if main gameseed would have been succesfully restored after first attempt. time(NULL) is munged into map.server.seed when it's zero in

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-02-27 Thread Marko Lindqvist
Follow-up Comment #2, bug #20567 (project freeciv): Turned out that start position assignment does not use mapseed, but main gameseed, so the main random state has been changing in mapgenerator. This does not explain lua script randomness problems, but attached patch anyway changes this so that

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-02-26 Thread Marko Lindqvist
URL: http://gna.org/bugs/?20567 Summary: Lua random() not really random Project: Freeciv Submitted by: cazfi Submitted on: Wed 27 Feb 2013 09:30:30 AM EET Category: None Severity: 3 - Normal

[Freeciv-Dev] [bug #20567] Lua random() not really random

2013-02-26 Thread Marko Lindqvist
Follow-up Comment #1, bug #20567 (project freeciv): There must be some problem in how main gameseed is restored after map has been generated (note that it's already restored by the time map_generated lua signal). Actually, if restoring of gameseed worked like it seems to be designed, our new 2.4