Postado Março 9, 2015 10 anos ALGUÉM AJUDA CONCERTAR ? TFS 0.3.6 Versão 8.60 Adicione a "data/creaturescripts/antmagebomb.xml" function onLogin(cid, words, param, channel) local _ip = nil local p = 0 local list, ips = {}, {} local players = getPlayersOnline() local max = 3 -- Maximo de players no mesmo IP. for i, pid in ipairs(players) do local ip = getPlayerIp(pid) local tmp = table.find(ips, ip) if(tmp ~= nil and (not _ip or _ip == ip)) then if(table.countElements(list, ip) == 0) then list[players[tmp]] = ip end list[pid] = ip end table.insert(ips, ip) end if(table.maxn(list) > 0) then meip = getPlayerIp(cid) mename = getCreatureName(cid) for pid, ip in pairs(list) do local metmp = table.find(ips, meip) if (metmp ~= nil) then p = p + 1 end end doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Voce tem ".. p .." chars online!") if p > max then doRemoveCreature(cid, mename) end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Voce tem ".. p+1 .." char online!") end return true end Em "data/creaturescripts/creaturescripts.xml" adicione essa linha: <event type="login" name="AntMageBomb" event="script" value="AntMageBomb.lua"/> ERRO : ele funciona melhor que todos os outros que eu testei ate hoje, porem... quando entro com varias accounts manager ao mesmo tempo ( magebomb ) da esse erro. e acaba dado CRASH..ALGUÉM AJUDA CONCERTAR ?
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.