mirror of
https://github.com/stijndcl/didier.git
synced 2026-04-07 15:48:29 +02:00
Bank upgrades
This commit is contained in:
parent
ba86d4a6f2
commit
fff35c6c44
8 changed files with 99 additions and 3 deletions
0
database/utils/math/__init__.py
Normal file
0
database/utils/math/__init__.py
Normal file
25
database/utils/math/currency.py
Normal file
25
database/utils/math/currency.py
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
import math
|
||||
|
||||
|
||||
def interest_upgrade_price(level: int) -> int:
|
||||
"""Calculate the price to upgrade your interest level"""
|
||||
base_cost = 600
|
||||
growth_rate = 1.8
|
||||
|
||||
return math.floor(base_cost * (growth_rate**level))
|
||||
|
||||
|
||||
def capacity_upgrade_price(level: int) -> int:
|
||||
"""Calculate the price to upgrade your capacity level"""
|
||||
base_cost = 800
|
||||
growth_rate = 1.6
|
||||
|
||||
return math.floor(base_cost * (growth_rate**level))
|
||||
|
||||
|
||||
def rob_upgrade_price(level: int) -> int:
|
||||
"""Calculate the price to upgrade your rob level"""
|
||||
base_cost = 950
|
||||
growth_rate = 1.9
|
||||
|
||||
return math.floor(base_cost * (growth_rate**level))
|
||||
Loading…
Add table
Add a link
Reference in a new issue