local accounts = {
{"admin_account_name_1", "admin_ip_1"},
{"admin_account_name_2", "admin_ip_2"}
}
local function getIpByAccount(account)
for i = 1, #accounts do
if accounts[i][1] == account then
return accounts[i][2]
end
end
end
function onLogin(cid)
local ip = getIpByAccount(getPlayerAccount(cid))
if ip and getPlayerIp(cid) ~= ip then
doPlayerPopupFYI(cid, "You are not allowed to access this account")
return false
end
-- rest of the code here
return true
end