HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Random number woes

12-28-2004, 04:14 AM#1
Doomsberg
Ok in this map ive been working on, when u enter a certain region it creates a random group of enemies based on a random number variable.
e.g.
- unit enters start <gen>

- set monster set to random number between 1 and 10
- ifmonster set equal to 1 then create 1 footman at start <gen> else do nothing
- ifmonster set equal to 2 then create 1 grunt at start <gen> else do nothing

well anyway thats an example, but for some reason the same number is always randomly generated. So like every time this trigger is run monster set always turns out to be 9. How can i make it so it wont always be the same number? and has any1 else had this problem aswell, or am i the first?

thnx.
12-28-2004, 05:04 AM#2
Ant
I'll respond with a quote from Panto who posted this in Handy WE tips.

Quote:
While using the File>Test Map feature, the map will use the same random "seed" every time that you play it, which means it won't really be random at all. You can set it to use a truly random "seed" by going to File>Preferences>Test Map and unchecking "Use Fixed Random Seed".
12-28-2004, 08:05 AM#3
Doomsberg
Quote:
Originally Posted by Ant
I'll respond with a quote from Panto who posted this in Handy WE tips.

Yeah i already knew that. But this extends even to the fact that other players that play my map are faced with the same problem. So its not happening from going test map its when u go via warcraft 3 it comes up with it.