Merge branch 'core'

This commit is contained in:
Unknown
2018-04-20 20:48:33 +01:00
2 changed files with 11 additions and 0 deletions

View File

@@ -58,6 +58,14 @@ function Game.get_player(mixed)
end
elseif mixed then
local player = game.players[mixed]
if type(mixed) == "string" and tonumber(mixed) then
for _, p in pairs(game.players) do
if p.name == mixed then
player = p
break
end
end
end
return player and player.valid and player
end
end

View File

@@ -8,6 +8,9 @@ Discord: https://discord.gg/r6dC2uK
]]
--Please Only Edit Below This Line-----------------------------------------------------------
-- a base for functions to keep things clean
_G._ = {}
-- replaces the base error function
_error = error
error = function(err)