Snott 0 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) Alguem me ajuda numa coisa, nem abri meu ot ainda, to arrumando umas coisas hj fui tentar jogar normal com um player, qndo fui pegar o Poke nao faz nada ao clicar no Bau, alguem sabe arrumar isso? Ja tentei fazer umas coisas aqui mas nao consegui, nao sou scripter então nao saco muito dessas coisas... Editado Janeiro 28, 2012 por Snott Link para o comentário Compartilhar em outros sites More sharing options...
BRDominik 1 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 @all Duvida : Add o sytem de !dive mas n sei (na vdd nem procurei ainda/preguiça e sono) onde muda que o player toma hit debaixo dagua...alguem sabe configurar? E alguem sabe se teria como fazer alguma funcao sei la que pokes de agua se movessem mais rapido em sqm de sea? Vlw indo dormir aqui Tinha algum aqui que tava fazendo testes nao sei se ele disponibilizou. To saindo so agora(5:30). D= Link para o comentário Compartilhar em outros sites More sharing options...
pocotozinho 6 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 eu tentei add o bike sistem apareceu isso [28/01/2012 02:33:19] [Error - LuaScriptInterface::loadFile] data/actions/scripts/bike.lua:6: unfinished string near '']' [28/01/2012 02:33:19] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/bike.lua) [28/01/2012 02:33:19] data/act nem sei mais o que tentar aqui ja reistalei ja mudei o id do item mais da esse erro Link para o comentário Compartilhar em outros sites More sharing options...
notle 59 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 MAP POKEFLAY AKE http://www.mediafire...w2jy8vd4bomdjq4 baixei aqui de boa e notei que quando dono do pokeflay não quer compartilhar ai galera da uma força "" Pflay Hacked hehehe Link para o comentário Compartilhar em outros sites More sharing options...
FD CODE 16 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) eu tentei add o bike sistem apareceu isso [28/01/2012 02:33:19] [Error - LuaScriptInterface::loadFile] data/actions/scripts/bike.lua:6: unfinished string near '']' [28/01/2012 02:33:19] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/bike.lua) [28/01/2012 02:33:19] data/act nem sei mais o que tentar aqui ja reistalei ja mudei o id do item mais da esse erro Eu tinha pego quando o otal2012 posto mais eu nem avia testado, fui ver agora deu o mesmo erro mais era so um erro pequeno, ta ai embaixo o script arrumado lek : ) : function onUse(cid, item, fromPosition, itemEx, toPosition) local sBike = 5701 local t = { [2547] = {article='a', name='bike', text='Mount, bike!', dtext='Demount, bike!', s=5700, condition=bikeCondition}, } function BikeSpeedOn(cid,nSpeed) setPlayerStorageValue(cid,sBike,getCreatureSpeed(cid)) doChangeSpeed(cid,-getCreatureSpeed(cid)) doChangeSpeed(cid,nSpeed) end function BikeSpeedOff(cid) doChangeSpeed(cid,-getCreatureSpeed(cid)) doChangeSpeed(cid,getPlayerStorageValue(cid,sBike)) end local v, r = getCreaturePosition(cid), t[item.itemid] local s = r.s local pos = {x = v.x, y = v.y, z = v.z} if r then if getPlayerStorageValue(cid, 25000) == 5 then return end if getPlayerStorageValue(cid, 23000) == 5 then return end if #getCreatureSummons(cid) >= 1 then return end if getPlayerStorageValue(cid, 17001) == 1 or getPlayerStorageValue(cid, 63215) == 1 or getPlayerStorageValue(cid, 17000) == 1 then doPlayerSendCancel(cid, "You can't use bike while ride/fly/surf.") return true end if getPlayerStorageValue(cid, s) <= 0 then doSendMagicEffect(pos, 177) doCreatureSay(cid, r.text, 19) setPlayerStorageValue(cid, s, 1) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, 'You have mounted ' .. r.article .. ' '.. r.name .. '.') BikeSpeedOn(cid,500) if getPlayerSex(cid) == 1 then doSetCreatureOutfit(cid, {lookType = 1394, lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0}, -1) else doSetCreatureOutfit(cid, {lookType = 1393, lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0}, -1) end elseif getPlayerStorageValue(cid, s) == 1 then doSendMagicEffect(pos, 177) doCreatureSay(cid, r.dtext, 19) setPlayerStorageValue(cid, s, 0) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, 'You haven demouted ' .. r.article .. ' '.. r.name .. '.') BikeSpeedOff(cid) return doRemoveCondition(cid, CONDITION_OUTFIT) else return doPlayerSendCancel(cid, 'You can\'t do this.') end else return doPlayerSendTextMessage(cid,MESSAGE_STATUS_CONSOLE_BLUE, 'Report bugs in Bike system.') end end Abraços Editado Janeiro 28, 2012 por felipedaniel Link para o comentário Compartilhar em outros sites More sharing options...
ninu 26 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 Olá alguem ja tem o npc que troca hitmonlee+20 +200k por Shiny ou Elite Hitmonlee ? Eu achei no Forum um topico com esse script mais é antigo tem como alguem editar o script? Script local focus = 0 local talk_start = 0 local target = 0 local following = false local attacking = false local talkState = {} function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye sir!') focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function sellPokemon(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function sellPokemonn(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function onCreatureSay(cid, type, msg) local msg = string.lower(msg) local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if (msgcontains(msg, 'bye') and focus == cid) then selfSay('See you around then!') focus = 0 elseif (msgcontains(msg, 'hi') and (focus == 0) and (focus ~= cid) and (getDistanceToCreature(cid) <= 4)) then selfSay('Welcome! I train pokemons fighters, you have a fighter pokemon?.') focus = cid talkState[talkUser] = 1 talk_start = os.clock() elseif (msgcontains(msg, 'machamp') and talkState[talkUser] == 1 and focus == cid) then selfSay('It is impossible to defend against punches and chops distributed by his four arms. It has a great fighting spirit.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machoke') and talkState[talkUser] == 1 and focus == cid) then selfSay('It has a powerful body, uses a belt to power savings to regulate their movements.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machop') and talkState[talkUser] == 1 and focus == cid) then selfSay('A very good pokemon for intense workouts, has a great facility to master all forms of martial arts.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] ~= 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'poliwrath') and talkState[talkUser] == 1 and focus == cid) then selfSay('Has developed muscles, the muscles used for quick attacks despite being in the water.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'primeape') and talkState[talkUser] == 1 and focus == cid) then selfSay('An angry pokemon. gets even more furious when he lost a fight.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonlee') and talkState[talkUser] == 1 and focus == cid) then selfSay('Interesting! Is a pokemon with legs fast and hard, has devastating kicks. Always wanted to train one of these, if you want I can train him for a sum of 200k. Accepted?') talkState[talkUser] = "hitmonlee" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonlee" and focus == cid) then sellPokemon(cid, "hitmonlee", 1) talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonchan') and talkState[talkUser] == 1 and focus == cid) then selfSay('Is a great boxer, a man who never gives up. I always wanted to train one of these. For an amount of 200k I can transform it into a great boxer. Accepted?') talkState[talkUser] = "hitmonchan" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonchan" and focus == cid) then sellPokemonn(cid, "hitmonchan", 1) talkState[talkUser] = 1 end end function onThink() if focus == 0 then selfTurn(1) else argx, argy, argz = selfGetPosition() dir = getDirectionTo({x=argx,y=argy,z=argz}, getThingPos(focus)) if dir == 7 then dir = 0 elseif dir == 6 then dir = 3 elseif dir == 5 then dir = 1 elseif dir == 4 then dir = 3 end selfTurn(dir) end if (os.clock() - talk_start) > 59 then if focus ~= 0 then selfSay('We have been talking for too much time!') focus = 0 end end if focus ~= 0 then a, b, c = selfGetPosition() if c ~= getThingPos(focus).z then focus = 0 end end if focus ~= 0 then if getDistanceToCreature(focus) > 4 then selfSay('Come back to sell me pokemons!') focus = 0 end end return true end Npc.xml <?xml version="1.0" encoding="UTF-8"?> <npc name="Raviel" script="elitenpc.lua" walkinterval="350000" floorchange="0" speed="0"> <health now="150" max="150"/> <look type="313"/> <parameters> <parameter key="message_greet" value="Welcome! I train pokemons fighters, you have a fighter pokemon?"/> <parameter key="message_farewell" value="Bye."/> <parameter key="message_idletimeout" value="Bye."/> <parameter key="message_walkaway" value="Bye."/> </parameters> </npc> Link para o comentário Compartilhar em outros sites More sharing options...
slipdarkness 0 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 kara to com um problema, tenho lido quase todos posts de vcs soh q tive q cria uma acc pra poder resolver um problema aqui, qdo eu abro o server aparece q da erro nos npcs e nao aparece eles no map sera q vcs tem alguma soluçao pra esse problema. obrigado desde ja ;] Link para o comentário Compartilhar em outros sites More sharing options...
pocotozinho 6 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) vlws filipedaniel funfo bele r+++ pra tu '-' slipdarkness Verifique se os npc que voce ta colocando tem o looktype que oserver suporta Editado Janeiro 28, 2012 por pocotozinho Link para o comentário Compartilhar em outros sites More sharing options...
slipdarkness 0 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) ja tentei e continuou dando o problema! Se alguem pudesse postar a pasta de npc q funcione agradeçeria e ficaria muito mais facil ps:ja tenho a ultima versao do server. obrigado ahhh sim havia me esquecido...gostaria de saber como arrumo os pokemons para dar respaw lvl alto pq do goto golem e ele ta lvl 15-20 ;] Editado Janeiro 28, 2012 por slipdarkness Link para o comentário Compartilhar em outros sites More sharing options...
Denuvo 71 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) @pacotozinho c pode mim explicar como add o bikesytem? @EDIT jeff00 funciono a sua diica naum deu mais crash no cooldown bar REP+ Editado Janeiro 28, 2012 por ChuckNorris666 Link para o comentário Compartilhar em outros sites More sharing options...
darkeyren 13 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) @skycerberus Eu só ficava jogando skyrim ? Todo esse mapa foi feito por min e meu irmão, vocês desejam que eu distribua tudo ? tudo eu consegui fazendo , perdendo todo meu tempo criando esse mapa, fazendo tudo que eu consegui fazer, como o Ricardo disse se vocês ficaram sempre pedindo tudo vocês nunca vão para frente, o SkyCerberus fala que eu só ficava jogando skyrim, não era eu que ficava jogando player no saffari e fazendo 1 nurse para ele ficar se healando (: Não se pode confiar em ninguem hoje em dia. - Falaram que eu nunca ajudava? Eu ajudava sim , e tambem estava offline do XTibia a um bom tempo. Agora sobre o Mapa - Todos direitos desse mapa são todos meus e não autorizo a distribuição , peço que a moderação retire. Editado Janeiro 28, 2012 por DarkeyreN Link para o comentário Compartilhar em outros sites More sharing options...
Gravr 0 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 kkkkk ja ate baxei e uuuuu dlç dlç assim vc me mata ai se eu te pego ai ai se eu te pego nuss mt bom o mapa vlw ae @SkyCerberus e tbm vlw @DarkeyreN pelo otimo map e site Link para o comentário Compartilhar em outros sites More sharing options...
daaadam 5 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 @DarkeyreN Além disso tudo, o server ainda era corrupto, uau! @brun123 Poxa cara, tu simplismente zoou o templo do Bruxera 7.1 Só porque queria dar uma jogada e.e Link para o comentário Compartilhar em outros sites More sharing options...
diegoSkate 2 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 Olá alguem ja tem o npc que troca hitmonlee+20 +200k por Shiny ou Elite Hitmonlee ? Eu achei no Forum um topico com esse script mais é antigo tem como alguem editar o script? Script local focus = 0 local talk_start = 0 local target = 0 local following = false local attacking = false local talkState = {} function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye sir!') focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function sellPokemon(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function sellPokemonn(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function onCreatureSay(cid, type, msg) local msg = string.lower(msg) local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if (msgcontains(msg, 'bye') and focus == cid) then selfSay('See you around then!') focus = 0 elseif (msgcontains(msg, 'hi') and (focus == 0) and (focus ~= cid) and (getDistanceToCreature(cid) <= 4)) then selfSay('Welcome! I train pokemons fighters, you have a fighter pokemon?.') focus = cid talkState[talkUser] = 1 talk_start = os.clock() elseif (msgcontains(msg, 'machamp') and talkState[talkUser] == 1 and focus == cid) then selfSay('It is impossible to defend against punches and chops distributed by his four arms. It has a great fighting spirit.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machoke') and talkState[talkUser] == 1 and focus == cid) then selfSay('It has a powerful body, uses a belt to power savings to regulate their movements.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machop') and talkState[talkUser] == 1 and focus == cid) then selfSay('A very good pokemon for intense workouts, has a great facility to master all forms of martial arts.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] ~= 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'poliwrath') and talkState[talkUser] == 1 and focus == cid) then selfSay('Has developed muscles, the muscles used for quick attacks despite being in the water.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'primeape') and talkState[talkUser] == 1 and focus == cid) then selfSay('An angry pokemon. gets even more furious when he lost a fight.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonlee') and talkState[talkUser] == 1 and focus == cid) then selfSay('Interesting! Is a pokemon with legs fast and hard, has devastating kicks. Always wanted to train one of these, if you want I can train him for a sum of 200k. Accepted?') talkState[talkUser] = "hitmonlee" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonlee" and focus == cid) then sellPokemon(cid, "hitmonlee", 1) talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonchan') and talkState[talkUser] == 1 and focus == cid) then selfSay('Is a great boxer, a man who never gives up. I always wanted to train one of these. For an amount of 200k I can transform it into a great boxer. Accepted?') talkState[talkUser] = "hitmonchan" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonchan" and focus == cid) then sellPokemonn(cid, "hitmonchan", 1) talkState[talkUser] = 1 end end function onThink() if focus == 0 then selfTurn(1) else argx, argy, argz = selfGetPosition() dir = getDirectionTo({x=argx,y=argy,z=argz}, getThingPos(focus)) if dir == 7 then dir = 0 elseif dir == 6 then dir = 3 elseif dir == 5 then dir = 1 elseif dir == 4 then dir = 3 end selfTurn(dir) end if (os.clock() - talk_start) > 59 then if focus ~= 0 then selfSay('We have been talking for too much time!') focus = 0 end end if focus ~= 0 then a, b, c = selfGetPosition() if c ~= getThingPos(focus).z then focus = 0 end end if focus ~= 0 then if getDistanceToCreature(focus) > 4 then selfSay('Come back to sell me pokemons!') focus = 0 end end return true end Npc.xml <?xml version="1.0" encoding="UTF-8"?> <npc name="Raviel" script="elitenpc.lua" walkinterval="350000" floorchange="0" speed="0"> <health now="150" max="150"/> <look type="313"/> <parameters> <parameter key="message_greet" value="Welcome! I train pokemons fighters, you have a fighter pokemon?"/> <parameter key="message_farewell" value="Bye."/> <parameter key="message_idletimeout" value="Bye."/> <parameter key="message_walkaway" value="Bye."/> </parameters> </npc> Pow cara também tou querendo saber como q ajeita isso... eu tenho um npc tbm, mas ele não da o pokemon escolhido... na vrdd ele não faz nada! bem que o brun123 podia fazer um EX de npc que de pokemon... tipo quest! vamos aguardar... Link para o comentário Compartilhar em outros sites More sharing options...
Gravr 0 Postado Janeiro 28, 2012 Share Postado Janeiro 28, 2012 (editado) Olá alguem ja tem o npc que troca hitmonlee+20 +200k por Shiny ou Elite Hitmonlee ? Eu achei no Forum um topico com esse script mais é antigo tem como alguem editar o script? Script local focus = 0 local talk_start = 0 local target = 0 local following = false local attacking = false local talkState = {} function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye sir!') focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function sellPokemon(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonlee." local poke1 = "This is Elite Hitmonlee's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function sellPokemonn(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Elite Hitmonchan." local poke1 = "This is Elite Hitmonchan's pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Elite Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function onCreatureSay(cid, type, msg) local msg = string.lower(msg) local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if (msgcontains(msg, 'bye') and focus == cid) then selfSay('See you around then!') focus = 0 elseif (msgcontains(msg, 'hi') and (focus == 0) and (focus ~= cid) and (getDistanceToCreature(cid) <= 4)) then selfSay('Welcome! I train pokemons fighters, you have a fighter pokemon?.') focus = cid talkState[talkUser] = 1 talk_start = os.clock() elseif (msgcontains(msg, 'machamp') and talkState[talkUser] == 1 and focus == cid) then selfSay('It is impossible to defend against punches and chops distributed by his four arms. It has a great fighting spirit.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machoke') and talkState[talkUser] == 1 and focus == cid) then selfSay('It has a powerful body, uses a belt to power savings to regulate their movements.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machop') and talkState[talkUser] == 1 and focus == cid) then selfSay('A very good pokemon for intense workouts, has a great facility to master all forms of martial arts.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] ~= 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'poliwrath') and talkState[talkUser] == 1 and focus == cid) then selfSay('Has developed muscles, the muscles used for quick attacks despite being in the water.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'primeape') and talkState[talkUser] == 1 and focus == cid) then selfSay('An angry pokemon. gets even more furious when he lost a fight.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonlee') and talkState[talkUser] == 1 and focus == cid) then selfSay('Interesting! Is a pokemon with legs fast and hard, has devastating kicks. Always wanted to train one of these, if you want I can train him for a sum of 200k. Accepted?') talkState[talkUser] = "hitmonlee" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonlee" and focus == cid) then sellPokemon(cid, "hitmonlee", 1) talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonchan') and talkState[talkUser] == 1 and focus == cid) then selfSay('Is a great boxer, a man who never gives up. I always wanted to train one of these. For an amount of 200k I can transform it into a great boxer. Accepted?') talkState[talkUser] = "hitmonchan" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonchan" and focus == cid) then sellPokemonn(cid, "hitmonchan", 1) talkState[talkUser] = 1 end end function onThink() if focus == 0 then selfTurn(1) else argx, argy, argz = selfGetPosition() dir = getDirectionTo({x=argx,y=argy,z=argz}, getThingPos(focus)) if dir == 7 then dir = 0 elseif dir == 6 then dir = 3 elseif dir == 5 then dir = 1 elseif dir == 4 then dir = 3 end selfTurn(dir) end if (os.clock() - talk_start) > 59 then if focus ~= 0 then selfSay('We have been talking for too much time!') focus = 0 end end if focus ~= 0 then a, b, c = selfGetPosition() if c ~= getThingPos(focus).z then focus = 0 end end if focus ~= 0 then if getDistanceToCreature(focus) > 4 then selfSay('Come back to sell me pokemons!') focus = 0 end end return true end Npc.xml <?xml version="1.0" encoding="UTF-8"?> <npc name="Raviel" script="elitenpc.lua" walkinterval="350000" floorchange="0" speed="0"> <health now="150" max="150"/> <look type="313"/> <parameters> <parameter key="message_greet" value="Welcome! I train pokemons fighters, you have a fighter pokemon?"/> <parameter key="message_farewell" value="Bye."/> <parameter key="message_idletimeout" value="Bye."/> <parameter key="message_walkaway" value="Bye."/> </parameters> </npc> Pow cara também tou querendo saber como q ajeita isso... eu tenho um npc tbm, mas ele não da o pokemon escolhido... na vrdd ele não faz nada! bem que o brun123 podia fazer um EX de npc que de pokemon... tipo quest! vamos aguardar... local focus = 0 local talk_start = 0 local target = 0 local following = false local attacking = false local talkState = {} function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye sir!') focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function sellPokemon(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Shiny Hitmonlee." local poke1 = "This is Shiny Hitmonlee pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Shiny Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Shiny Hitmonlee." local poke1 = "This is Shiny Hitmonlee pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Shiny Hitmonlee") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function sellPokemonn(cid, name, price) local pokename = name local bp = getPlayerSlotItem(cid, CONST_SLOT_BACKPACK) local itemsball = getItemsInContainerById(bp.uid, 2222) local itemsultra = getItemsInContainerById(bp.uid, 2220) for _, pok in pairs(itemsball) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Shiny Hitmonchan." local poke1 = "This is Shiny Hitmonchan pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Shiny Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2222) selfSay('Thank You for letting me train him.') return true end end end for _, pok in pairs(itemsultra) do if string.lower(getItemAttribute(pok, "poke"):sub(9, findLetter(getItemAttribute(pok, "poke"), "'")-1)) == pokename then if(doPlayerRemoveMoney(cid, 20000000)) then doRemoveItem(pok, 1) local health = 7800 -- Health do poke local maxhealth = 7800 -- Maximo de health do poke local description = "Contains a Shiny Hitmonchan." local poke1 = "This is Shiny Hitmonchan pokeball. HP = ["..health.."/"..maxhealth.."]" item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", poke1) doItemSetAttribute(item, "nome", "Shiny Hitmonchan") doItemSetAttribute(item, "description", description) doPlayerAddItemEx(cid, item, true) doTransformItem(item, 2220) selfSay('Thank You for letting me train him.') return true end end end selfSay('Hey, you do not have that pokemon or the amount of money we agreed!') end function onCreatureSay(cid, type, msg) local msg = string.lower(msg) local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if (msgcontains(msg, 'bye') and focus == cid) then selfSay('See you around then!') focus = 0 elseif (msgcontains(msg, 'hi') and (focus == 0) and (focus ~= cid) and (getDistanceToCreature(cid) <= 4)) then selfSay('Welcome! I train pokemons fighters, you have a fighter pokemon?.') focus = cid talkState[talkUser] = 1 talk_start = os.clock() elseif (msgcontains(msg, 'machamp') and talkState[talkUser] == 1 and focus == cid) then selfSay('It is impossible to defend against punches and chops distributed by his four arms. It has a great fighting spirit.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machoke') and talkState[talkUser] == 1 and focus == cid) then selfSay('It has a powerful body, uses a belt to power savings to regulate their movements.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'machop') and talkState[talkUser] == 1 and focus == cid) then selfSay('A very good pokemon for intense workouts, has a great facility to master all forms of martial arts.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] ~= 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'poliwrath') and talkState[talkUser] == 1 and focus == cid) then selfSay('Has developed muscles, the muscles used for quick attacks despite being in the water.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'primeape') and talkState[talkUser] == 1 and focus == cid) then selfSay('An angry pokemon. gets even more furious when he lost a fight.') elseif (msgcontains(msg, 'thx') and talkState[talkUser] == 1 and focus == cid) then selfSay('Its nothing, tell me if you need something more.') talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonlee') and talkState[talkUser] == 1 and focus == cid) then selfSay('Interesting! Is a pokemon with legs fast and hard, has devastating kicks. Always wanted to train one of these, if you want I can train him for a sum of 200k. Accepted?') talkState[talkUser] = "hitmonlee" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonlee" and focus == cid) then sellPokemon(cid, "hitmonlee", 1) talkState[talkUser] = 1 ---------------------------------------------------------------- elseif (msgcontains(msg, 'hitmonchan') and talkState[talkUser] == 1 and focus == cid) then selfSay('Is a great boxer, a man who never gives up. I always wanted to train one of these. For an amount of 200k I can transform it into a great boxer. Accepted?') talkState[talkUser] = "hitmonchan" elseif (msgcontains(msg, 'yes') and talkState[talkUser] == "hitmonchan" and focus == cid) then sellPokemonn(cid, "hitmonchan", 1) talkState[talkUser] = 1 end end function onThink() if focus == 0 then selfTurn(1) else argx, argy, argz = selfGetPosition() dir = getDirectionTo({x=argx,y=argy,z=argz}, getThingPos(focus)) if dir == 7 then dir = 0 elseif dir == 6 then dir = 3 elseif dir == 5 then dir = 1 elseif dir == 4 then dir = 3 end selfTurn(dir) end if (os.clock() - talk_start) > 59 then if focus ~= 0 then selfSay('We have been talking for too much time!') focus = 0 end end if focus ~= 0 then a, b, c = selfGetPosition() if c ~= getThingPos(focus).z then focus = 0 end end if focus ~= 0 then if getDistanceToCreature(focus) > 4 then selfSay('Come back to sell me pokemons!') focus = 0 end end return true end Testa ae e ve se funfo Editado Janeiro 28, 2012 por Gravr Link para o comentário Compartilhar em outros sites More sharing options...
Posts Recomendados