Full Version : Rare spawner
xmlspawner >>Q&A >>Rare spawner


<< Prev | Next >>

Abracadabra- 07-06-2006
What I'd like to do is set a spawner down that will spawn at random one of ten rares that I designate. The items would not need to decay at set intervals, but rather once the player picks up that item the spawner is reset to spawn again, this time with another random rare. I'll choose the rares myself, so for demonstration purposes let's say its item1, item2, and item3. I'm nearly certain this can be done with xml spawner but the method escapes me.

ArteGordon- 07-06-2006
QUOTE (Abracadabra @ July 06, 2006 09:08 pm)
What I'd like to do is set a spawner down that will spawn at random one of ten rares that I designate. The items would not need to decay at set intervals, but rather once the player picks up that item the spawner is reset to spawn again, this time with another random rare. I'll choose the rares myself, so for demonstration purposes let's say its item1, item2, and item3. I'm nearly certain this can be done with xml spawner but the method escapes me.

yeah, that's easy.

Just add each entry to the spawner

item1
item2
item3

and then set the maxcount of the spawner to 1.

Since the spawner maxcount is 1, only one item can be spawned at any given time, and that one item will be randomly selected from the list.

If you want to change the probabilities of the different items being selected, just increase their individual maxcounts. So if you made the item1 maxcount 10, then it would have a 10 out of 12 chance of being selected. The other items would each have a 1 out of 12 chance (12 = 10 + 1 + 1)

Abracadabra- 07-06-2006
Wow that's awesome! I was imaging it would be much more complicated. Over time Arte you will see that the easy stuff escapes me the most lol Thanks again pal

ArteGordon- 07-07-2006
here is a HowTo post on the topic
http://xmlspawner.15.forumer.com/index.php?showtopic=79