-
Total de itens
108 -
Registro em
-
Última visita
Tudo que mylorc postou
-
Troquei porém ainda não resolveu: 13:55 Force: Olá Boy Short. Eu tenho uma missão para você. 13:55 Boy Short [8]: missao 13:55 Boy Short [8]: missão 13:55 Boy Short [8]: missão O que poderei fazer? Achei o erro haha na verdade ta tudo certo,só preciso editar o inicio para por um aviso do que precisa! Obrigado!
-
Estou postando o modo que esta aqui,caso esteje algo errado me informe por favor: XML -> <?xml version="1.0" encoding="ISO-8859-1"?> <npc name="Force" script="data/npc/scripts/missao.lua" walkinterval="3000" floorchange="0"> <health now="100" max="100"/> <look type="132" head="20" body="39" legs="45" feet="7" addons="0"/> <parameters> <parameter key="message_greet" value="Olá |PLAYERNAME|. Eu tenho uma {missão} para você." /> <parameter key="message_farewell" value="Até mais, |PLAYERNAME|!"/> </parameters> </npc> LUA -> local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end function creatureSayCallback(cid, type, msg) if(not npcHandler:isFocused(cid)) then return false end local stg = 14278 local item1 = 8710 local qtd = 10 local level = 7 local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid local msg = string.lower(msg) if(msgcontains(msg, 'missao')) and getPlayerStorageValue(cid, stg) >= 1 then selfSay('Você já me ajudou, sou grato por isso!', cid) talkState[talkUser] = 0 end if(msgcontains(msg, 'missao')) and getPlayerStorageValue(cid, stg) <= 0 then if (getPlayerItemCount(cid, item1) == qtd) then selfSay('Você não tem '..qtd..' {'..getItemNameById(item1)..'s}. Volte aqui quando tiver', cid) elseif doPlayerRemoveItem(cid, item1, qtd) then setPlayerStorageValue(cid, stg, 1) selfSay('Muito obrigado, como recompensa aqui está sua experiência por ter me ajudado!', cid) doPlayerAddLevel(cid, level) end end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
-
Porém agora não esta dando novamente,o player fala hi e ele responde,mas quando fala missão ou missao o npc não responde nada. Creio que o problema possa estar nesta localidade: local stg = 14278 local item1 = 8710 local qtd = 10 local level = 7 local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid local msg = string.lower(msg)
-
Agora ele respondeu,como eu edito para que o player tenha que entregar 10 cockroach legs e receba 7 level de recompença?
-
Sim,deixe me perguntar você testou também? O meu ot é 8.54 pode haver algum erro por isso?
-
Sim testei,porém quando falo hi para o npc,ele não responde. Não sei identificar o problema. Sabe resolver?
-
Fawz esse script que me passou : coloquei tudo certo porem quando entro no jogo e falo hi para o npc,ele simplesmente não responde,sabe o que pode ser?
-
O.K
-
Não deu,e sim eu troquei. Estou postando os aequivos aqui para você olhar: XML -> <npc name="Force" script="data/npc/scripts/force.lua" walkinterval="0" floorchange="0" access="5" level="1" maglevel="1"> <health now="150" max="150"/> <look type="124" head="114" body="114" legs="114" feet="114" corpse="2212"/> <parameters> <parameter key="message_greet" value="Welcome to the beginning of the game, Sir |PLAYERNAME|. You would make the {MISSION}?" /> </parameters> </npc> Lua -> local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} function doBuyPokemonWithCasinoCoins(cid, poke) npcHandler:onSellpokemon(cid) end function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid function creatureSayCallback(cid, type, msg) if(not npcHandler:isFocused(cid)) then return false end local storage = 6058 local items = {8710, 8710, 8710} if msgcontains(string.lower(msg), 'mission') or msgcontains(string.lower(msg), 'help') then selfSay("Would you like to help me on a mission?", cid) talkState[talkUser] = 1 elseif (msgcontains(string.lower(msg), 'yes') or msgcontains(string.lower(msg), 'sim')) and talkState[talkUser] == 1 then if getPlayerStorageValue(cid, storage) <= 0 then selfSay("Bring me these items:Cockroach leg, cockroach leg, cockroach leg and reward you with experience.", cid) setPlayerStorageValue(cid, storage, 1) talkState[talkUser] = 0 return true elseif getPlayerStorageValue(cid, storage) == 1 then for a, b in ipairs(items) do if getPlayerItemCount(cid, b) >= 1 then selfSay("Thank you!", cid) doPlayerAddLevel(cid, 7) doPlayerRemoveItem(cid, items, 1) talkState[talkUser] = 0 return true else selfSay("You have not got the items, so go search them!", cid) talkState[talkUser] = 0 return true end end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) (Obs: O 1° arquivo xml sujerido não deu certo,não apareceu no rme e nem no jogo,porém esse usado por mim só aparece no rme,mas ja deu totalmente certo com outros npc,tipo travel)
-
Fiz,porém o npc não aparece,nem tentando summonalo,creio que o problema seje o arquivo lua,pois o xml eu troquei com outros e não resolveu.
-
Tem skype para mim te mostrar como que é? Por que tipo só fala Sorry,not possible algo assim,não da error.
-
Esse é os arquivo:XML <?xml version="1.0" encoding="UTF-8"?> <npc name="Force" script="data/npc/scripts/force.lua" walkinterval="5000" floorchange="0" access="5" level="1" maglevel="1"> <health now="100" max="100"/> <look type="128" head="20" body="100" legs="50" feet="99" corpse="2212"/> <parameters> <parameter key="message_greet" value="Hello |PLAYERNAME|. Welcome to the start of the game. How can I help?{Mission}"/> <parameter key="message_farewell" value="Come back anytime, |PLAYERNAME|!"/> <parameter key="module_keywords" value="1" /> </parameters> </npc> Lua: local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end function creatureSayCallback(cid, type, msg) if(not npcHandler:isFocused(cid)) then return false end local talkUser = NPCHANDLER_CONVbehavior == CONVERSATION_DEFAULT and 0 or cid if(msgcontains(msg, 'kevnan')) and getPlayerStorageValue(cid, 3987) >= 1 then selfSay('You've picked the itens.', cid) talkState[talkUser] = 0 end if(msgcontains(msg, 'cheap')) and getPlayerStorageValue(cid, 3987) <= 0 then selfSay('Oh you saw the cockroaches out there know what is good in them? Ah legs ... haha', cid) elseif(msgcontains(msg, 'legs')) then selfSay('You talked legs? Tell {yes} or {no}', cid) talkState[talkUser] = 1 elseif(msgcontains(msg, 'more')) then selfSay('I believe that you can kill those cheap, come back when you get 10 legs to {mission}.', cid) talkState[talkUser] = 2 elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 1) then if (getPlayerItemCount(cid, 8710) >= 10) then selfSay('Ma. But that good news ..... Legs of cockroaches, Mom will make a soup with them .. Wondering {more}?', cid) talkState[talkUser] = 0 else selfSay('From what you're talking about legs?', cid) talkState[talkUser] = 0 end elseif(msgcontains(msg, 'mission') and talkState[talkUser] == 2) then if(getPlayerItemCount(cid, IDITEM1) >= 1) then if(getPlayerItemCount(cid, IDITEM2) >= 1) then if(getPlayerItemCount(cid, IDITEM3) >= 1) then selfSay('Thank you for picking up your legs for me. As promised here is your reward.', cid) doPlayerRemoveItem(cid, REMOVEITEM1, 1) doPlayerRemoveItem(cid, REMOVEITEM2, 1) doPlayerRemoveItem(cid, REMOVEITEM3, 1) doPlayerAddLevel(cid, 15407, 7) setPlayerStorageValue(cid, 3987, 1) talkState[talkUser] = 0 else selfSay('Still not got the legs? Remember that cheap is legs. You need to bring your legs to the mission', cid) talkState[talkUser] = 0 end end return TRUE end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) É isso ai,se tiver algum problema me avisa por favor.
-
Eu tento summonar e diz assim, Sorry,not possible. o que fazer?
-
É eu fiz tudo corretamente,porém ainda não aparece no jogo.(Obs:No RME aparece) O que podera estar ocorrendo?
-
Aonde fica o xp de recompença? Eu fiz tudo,coloquei no rme e tal,mas quando abro o jogo o npc não aparece. O que faço?
-
Olá,preciso criar um npc de missão,alguém me ajuda? Assim,preciso de um npc que recolha 3 itens e de recompença ele dara ao player xp (do lvl 1 irá para o lvl 8). Ajudem por favor.
-
(resolvido)Olá,gostaria de criar um npc de escolher profissão (paladin,Druid,Knight,Sorcerer) Alguém poderia me ajudar?
-
Resolvido! Obrigado.
-
Também não usa os Potions. Deu certo,obrigado. Como lhe dou +Rep?
-
Quando entro no Otserv e clico em food fala -> You cannot use this object - Você não pode usar esse objeto. Por favor me ajude,eu criei a pasta food dentro de actions/other.
-
Alguém pode me arrumar um itens.xml 8.54 full? Consegui arruma a escada só falta arrumar a porta para abrir ( consegui o Itens.cml ).
-
Quem Está Navegando 0 membros estão online
- Nenhum usuário registrado visualizando esta página.