/require lisp.tf /def lvlcost = \ /if (%1=~"") /echo -p @{BCred}ERROR.@{n} Give wanted level as a parameter, e.g. "/lvlcost 100".%;\ /else \ /if (%1>120) /let wanted_lvl 120%;/else /let wanted_lvl %1%;/endif%;\ /let current_lvl 0%;\ /let total_lvlcost 0%;\ /let total_qps 0%;\ /while (current_lvl < wanted_lvl) \ /let current_lvl $[++current_lvl]%;\ /let this_lvl $(/nth %current_lvl %lvlcosts)%;\ /let this_lvl_qps $(/nth %current_lvl %lvlqps)%;\ /let this_lvl_normal $[this_lvl*0.75]%;\ /let this_lvl_glevel $[this_lvl*0.4]%;\ /let total_lvlcost $[total_lvlcost+this_lvl_normal+this_lvl_glevel]%;\ /let total_qps $[total_qps+this_lvl_qps]%;\ /done%;\ /let total_lvlcost $[trunc(total_lvlcost)]%;\ /if (strlen(total_lvlcost)<4) \ /echo Level %wanted_lvl costs: $[total_lvlcost]k%;\ /elseif (strlen(total_lvlcost)=4) \ /echo Level %wanted_lvl costs: $[substr(total_lvlcost,-4,1)]M $[substr(total_lvlcost,-3,3)]k%;\ /elseif (strlen(total_lvlcost)=5) \ /echo Level %wanted_lvl costs: $[substr(total_lvlcost,-5,2)]M $[substr(total_lvlcost,-3,3)]k%;\ /elseif (strlen(total_lvlcost)=6) \ /echo Level %wanted_lvl costs: $[substr(total_lvlcost,-6,3)]M $[substr(total_lvlcost,-3,3)]k%;\ /elseif (strlen(total_lvlcost)=7) \ /echo Level %wanted_lvl costs: $[substr(total_lvlcost,-7,1)]G $[substr(total_lvlcost,-6,3)]M $[substr(total_lvlcost,-3,3)]k%;\ /elseif (strlen(total_lvlcost)=8) \ /echo Level %wanted_lvl costs: $[substr(total_lvlcost,-8,2)]G $[substr(total_lvlcost,-6,3)]M $[substr(total_lvlcost,-3,3)]k%;\ /endif%;\ /echo QP required: %total_qps%;\ /if (reinctax_worth!="" & reinc_tax!="") \ /echo Your worth: $[trunc(%{reinctax_worth}/1000)]M, Your reinctax: %{reinc_tax}, After taxes: $[trunc(trunc(reinctax_worth/1000)*(100-reinc_tax)/100)]%;\ /echo You would have $[trunc(((reinctax_worth*(100-reinc_tax)/100)-total_lvlcost)/1000)]M after levels.%;\ /endif%;\ /endif /set lvlcosts 1 2 2 4 5 8 11 16 23 31 42 57 75 97 130 160 200 250 310 380 460 550 660 780 920 1080 1260 1470 1700 1950 2230 2550 2900 3280 3700 4160 4660 5210 5810 6460 7170 7930 8750 9640 10600 11600 12700 13900 15100 16500 17900 19400 21100 22800 24600 26600 28600 30800 33100 35500 38100 40800 43600 46600 49700 53000 56500 60100 63900 67900 72100 76500 81100 85800 90800 96000 101500 107200 113100 119200 125600 132300 139200 146400 153900 161600 169700 178000 186700 195700 205000 214700 224700 235000 245700 406700 424900 443600 463000 483000 503600 524900 546900 569600 593000 617100 652000 667600 694000 721200 749100 777900 807600 838000 869400 901600 934700 968800 1004000 1040000 /set lvlqps 0 1 1 1 1 2 2 3 3 4 4 5 5 6 7 7 8 9 9 10 11 12 12 13 14 15 16 17 17 18 19 20 21 22 23 24 25 26 28 29 30 31 32 33 35 36 37 38 40 41 42 44 45 46 48 49 51 52 54 55 57 58 60 62 63 65 67 68 70 72 73 75 77 79 81 82 84 86 88 90 92 94 96 98 100 102 104 106 108 110 112 115 117 119 121 123 126 128 130 133 135 137 140 142 144 147 149 152 154 157 159 162 164 168 170 172 174 178 180 183