Skip to content

Commit

Permalink
Merge pull request #6710 from BinuDR/patch-3
Browse files Browse the repository at this point in the history
  • Loading branch information
MahtraDR authored Oct 5, 2023
2 parents c37ef0d + d2ef9a1 commit 441ece9
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions tdps.lic
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit 441ece9

Please sign in to comment.