Postado Setembro 21, 2015 9 anos Salve rapaziada, de novo pedindo scripts... Bom, meu pedido é o seguinte: comando !online mas apenas mostrar a quantidade de players online. Exemplo: Rep+ pra quem me ajudar, ou pelo menos tentar
Postado Setembro 21, 2015 9 anos Solução function onSay(cid, words, param) local player = Player(cid) local hasAccess = player:getGroup():getAccess() local players = Game.getPlayers() local playerCount = Game.getPlayerCount() player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, playerCount .. " players online.") local i = 0 local msg = "" for k, tmpPlayer in ipairs(players) do if hasAccess or not tmpPlayer:isInGhostMode() then if i > 0 then msg = msg .. ", " end msg = msg .. tmpPlayer:getName() .. " [" .. tmpPlayer:getLevel() .. "]" i = i + 1 end if i == 10 then if k == playerCount then msg = msg .. "." else msg = msg .. "," end player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, msg) msg = "" i = 0 end end if i > 0 then msg = msg .. "." player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, msg) end return false end STYLLER OT 2022
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.