-- helper function to come up with appropriate XP rewards for quests
-- level -> level range to use from table
-- percent -> percent of exp at the level to give (default = 3)
-- range -> range of randomness (default = 1)
-- example: ExpHelper(51, 5, 1) will return a random exp value between 4% and 6% (5% average, range of 1%) of experience required to level from 51 to 52
-- defaults
percent=percentor3;
range=rangeor1;
-- hardcoded exp by level table, note this is exp to go from level n to level n+1, not total exp at level
localexp={
[1]=1000,
[2]=7000,
[3]=19000,
[4]=37000,
[5]=61000,
[6]=91000,
[7]=127000,
[8]=169000,
[9]=217000,
[10]=271000,
[11]=331000,
[12]=397000,
[13]=469000,
[14]=547000,
[15]=631000,
[16]=721000,
[17]=817000,
[18]=919000,
[19]=1027000,
[20]=1141000,
[21]=1261000,
[22]=1387000,
[23]=1519000,
[24]=1657000,
[25]=1801000,
[26]=1951000,
[27]=2107000,
[28]=2269000,
[29]=2437000,
[30]=5311000,
[31]=3070100,
[32]=3274700,
[33]=3485900,
[34]=3703700,
[35]=8215600,
[36]=4537200,
[37]=4796400,
[38]=5062800,
[39]=5336400,
[40]=12017200,
[41]=6397296,
[42]=6717104,
[43]=7044704,
[44]=7380096,
[45]=16835800,
[46]=8695400,
[47]=9081792,
[48]=9476608,
[49]=9879808,
[50]=10291392,
[51]=23976496,-- this is the amount of exp for an AA!
[52]=25996304,
[53]=28118096,
[54]=46090704,
[55]=50205888,
[56]=54529312,
[57]=59065696,
[58]=63819904,
[59]=89334624,
[60]=53462976,
[61]=34041088,
[62]=35175680,
[63]=36328960,
[64]=37500672,
[65]=38691072,
[66]=39900160,
[67]=41127680,
[68]=42373888,
[69]=43638720,
[70]=44922048,
[71]=46224128,
[72]=47544704,
[73]=48883840,
[74]=50241792,
[75]=51618048,
[76]=53013120,
[77]=54426752,
[78]=55858816,
[79]=57309696,
[80]=58779136,
[81]=60267136,
[82]=61773696,
[83]=63298816,
[84]=64842752,
[85]=66405120,
[86]=67986048,
[87]=69585792,
[88]=71203840,
[89]=72840704,
[90]=74496000,
[91]=76170240,
[92]=77862656,
[93]=79574016,
[94]=81303552,
[95]=83052032,
[96]=84819200,
[97]=86604800,
[98]=88408832,
[99]=90231552,
[100]=92073216
}
-- return random between upper bound and lower bound