aboutsummaryrefslogtreecommitdiff
path: root/interest.lua
diff options
context:
space:
mode:
authorGabriel Pérez-Cerezo <gabriel@gpcf.eu>2017-06-03 11:51:29 +0200
committerGabriel Pérez-Cerezo <gabriel@gpcf.eu>2017-06-03 11:51:29 +0200
commit121afdcd3f48b81599ef06e82c3f3d2288c8552c (patch)
treeee297d595ae7a2e147799b789641236bf3c5d8f9 /interest.lua
parentb7580bcea4c7eb94c48f88b9ba744d5b2473dd1c (diff)
downloadatm-121afdcd3f48b81599ef06e82c3f3d2288c8552c.tar.gz
atm-121afdcd3f48b81599ef06e82c3f3d2288c8552c.tar.bz2
atm-121afdcd3f48b81599ef06e82c3f3d2288c8552c.zip
Replace interest with basic income, add starting amount of 30 minegeld.
Diffstat (limited to 'interest.lua')
-rw-r--r--interest.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/interest.lua b/interest.lua
index b8f8d0c..d1d7980 100644
--- a/interest.lua
+++ b/interest.lua
@@ -2,13 +2,13 @@
local timer = 0
minetest.register_globalstep(function(dtime)
timer = timer + dtime;
- if timer >= 3000 then
+ if timer >= 1000 then
timer = 0
atm.readaccounts()
for _,player in ipairs(minetest.get_connected_players()) do
local name = player:get_player_name()
if not (atm.balance[name] == nil) then
- atm.balance[name] = math.floor(atm.balance[name] * 1.05)
+ atm.balance[name] = math.floor(atm.balance[name] + 5)
end
end
atm.saveaccounts()