# Gold Required for Level Formula

### From Braindead's Mordor Site

I've finally found the answer to just what you might need billions of gold for in Mordor: the Guildmaster is charging my Level 755 Thief almost 33 million gold to make each level by now.

I decided to take a look in the source to see what it'll cost me to get to Level 999, provided I'm still playing by then. The formula incorporates a loop, with rounding performed inside the loop, and at this time I'm not going to try to express the formula without using a loop.

I've written a little Javascript program which prints out the cost for each level: :typing:

LevelCost=0;

document.write("Gold Needed for Each Level<br><br>Guild Gold Factor = "+GGF+"<br><br>");

for (glvl=1; glvl<999; glvl=glvl+1) {

LevelCost=LevelCost+Math.round(((glvl * 2) -1) * 30.1);

document.write("Level "+(glvl + 1)+": "+Math.round(LevelCost * (1 +GGF/10))+" gold needed<br>");

};

To run it, open a blank browser window (type about:blank in the address bar), then copy the above lines into the address bar and hit enter. It might not work on your machine. It might even crash it -- I only tested it on Firefox.

GGF is GuildGoldFactor, the number displayed in Wabbit's Editor as "GoldPerLev?" (click on "Show Spell Data" on the Guilds form). Its value is 1 for Warrior, 2 for Paladin, 3 for Nomad, Seeker, Mage, and Sorcerer, 4 for Wizard and Healer, 5 for Ninja and Villain, 7 for Scavenger, and 9 for Thief.

The formula above uses a GGF of 9 by default; to get the leveling costs for any guilds other than Thief, change it before you run it.

For spreadsheet uses you may want to use a formula that is extremely close, in fact, correct minus the rounding. If you are level n and want to go to level n+1, the associated cost is: 30.1*n^2*(1+ggf/10)

Here is a Javascript program to find out the total gold needed to reach each level:

LevelCost=0;

TotalCost=0;

document.write("Total Gold Needed to Reach Level<br><br>Guild Gold Factor = "+GGF+"<br><br>");

for (glvl=1; glvl<999; glvl=glvl+1){

LevelCost=LevelCost+Math.round(((glvl * 2) - 1) * 30.1);

TotalCost=TotalCost+Math.round(LevelCost*(1+GGF/10));document.write("Level "+(glvl + 1)+": "+TotalCost+" total gold needed<br>");

};

The following formula might be slightly off, although banker's rounding should reduce the approximation. In any case, it's at most 999 gp off out of several billion gp. This is the total cost of leveling from level 1 to n+1: n* (n + 1)* (2n + 1)/6*30.1*(1+ggf/10)

Apparently I've already spent more than 8 billion gold leveling my Thief and will need to spend a total of nearly 19 billion gold before I can reach Level 999.

Discuss this topic in the forum

## See Also