Denuvo 71 Postado Maio 9, 2013 Share Postado Maio 9, 2013 (editado) Olá pessoal, irei compartilhar aqui o meu fishing.lua no fórum, pois parei com Pokétibia.. depois de muito tempo tentandodeixa-lo "jogavel" eu meio que consegui.. então pra quem tem problemas com o fishing dá uma conferida ai nessa versão, só lembrando que ele foi testado apenas no otclient.. function onUse(cid, item, fromPos, itemEx, toPos) d0 = {[0] = {pokemon = 'Magikarp'},[1] = {pokemon = 'Poliwag'},[2] = {pokemon = 'Krabby'},} d20 = { [0] = {pokemon = 'Magikarp'}, [1] = {pokemon = 'Marill'}, [2] = {pokemon = 'Remoraid'}, [3] = {pokemon = 'Krabby'}, [4] = {pokemon = 'Horsea'}, [6] = {pokemon = 'Poliwag'}, [5] = {pokemon = 'Goldeen'}, } d40 = {[0] = {pokemon = 'Magikarp'},[1] = {pokemon = 'Remoraid'},[2] = {pokemon = 'Marill'},[3] = {pokemon = 'Krabby'},[4] = {pokemon = 'Horsea'},[6] = {pokemon = 'Poliwag'},[5] = {pokemon = 'Goldeen'},[7] = {pokemon = 'Tentacool'},[8] = {pokemon = 'Chinchou'},[9] = {pokemon = 'Staryu'},} d60 = { [0] = {pokemon = 'Magikarp'}, [1] = {pokemon = 'Remoraid'}, [2] = {pokemon = 'Marill'}, [3] = {pokemon = 'Krabby'}, [4] = {pokemon = 'Horsea'}, [5] = {pokemon = 'Poliwag'}, [6] = {pokemon = 'Goldeen'}, [7] = {pokemon = 'Tentacool'}, [8] = {pokemon = 'Chinchou'}, [9] = {pokemon = 'Staryu'}, [10] = {pokemon = 'Poliwhirl'}, [11] = {pokemon = 'Seaking'}, [12] = {pokemon = 'Kingler'}, } d80 = {[0] = {pokemon = 'Magikarp'},[1] = {pokemon = 'Remoraid'},[2] = {pokemon = 'Marill'},[3] = {pokemon = 'Krabby'},[4] = {pokemon = 'Horsea'},[5] = {pokemon = 'Poliwag'},[6] = {pokemon = 'Goldeen'},[7] = {pokemon = 'Tentacool'},[8] = {pokemon = 'Chinchou'},[9] = {pokemon = 'Staryu'},[10] = {pokemon = 'Poliwhirl'},[11] = {pokemon = 'Seaking'},[12] = {pokemon = 'Kingler'},[13] = {pokemon = 'Seadra'},[14] = {pokemon = 'Starmie'},[15] = {pokemon = 'Corsola'},[16] = {pokemon = 'Mantine'},[17] = {pokemon = 'Politoed'},} d100 = { [0] = {pokemon = 'Magikarp'}, [1] = {pokemon = 'Remoraid'}, [2] = {pokemon = 'Marill'}, [3] = {pokemon = 'Krabby'}, [4] = {pokemon = 'Horsea'}, [5] = {pokemon = 'Poliwag'}, [6] = {pokemon = 'Goldeen'}, [7] = {pokemon = 'Tentacool'}, [8] = {pokemon = 'Chinchou'}, [9] = {pokemon = 'Staryu'}, [10] = {pokemon = 'Poliwhirl'}, [11] = {pokemon = 'Seaking'}, [12] = {pokemon = 'Kingler'}, [13] = {pokemon = 'Seadra'}, [14] = {pokemon = 'Starmie'}, [15] = {pokemon = 'Corsola'}, [16] = {pokemon = 'Mantine'}, [17] = {pokemon = 'Politoed'}, [18] = {pokemon = 'Octillery'}, [19] = {pokemon = 'Kingdra'}, [20] = {pokemon = 'Tentacruel'}, [21] = {pokemon = 'Gyarados'}, } local bonus = 8 local config = { waters = {4614, 4615, 4616, 4617, 4618, 4619, 4608, 4609, 4610, 4611, 4612, 4613, 7236, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625, 4665, 4666, 4820, 4821, 4822, 4823, 4824, 4825},} local borders = {4632, 4633, 4634, 4635, 4636, 4637, 4638, 4639, 4650, 4651, 4652, 4653, 4654, 4655, 4656, 4658, 4659, 4660, 4661, 4662, 4663} local skill = getPlayerSkillLevel(cid, 6)local playerpos = {x=getCreaturePosition(cid).x, y=getCreaturePosition(cid).y+1, z=getCreaturePosition(cid).z} function Effect() doSendMagicEffect(toPos, 1) end function Say() if skill >= 0 and skill < 20 thenlocal random = math.random(0, 6)if random <= 1 thendoSummonCreature(d0[random].pokemon, playerpos)elseif random >= 1 thendoPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER)enddoSendMagicEffect(getThingPos(cid), 173)doSendMagicEffect(toPos, 53)doCreatureSetNoMove(cid,false)setPlayerStorageValue(cid, 171833, -1)doPlayerAddSkillTry(cid, 6, 1) elseif skill >= 20 and skill < 40 then local random = math.random(0, 8) if random <= 3 then doSummonCreature(d20[random].pokemon, playerpos) elseif random >= 3 then doPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER) end doSendMagicEffect(getThingPos(cid), 173) doSendMagicEffect(toPos, 53) doCreatureSetNoMove(cid,false) setPlayerStorageValue(cid, 171833, -1) doPlayerAddSkillTry(cid, 6, 1) elseif skill >= 40 and skill < 60 then local random = math.random(0, 17)if random <= 8 thendoSummonCreature(d60[random].pokemon, playerpos)elseif random >= 8 thendoPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER)enddoSendMagicEffect(getThingPos(cid), 173)doSendMagicEffect(toPos, 53)doCreatureSetNoMove(cid,false)setPlayerStorageValue(cid, 171833, -1)doPlayerAddSkillTry(cid, 6, 1) elseif skill >= 60 and skill < 80 then local random = math.random(0, 17) if random <= 8 then doSummonCreature(d60[random].pokemon, playerpos) elseif random >= 8 then doPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER) end doSendMagicEffect(getThingPos(cid), 173) doSendMagicEffect(toPos, 53) doCreatureSetNoMove(cid,false) setPlayerStorageValue(cid, 171833, -1) doPlayerAddSkillTry(cid, 6, 1) elseif skill >= 80 and skill < 100 then local random = math.random(0, 17)if random <= 8 thendoSummonCreature(d60[random].pokemon, playerpos)elseif random >= 8 thendoPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER)enddoSendMagicEffect(getThingPos(cid), 173)doSendMagicEffect(toPos, 53)doCreatureSetNoMove(cid,false)setPlayerStorageValue(cid, 171833, -1)doPlayerAddSkillTry(cid, 6, 1) elseif skill >= 100 then local random = math.random(0, 17) if random <= 8 then doSummonCreature(d60[random].pokemon, playerpos) elseif random >= 8 then doPlayerSay(cid, "The pokemon has scaped the hook.", TALKTYPE_MONSTER) end doSendMagicEffect(getThingPos(cid), 173) doSendMagicEffect(toPos, 53) doCreatureSetNoMove(cid,false) setPlayerStorageValue(cid, 171833, -1) doPlayerAddSkillTry(cid, 6, 1) end end if getPlayerStorageValue(cid, 17000) >= 1 or getPlayerStorageValue(cid, 17001) >= 1 or getPlayerStorageValue(cid, 63215) >= 1 or getPlayerStorageValue(cid, 20010) >= 1 then doPlayerSendCancel(cid, "You can't fish when you are using bike, ride, surf or fly!")return trueend if getTilePzInfo(getCreaturePosition(cid)) == true then doPlayerSendCancel(cid, "You can't fish in protection zone.") return true end if(isInArray(config.waters, itemEx.itemid)) and getPlayerStorageValue(cid, 171833) >= 1 then doPlayerSendTextMessage(cid, 27, "You can't fish yet.")doSendMagicEffect(getThingPos(cid), 161)return trueend local fishingout = 316 if getPlayerSex(cid) == 0 then fishingout = fishingout+2 endif(isInArray(config.waters, itemEx.itemid)) and getPlayerStorageValue(cid, 171833) <= 0 thensetPlayerStorageValue(cid, 171833, 1)doCreatureSetNoMove(cid,true)doSendMagicEffect(toPos, CONST_ME_LOSEENERGY)doSendMagicEffect(toPos, 255)for i = 1,3 doaddEvent(Effect,750*i,cid)endaddEvent(Say,3000)return trueendreturn trueend Possa ser que dê algum erro com o efeito ao pescar pois, eu coloquei um efeito de isca nele, então o meu spr pode ser diferente do de vocês, caso ocorra isso é só você procurar por "doSendMagicEffect(toPos, 255)" e muda o "255" de acordo com o efeito que tiver no seu spr aconselho você substituir os "255" por "1".. lembrando que esse fishing não tem necessidade do uso de outfit. É isso galera bom aproveito :B Editado Maio 9, 2013 por ChuckNorris666 Link para o comentário https://xtibia.com/forum/topic/214001-fishinglua-pda-e-centurion-by-chucknorris666/ Compartilhar em outros sites More sharing options...
BrunooMaciell 85 Postado Maio 9, 2013 Share Postado Maio 9, 2013 Vou esta testando qualquer coisa !! Rep+ ^^ Link para o comentário https://xtibia.com/forum/topic/214001-fishinglua-pda-e-centurion-by-chucknorris666/#findComment-1518097 Compartilhar em outros sites More sharing options...
Denuvo 71 Postado Maio 9, 2013 Autor Share Postado Maio 9, 2013 ok :B Link para o comentário https://xtibia.com/forum/topic/214001-fishinglua-pda-e-centurion-by-chucknorris666/#findComment-1518171 Compartilhar em outros sites More sharing options...
guirlz 0 Postado Maio 10, 2013 Share Postado Maio 10, 2013 Muito bom cara, ótimo script.. só uma dúvida, tem como colocar ele para quando você pescar o bixo só ataque você.. pq por exemplo se você pesca e puxa seu poke os pokemons vao em outras pessoas.. Link para o comentário https://xtibia.com/forum/topic/214001-fishinglua-pda-e-centurion-by-chucknorris666/#findComment-1518737 Compartilhar em outros sites More sharing options...
Denuvo 71 Postado Maio 14, 2013 Autor Share Postado Maio 14, 2013 bom cara até onde eu sei ele só ataca o pokémon do player que pesco agora caso você sai pescando um monte ai é provável que ele ataque outros players.. Link para o comentário https://xtibia.com/forum/topic/214001-fishinglua-pda-e-centurion-by-chucknorris666/#findComment-1520548 Compartilhar em outros sites More sharing options...
Posts Recomendados