Postado Janeiro 9, 2015 10 anos Hi i need help with remake line of this script: local newidd = isShinyName(name) and ballcatch[item.itemid].ball [1] or ballcatch[item.itemid].ball[1] local typeee = ballcatch[item.itemid].typeee local restrictions = {"Moltres", "Articuno", "Zapdos", "Mew", "Mewtwo", "Entei", "Raikou", "Suicune", "Lugia", "Ho-oh", "Darkrai", "Beldum", "Metang", "Metagross", "Shiny Metagross", "Shiny Metang", "Shiny Milotic"} if isInArray(restrictions, name) then return doPlayerSendTextMessage(cid, 25, "This pokemon is legendary It can not be captured in master ball.") end order for this funcion to work not only for all balls but only for master ball. Editado Janeiro 9, 2015 10 anos por Spreh (veja o histórico de edições)
Postado Janeiro 9, 2015 10 anos O tópico foi movido para a área correta, preste mais atenção da próxima vez! Leia as regras do fórum: http://tibiaking.com/forum/topic/1281-regras-gerais/?p=7680 Este tópico foi movido: De: "OTServ → Suporte OTServ → Suporte de Scripts" Para: "OTServ → Suporte OTServ → Suporte de Servidores Derivados" The corrupt fear us. The honest support us. The heroic join us.
Postado Janeiro 9, 2015 10 anos Em 09/01/2015 em 18:49, Spreh disse: Hi i need help with remake line of this script: local newidd = isShinyName(name) and ballcatch[item.itemid].ball [1] or ballcatch[item.itemid].ball[1] local typeee = ballcatch[item.itemid].typeee local restrictions = {"Moltres", "Articuno", "Zapdos", "Mew", "Mewtwo", "Entei", "Raikou", "Suicune", "Lugia", "Ho-oh", "Darkrai", "Beldum", "Metang", "Metagross", "Shiny Metagross", "Shiny Metang", "Shiny Milotic"} if isInArray(restrictions, name) then return doPlayerSendTextMessage(cid, 25, "This pokemon is legendary It can not be captured in master ball.") end order for this funcion to work not only for all balls but only for master ball. I cant help u solving,cause i dont play poketibia, but i can help translating to more people see... i hope that u get a answer. i think we' ll need more, the full script to solve it Topic in portuguese: Tópico em português: Oi eu preciso de ajuda para refazer a linha desse script: local newidd = isShinyName(name) and ballcatch[item.itemid].ball [1] or ballcatch[item.itemid].ball[1] local typeee = ballcatch[item.itemid].typeee local restrictions = {"Moltres", "Articuno", "Zapdos", "Mew", "Mewtwo", "Entei", "Raikou", "Suicune", "Lugia", "Ho-oh", "Darkrai", "Beldum", "Metang", "Metagross", "Shiny Metagross", "Shiny Metang", "Shiny Milotic"} if isInArray(restrictions, name) then return doPlayerSendTextMessage(cid, 25, "This pokemon is legendary It can not be captured in master ball.") end Arrumar para essa função funcionar não só para pokebolas mas somente com masterbolas... Se quiser sua dúvida tirada, mande PM com os links, e não com a dúvida (outros podem ter a mesma dúvida, e o fórum serve para ser usado). Tópicos: Mostrar conteúdo oculto [FAQ] BBCODE [LIB] Constant [RME] Administrando bordas. [TALK] Broadcast Editável. [TALK] Sugest. [TALK] Checkpoint. [MOVE] Pântano pegajoso. [ACTION] Piggy Bank. (Cassino). [GLOBAL] Uptime Ad. [C0DE] Consertando 'Invalid Password' [PROGRAM] Quest Maker
Postado Janeiro 9, 2015 10 anos Autor Thank you for translate Full script: local ballcatch = { --id normal, id da ball shiy [2394] = {cr = 3, on = 24, off = 23, ball = {11826, 11737}, send = 47, typeee = "normal"}, --alterado v1.9 \/ [2391] = {cr = 6, on = 198, off = 197, ball = {11832, 11740}, send = 48, typeee = "great"}, [2393] = {cr = 10, on = 202, off = 201, ball = {11835, 11743}, send = 46, typeee = "super"}, [2392] = {cr = 20, on = 200, off = 199, ball = {11829, 11746}, send = 49, typeee = "ultra"}, [12617] = {cr = 99999, on = 204, off = 203, ball = {10975, 12621}, send = 35, typeee = "master"}, } function onUse(cid, item, frompos, item3, topos) local item2 = getTopCorpse(topos) if item2 == null then return true end if getItemAttribute(item2.uid, "catching") == 1 then return true end if getItemAttribute(item2.uid, "golden") and getItemAttribute(item2.uid, "golden") == 1 then return doPlayerSendCancel(cid, "You can't try to catch a pokemon in the Golden Arena!") end local name = string.lower(getItemNameById(item2.itemid)) --alterado v1.9 \/ name = string.gsub(name, "fainted ", "") name = string.gsub(name, "defeated ", "") name = doCorrectPokemonName(name) local x = pokecatches[name] local storage = newpokedex[name].stoCatch --alterado v1.9 \/ if getPlayerStorageValue(cid, storage) == -1 or not string.find(getPlayerStorageValue(cid, storage), ";") then setPlayerStorageValue(cid, storage, "normal = 0, great = 0, super = 0, ultra = 0, master = 0;") end if not x then return true end local owner = getItemAttribute(item2.uid, "corpseowner") if owner and isCreature(owner) and isPlayer(owner) and cid ~= owner then doPlayerSendCancel(cid, "You are not allowed to catch this pokemon.") return true end local catchinfo = {} catchinfo.rate = ballcatch[item.itemid].cr catchinfo.catch = ballcatch[item.itemid].on catchinfo.fail = ballcatch[item.itemid].off catchinfo.newid = newidd catchinfo.name = doCorrectPokemonName(name) catchinfo.topos = topos catchinfo.chance = x.chance doSendDistanceShoot(getThingPos(cid), topos, ballcatch[item.itemid].send) doRemoveItem(item.uid, 1) local newidd = isShinyName(name) and ballcatch[item.itemid].ball [1] or ballcatch[item.itemid].ball[1] local typeee = ballcatch[item.itemid].typeee local restrictions = {"Moltres", "Articuno", "Zapdos", "Mew", "Mewtwo", "Entei", "Raikou", "Suicune", "Lugia", "Ho-oh", "Darkrai", "Beldum", "Metang", "Metagross", "Shiny Metagross", "Shiny Metang", "Shiny Milotic"} if isInArray(restrictions, name) then return doPlayerSendTextMessage(cid, 25, "This pokemon is legendary It can not be captured in master ball.") end addEvent(doSendPokeBall, d * 70 + 100 - (d * 14) , cid, catchinfo, false, false, typeee) addEvent(doSendMagicEffect, (d * 70 + 100 - (d * 14)) - 100, topos, 3) return true end Editado Janeiro 9, 2015 10 anos por Spreh (veja o histórico de edições)
Postado Janeiro 9, 2015 10 anos U r welcome Look that local ballcatch = { --id normal, id da ball shiy [2394] = {cr = 3, on = 24, off = 23, ball = {11826, 11737}, send = 47, typeee = "normal"}, --alterado v1.9 \/ [2391] = {cr = 6, on = 198, off = 197, ball = {11832, 11740}, send = 48, typeee = "great"}, [2393] = {cr = 10, on = 202, off = 201, ball = {11835, 11743}, send = 46, typeee = "super"}, [2392] = {cr = 20, on = 200, off = 199, ball = {11829, 11746}, send = 49, typeee = "ultra"}, [12617] = {cr = 99999, on = 204, off = 203, ball = {10975, 12621}, send = 35, typeee = "master"}, } Try put all ids and config of this tab for the master ball, i think it ll work, im in my celphone now... Any mistake u can use u original script posted here... Se quiser sua dúvida tirada, mande PM com os links, e não com a dúvida (outros podem ter a mesma dúvida, e o fórum serve para ser usado). Tópicos: Mostrar conteúdo oculto [FAQ] BBCODE [LIB] Constant [RME] Administrando bordas. [TALK] Broadcast Editável. [TALK] Sugest. [TALK] Checkpoint. [MOVE] Pântano pegajoso. [ACTION] Piggy Bank. (Cassino). [GLOBAL] Uptime Ad. [C0DE] Consertando 'Invalid Password' [PROGRAM] Quest Maker
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.