Re: killing same mobs EXP gain limitation

From: Ray (ruppertr@SNYCORVA.CORTLAND.EDU)
Date: 08/25/97


On Mon, 25 Aug 1997, Andrey Fidrya wrote:

> When player kills mob first time, he gets full XP.
> When he kill same mob more and more, he gets less and less XP.
> If he killed same mob for over 100 times, he gets no XP at all.
> If he stops killing same mob for a while and killed 20-40 other mobs,
> he can kill first mob for full XP again.
> Anyone have any ideas about implementing that system?
> If you just keep an array with mobs and number_of_kills per each mob,
> playerbase will become ~10 kb larger per each player. :(

If you only keep an array (or linked list) of 20 or 40 (or whatever)
entries of vnum and # killed with each player, that won't be too bad.
Sort it by most recent mob killed (ie when a mob is killed, make the
first entry in the array be that mob.)  And if the list is already full,
drop the oldest entry.  It sounds like a linked list'd probably be the
way to go with this.  Vnum is an int (4 bytes, generally) and kills can
be a byte (1 byte [duh!]) if you make it so it doesn't track kills above
100, so you're adding 5 bytes * 20 or 40 or whatever per player, which is
200 bytes worst case.  That isn't too bad, actually.

Sounds interesting,
                Ray


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST