diff --git a/tdps.lic b/tdps.lic index ca1e274595..d30f6b3e8f 100644 --- a/tdps.lic +++ b/tdps.lic @@ -20,9 +20,7 @@ def cost(current, modifier) cost = 0 start = 10 - 2 * modifier for i in start..current - 1 do - mult = i < 100 ? 3 : 15 - mod = (modifier.to_f * i / 2).truncate - cost += (i * mult) + mod + cost += i * (i < 100 ? 3 : 15) + modifier * (i / 2).floor(0) end return cost end @@ -52,7 +50,7 @@ else end # Calcuate total TDPs spent for each stat -costs = [] +costs = Array.new(8) for i in 0..7 costs[i] = cost(stats[i], mods[i]) end