[MUD-Dev] The grass is always greener in the other field

Adam Wiggins adam at angel.com
Fri Dec 17 15:55:47 New Zealand Daylight Time 1999


On Fri, 17 Dec 1999, Sellers, Michael wrote:
> Adam wrote:
> > The system which I have proposed here before, and in fact which I use
> > myself, is seeded randoms.  The chance to pick a lock, hide in a certain
> > room, or do other actions which need a hint of randomness but which the
> > player should not be able to "spam" until they succeed, is based upon a
> > seed for that location.
> > 
> > So a given lock-picker will either not be able to pick a given player
> house's
> > lock at all, no matter how many times they try, with their current skill
> > level; and then once they can, they can do it every time, prompting the
> > player who owns the house to buy a new lock if they find that someone
> > who can gain access to their house does so on a regular basis.
> 
> Adam, I believe I've seen this before expressed as:
> 
> seed = location seed + (obj ID | activity ID) + your skill level
> randNum = rand(seed)
> if (your skill > randNum) success = TRUE;
> 
> So you use the location, activity or object involved, and your skill to
> build seed for the random number.  As long as one of these doesn't change,
> your success or failure won't change either.  This also allows for critical
> success/failures if you want that sort of thing.
> 
> Is that essentially what you were talking about?

Yes.  I'm not going to write out my formula here as it's pretty complex
and has a lot of variables in it that aren't relevant to this discussion,
but the general format looks more like this:

seed = lock ID | (char ID << ID_BIT_WIDTH)

difficulty = lock complexity + character size
difficulty -= character perception + character agility + lockpick bonus

requiredSkill = seeded_random(seed, difficulty / 2, difficulty)

if (your skill > requiredSkill) success = TRUE;


The effect of doing it this way is that for every unique situation (a
given character and a given lock to pick) there is a "threshold" of
skill required.  Once your skill hits that number, you can do it every
time.  In essence, your character has "figured out" that particular lock,
and from then on picking it is just a matter of recalling the past
experience and doing it the same way.

Note also that this threshold will be fairly similar across characters
for a lock of a given difficulty.  Player A may find themselves able to
pick it at a skill of 65, while player B will have to wait until 73, and
player C can do it as early as 58.

Adam





_______________________________________________
MUD-Dev maillist  -  MUD-Dev at kanga.nu
http://www.kanga.nu/lists/listinfo/mud-dev



More information about the MUD-Dev mailing list