The -seed command and objects
#1
I recall a discussion here (or possibly some other place) about how and what the game really do different and random when one use the -seed command and when one play single player. I have searched a lot but can't find the thread, does anyone recall it?

In any case, looking a bit at how the game handle objects (that is chests and such), it looks like the game actually uses one global seed stream for all objects in a game. That is, the seed set to each individual object is not used. The object seed would be used for all random results such as item type and quality (but NOT item properties). It is used also in many cases in seting up objects.

So in regard to using the seed command and to restart single player games, if one spawn the map in the same order, and operate objects in the same order (with the possible exception of objects that doesn't operate random results), one should get identical drop results as far as item type and quality goes I would say. This agrees with the experience of previously posted info. This is also why there is a difference between objects and monsters.

FOr the technical minded, this seed is stored in a structure pointed to at ptGame+10f0 The first two dwords in that structure is the seed. The structure also holds infro from the txt files for all objects in the game if my notes are correct. See phrozen keep for more info similar to this in the unit/game structure thread.

Hope this is of some use.
There are three types of people in the world. Those who can count and those who can't.
Reply
#2
i think the thread your looking for is called" does magic find diminish over time " or something to that effect.
Reply
#3
Heiho,

I recall a similar discussion over at d2de, where your hypothese was confirmed some while ago. Lots of 'double' monsters, which all drop the same item (a cracked sword or whatever) or at least the same item class.
It was also reported, that the monsters give far less exp than without -seed, and that the actual number you can attach as parameter has no influence at all

<edit>
seed seemed to modify the MonDen value in levels.txt, it doesn't work eg in the Bloody Foothills, where MonDen was fixed at 0.
This is all 1.09 info
</edit>
so long ...
librarian

Check out some peanuts or the
Diablo II FAQtoids
current status: re-thinking about HoB
Reply
#4
I think you're talking about the very involved discussion we had on the diabloii.net single player forum after someone found a Tyrael's Might after using -seed.
It was a while back though and it is a very busy forum.

I am a little surprised by the idea that the object seed is used for both type and quality - no reason to doubt of course but then can you explain the rack-running process? When you hit the same rack over and over in single play, it will drop the same item type (always in most cases, but with some variety in others). However, the quality of the item varies around seemingly randomly.

My explanation (with no basis from code digging, just educated guessing) is that the rack is created when the map is created, and since the map seed is retained in SP the rack is given the same object seed every time, and this means it drops the same item every time. That it varies can possibly be explained by the fact that it might not be created until it is "spawned", like a monster - eg a rack right next to a WP will always drop the same, but if you have to run to it, the path you take is crucial, and if you approach from a different direction it changes the item type. However since the quality varies randomly (no matter how careful you are), I assumed that was being determined from the global random stream, not the rack's object seed. Otherwise repitition would be more serious than it seems.

Of course racks and monsters may work more differently than I have been assuming. I realise the quality of a rack drop is worked out through an entirely different bit of code.
"Thank you. We always have a shortage of unfounded opinions, so this will really help us. " - adeyke
Reply
#5
Thrugg,Mar 11 2004, 07:28 PM Wrote:I think you're talking about the very involved discussion we had on the diabloii.net single player forum after someone found a Tyrael's Might after using -seed.
It was a while back though and it is a very busy forum.

I am a little surprised by the idea that the object seed is used for both type and quality - no reason to doubt of course but then can you explain the rack-running process?&nbsp; When you hit the same rack over and over in single play, it will drop the same item type (always in most cases, but with some variety in others).&nbsp; However, the quality of the item varies around seemingly randomly.

My explanation (with no basis from code digging, just educated guessing) is that the rack is created when the map is created, and since the map seed is retained in SP the rack is given the same object seed every time, and this means it drops the same item every time.&nbsp; That it varies can possibly be explained by the fact that it might not be created until it is "spawned", like a monster - eg a rack right next to a WP will always drop the same, but if you have to run to it, the path you take is crucial, and if you approach from a different direction it changes the item type.&nbsp; However since the quality varies randomly (no matter how careful you are), I assumed that was being determined from the global random stream, not the rack's object seed.&nbsp; Otherwise repitition would be more serious than it seems.

Of course racks and monsters may work more differently than I have been assuming.&nbsp; I realise the quality of a rack drop is worked out through an entirely different bit of code.
Hmmm, let me think again :)

Anyway, picking base item from a TC and picking quality is all in same routine so coupled. The seed used there is....hmm.....have to check again :) Racks does NOT however pick base item and quality through that function and thus works differently. Have not checked it out lately though. I would suspect the common object seed is used in part since it is a pramatere to all object functions.
There are three types of people in the world. Those who can count and those who can't.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)