1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2025-01-12 02:28:02 +02:00

made allowed_to_nuke not accept strings

This commit is contained in:
Maik Wild 2017-12-28 23:03:50 +01:00
parent 6c16927d66
commit 9bf96adac3

View File

@ -3,7 +3,7 @@
function allowed_to_nuke(player)
if type(player) == "table" then
return player.admin or is_mod(player.name) or is_regular(player.name) or ((player.online_time / 216000) > global.scenario.config.nuke_min_time_hours)
elseif type(player) == "number" or type(player) == string then
elseif type(player) == "number" then
return allowed_to_nuke(game.players[player])
end
end