Change us_time calls to gametime.
This commit is contained in:
parent
2b8b604162
commit
11c4a7d7d0
3 changed files with 6 additions and 6 deletions
4
chat.lua
4
chat.lua
|
@ -10,9 +10,9 @@ minetest.register_chatcommand("armor", {
|
|||
for group, value in pairs(armor) do
|
||||
minetest.chat_send_player(name, " "..group.." "..value)
|
||||
end
|
||||
--print(math.floor(minetest.get_us_time() / (60 * 1000000)))
|
||||
print(math.floor(minetest.get_gametime() / 60))
|
||||
if fun_caves.armor_expire and fun_caves.armor_expire[name] then
|
||||
local min = math.floor((fun_caves.armor_expire[name] - minetest.get_us_time()) / (60 * 1000000))
|
||||
local min = math.floor((fun_caves.armor_expire[name] - minetest.get_gametime()) / 60)
|
||||
minetest.chat_send_player(name, "Your elixir will expire in "..min..' minutes.')
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue