From: Nic Suzor <glok.lists@cryogen.com>
Subject: How-To Titles..

heres my code to replace the titles[] stuff... put it at the end of
utils.c, and then grep -in titles *.[ch] and replace all the titles exp
stuff with exp_to_level(ch).
this makes it easier to add new levels, and gets rid of those ugly tables
at the end of class.c. oh, and if you want to add a class modifier (i didnt
want it),  just create another int cmodifier, and change that. oh, and you
have to lose all the set_title stuff too, because that wont exist any more.

'luck :)

Nic Suzor

int exp_to_level(struct char_data *ch)
{
  int modifier, exp;

  if (GET_LEVEL(ch) < 10)
    modifier = 1;
  else if (GET_LEVEL(ch) < 20)
    modifier = 2;
  else if (GET_LEVEL(ch) < 30)
    modifier = 5;
  else if (GET_LEVEL(ch) < 40)
    modifier = 10;  
  else if (GET_LEVEL(ch) < 50)
    modifier = 20;
  else if (GET_LEVEL(ch) < 60)
    modifier = 30;
  else if (GET_LEVEL(ch) < 70)
    modifier = 50;
  else if (GET_LEVEL(ch) < 80)
    modifier = 70;  
  else if (GET_LEVEL(ch) < 90)
    modifier = 100;
  else
    modifier = 250;
    
  exp = GET_LEVEL(ch) * modifier * 4000;
    
  return exp;
}

---
From: "David A. Carver" <dcarver@iwaynet.net>
Subject: Exp to Level Algorithm

> Along the lines of fair but useful experience caps, does anyone have
> any ideas on an equation to calculate exp to level that is equally
> increased?  Not like 1k per level, but more so half of last level
> plus current total exp divided by level?  Or, can someone explain
> why the current exp table is set up the way it is, incrementing by
> the same amount, then doubling, then incrementing by that same
> amount.  This creates different plateau's of exp to gain in order to

I have no idea why the experience system is set up the way it is, 
probably just the way it was done.  I just recently went through and 
modified my code to include 104 levels.  While doing this I went 
through and took out the experience table and replaced it with the 
following basic formula:

(The formula calculates the experience needed to go from (level of 
player) to (level of player + 1)

level of player * 2000 * level modifier * class modifier.

The level modifier is as follows:
Levels          Modifier
1 - 10                1
11 - 20              4
21 - 30              8
31 - 55              9
56 - 60              8.5
60 - 65              8.4
66 - 70              8.3
71 - 75              8.2
76 - 80              8.1
81 ->                8

Class Modifier is a number based on a characters Class.  The theory 
is that it should take a Wizard or Cleric less experience to get to 
the same level than it would take a Warrior or Ranger.  I started 
Wizards at 1.1 and Rangers at 1.8.  This is a constant.

I had to play around with the Level Modifier until I got something 
that looks like it will work reasonably well.

Hope this helps.

Dave Carver
