I wouldn't create an array, just create a an equation.

This is similiar to what I did:

#define BASE_EXP 88 /* how much experience increases per level */
#define KILL_PER_LEVEL 12  /* average kills per level needed */

And then in xp_compute I do:

      min = (victim->level);
      min = min * BASE_EXP;
      min = min/KILL_PER_LEVEL;
      min = min *3/4;
      max = (((victim->level) * BASE_EXP)/KILL_PER_LEVEL)*4/3.2;

As far as gaining levels, change exp_per_level() to:
int exp_per_level(CHAR_DATA *ch)
{
     return ((ch->level)*BASE_EXP);
}

Then the experience for each level goes up steadily.

You will want to tweak the BASE_EXP abd KILL_PER_LEVEL based on your mud.
Also, 12 is not set in stone, it could be 10, it could be 15.

Hope this helps.



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 20, 2002 8:22 AM
To: [email protected]
Subject: New Exp System


I want to remove the current system of XP gaining from 
my ROM. I want it so it does this instead: Goes through 
an array, and determines how much xp you need to level 
that way. For an example, here is the XP array. You are 
level 1, and need to get to level two. Well, you need 20 
exp to do so. So, when you get twenty XP, you are raised 
to level 2, and than need 40 XP to make it to level 3. 
Can someone tell me how I could implement this?

{1, 20, 40, 80, 100}

-- 
ROM mailing list
[email protected]
http://www.rom.org/cgi-bin/mailman/listinfo/rom

Reply via email to