Fixed AFK kick message

it doesnt need to print (max_afk_time*3600) just the time (max_afk_time)
This commit is contained in:
badgamernl
2018-03-20 16:37:08 +01:00
committed by GitHub
parent a6360c577a
commit 34ec1dc5fe

View File

@@ -16,7 +16,7 @@ Event.register(-1,function(event)
for _,player in pairs(game.connected_players) do
local afk = Ranking.get_rank(player).max_afk_time or false
if afk then
if player.afk_time > afk*3600 then game.kick_player(player,'AFK For Too Long ('..tostring(afk*3600)..' Minutes)') end
if player.afk_time > afk*3600 then game.kick_player(player,'AFK For Too Long ('..tostring(afk)..' Minutes)') end
end
end
end):on_event('error',function(self,err)
@@ -28,4 +28,4 @@ Event.register(-1,function(event)
}
self:close()
end):open()
end)
end)