mirror of
https://gitlab.com/lunovox/minertrade.git
synced 2025-03-15 05:31:20 +00:00
Declarando depósito no terminal. (espero que não demasiado verboso)
This commit is contained in:
parent
247dc5cb62
commit
77debf1915
1 changed files with 2 additions and 1 deletions
|
@ -53,12 +53,12 @@ minetest.after(3.5, function()
|
|||
if #players >= 1 then
|
||||
if modMinerTrade.bank.last_pay ~= minetest.get_day_count() then
|
||||
modMinerTrade.bank.last_pay = minetest.get_day_count()
|
||||
local description = modMinerTrade.translate("The city hall deposited the %2d° salary in your bank account!"):format(minetest.get_day_count())
|
||||
for _, player in ipairs(players) do
|
||||
local playername = player:get_player_name()
|
||||
if minetest.get_player_privs(playername).salary then
|
||||
if modMinerTrade.isExistAcount(playername) then
|
||||
local value = modMinerTrade.salary.getValue()
|
||||
local description = modMinerTrade.translate("The city hall deposited the %2d° salary in your bank account!"):format(minetest.get_day_count())
|
||||
modMinerTrade.addBalance(playername, value)
|
||||
modMinerTrade.addStatement(playername, value, description)
|
||||
minetest.chat_send_player(
|
||||
|
@ -73,6 +73,7 @@ minetest.after(3.5, function()
|
|||
end
|
||||
end
|
||||
end -- Final off for _, player in ipairs(players) do
|
||||
minetest.log('action',"[MINERTRADE] "..description)
|
||||
modMinerTrade.doBankSave()
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue