mirror of
https://github.com/sys4-fr/server-nalc.git
synced 2025-01-26 09:40:28 +01:00
[_misc & fishing & whoison] Updates and fixes
- _misc : Fix noshout (seeaebd448148
) - fishing : update submodule's commit's reference - whoison : fix timeonline (seeeab339a3d3
)
This commit is contained in:
parent
7a1f3beb0a
commit
30c8e8ebee
@ -16,7 +16,7 @@ end
|
|||||||
|
|
||||||
minetest.register_on_joinplayer(function(player)
|
minetest.register_on_joinplayer(function(player)
|
||||||
local name = player:get_player_name()
|
local name = player:get_player_name()
|
||||||
if not minetest.check_player_privs(name, {interact=true}) and players[name] == nil then
|
if minetest.check_player_privs(name, {shout=false}) and players[name] == nil then
|
||||||
minetest.after(5, tick, name)
|
minetest.after(5, tick, name)
|
||||||
players[name] = true
|
players[name] = true
|
||||||
end
|
end
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit 14bdc521f2d5d5a7dadb8ffda01e961a2aa51f0b
|
Subproject commit d8777494b31187e8717dc2fa07f40834d3b7084f
|
@ -100,6 +100,9 @@ minetest.register_chatcommand("timeonline",{
|
|||||||
description = "Shows the cumulative time a player has been online",
|
description = "Shows the cumulative time a player has been online",
|
||||||
func = function (name, param)
|
func = function (name, param)
|
||||||
if ( param ~= nil ) then
|
if ( param ~= nil ) then
|
||||||
|
if param == "" then
|
||||||
|
param = name
|
||||||
|
end
|
||||||
local t = whoison.getTimeOnline(param)
|
local t = whoison.getTimeOnline(param)
|
||||||
if ( t ~= nil ) then
|
if ( t ~= nil ) then
|
||||||
minetest.chat_send_player(name,param.." has been online for "..breakdowntime(t))
|
minetest.chat_send_player(name,param.." has been online for "..breakdowntime(t))
|
||||||
@ -107,7 +110,7 @@ minetest.register_chatcommand("timeonline",{
|
|||||||
minetest.chat_send_player(name,"Sorry, I have no record of "..param)
|
minetest.chat_send_player(name,"Sorry, I have no record of "..param)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
minetest.chat_send_player(name,"Usage is /timeonline <name>")
|
minetest.chat_send_player(name,"Usage is /timeonline [<name>]")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user