Code:
function onLogin(player)
local maxMC = 10
local mcAmount = 0
for _, tmpPlayer in ipairs(Game.getPlayers()) do
if (player:getIp() == tmpPlayer:getIp()) then
if mcAmount >= maxMC then
return false
end
mcAmount = mcAmount + 1
end
end
return true
end
I'm trying to adapt this code so that when the player logs it to gain more storage if he already has 4 character logged in he does not win this storage