Postado Outubro 12, 2015 9 anos Eae galera blz? preciso de ajuda com esse script, ele serve para saber quantas balls gastei em um certo pokemon ex: !pokeballs gloom o problema é que sempre que uso o comando da isso --> Você ainda não gastou nenhuma ball para catar um Gloom.mesmo eu gastando varias balls no gloom.Base pokexcyan (Pokemons Icones)ai o Script local function sendBrokesMsg2(cid, name, str) --alterado v1.9 \/ TUDO!!if not isCreature(cid) then return false endlocal storage = getPlayerStorageValue(cid, str)if storage == -1 then return sendMsgToPlayer(cid, 27, "Você ainda não gastou nenhuma ball para catar esse pokemon!")endlocal t = "normal = (.-), great = (.-), super = (.-), ultra = (.-), saffari = (.-), dark = (.-);"local msg = {}table.insert(msg, "Você ja gastou: ")for n, g, s, u, s2, d in storage:gmatch(t) do if tonumber(n) and tonumber(n) > 0 then table.insert(msg, tostring(n).." Poke ball".. (tonumber(n) > 1 and "s" or "")) end if tonumber(g) and tonumber(g) > 0 then table.insert(msg, (#msg > 1 and ", " or "").. tostring(g).."Great ball".. (tonumber(g) > 1 and "s" or "")) end if tonumber(s) and tonumber(s) > 0 then table.insert(msg, (#msg > 1 and ", " or "").. tostring(s).."Super ball".. (tonumber(s) > 1 and "s" or "")) end if tonumber(u) and tonumber(u) > 0 then table.insert(msg, (#msg > 1 and ", " or "").. tostring(u).."Ultra ball".. (tonumber(u) > 1 and "s" or "")) end if tonumber(s2) and tonumber(s2) > 0 then table.insert(msg, (#msg > 1 and ", " or "").. tostring(s2).."Saffari ball".. (tonumber(s2) > 1 and "s" or "")) end if tonumber(d) and tonumber(d) > 0 then table.insert(msg, (#msg > 1 and ", " or "").. tostring(d).."Dark ball".. (tonumber(d) > 1 and "s" or "")) endendif #msg == 1 then return doPlayerSendTextMessage(cid, 27, "Você ainda não gastou nenhuma ball para catar um "..name..".")endif string.sub(msg[#msg], 1, 1) == "," then msg[#msg] = " and".. string.sub(msg[#msg], 2, #msg[#msg])endtable.insert(msg, " tentando catar um "..name..".")return sendMsgToPlayer(cid, 27, table.concat(msg))endfunction onSay(cid, words, param)if(param == '') then doPlayerSendTextMessage(cid, 27, "Coloque um nome de pokemon...") return trueendif newpokedex[doCorrectPokemonName(param)] then local storage = newpokedex[doCorrectPokemonName(param)].stoCatch local name = doCorrectPokemonName(param) sendBrokesMsg2(cid, name, storage)else doPlayerSendTextMessage(cid, 27, "Isso não e um pokemon...")endreturn trueend ficaria muito grato se alguém me ajudasse ! Dou Rep+
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.