Jump to content
Jobbysantos1999

Cast System TFS 0.4 [8.6]

Recommended Posts

Olá pessoal do Xtibia,

Já estou de saco cheio, esse bando de humanos querendo tirar aproveito de coisas falsas e piratas, cobrando um valor altíssimo por códigos, ou seja, cobrando por meros combinações de códigos... O cara fez um trabalho legal? Sim, fez, porém, está usando coisas falsas para serem revendidas (pirataria), como por exemplo :

  • War System (hoje não é mais vendido, já é gratuito)
  • Cast System (estará sendo postado gratuitamente)
  • TFS e Distros (Sem permissões do verdadeiro criado de Tibia)
  • E muitos outros...

Vem o que vem no conteúdo a seguir contem os seguintes items :

  • Sourcers com o Cast System.
  • Código MySQL para você por na sua database.
  • Talkaction para o player poder executar o comando.
  • Livestream.php, que é a página do Cast System com comandos e outros (não sei se suporta em Gesior, porém, sei que suporta em Modern).

Link para download:

Please login or register to see this link.

Scan:

Please login or register to see this link.

Bem, sei que nas sourcers modificadas tem essas marcações : //CA (Significa que há alterações relacionadas ao sistema do Cast)

NÃO ESQUEÇA DE ADICIONAR ISSO NO CONFIG.LUA :

enableCast = "true"

Créditos:

Jamison Collins

Jobby Magalhães (Por trazer para o forúm).

 

 

Obs: Não derei qualquer tipo de suporte do mesmo, apenas trouxe o mesmo para este forúm com intuito de ajudar a comunidade, obrigado.

 

Edited by JobbySantos

Share this post


Link to post
Share on other sites

eu consegui arumar os erro era na hora de compilar tive que tirar um negocio para funcionar agora esta 100% este cast tem bug que da crash no server?

to rodando esse cast no 8.6/9.8x/10.10 faz um tempo e até agr n caiu n...

Share this post


Link to post
Share on other sites

eu consegui arumar os erro era na hora de compilar tive que tirar um negocio para funcionar agora esta 100% este cast tem bug que da crash no server?

 

Bom meus amigos não tiveram problemas com crash até agora. *(Lembrando este cast so funciona perfeitamente em 8.6)* .

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Dilooow
      meus ginasio estao 100 % fora um erro que nao sei o do porque ele acontecem  quando mato os pokemons do npc de ginasio eles morrem normal porem antes do npc sacar seu 2 pokemon aparece o erro na distrito \/ quem puder me ajudar agradeço versao do serve e um serve open source   
       
      [02/07/2020 15:11:02] Servidor PBR, version 0.3.6 (Servidor PBR.)
      [02/07/2020 15:11:02] Compiled with Spacial Kpdo  at Jun 19 2020, 11:42:44.
      [02/07/2020 15:11:02] A server developed by : Gredison de jesus santos.
      [02/07/2020 15:11:02] Servidor PBR - Pokemon Tibia Online.
       
      [02/07/2020 15:13:40] [Error - CreatureScript Interface] 
      [02/07/2020 15:13:40] In a timer event called from: 
      [02/07/2020 15:13:40] buffer:onDeath
      [02/07/2020 15:13:40] Description: 
      [02/07/2020 15:13:40] [string "info = {..."]:145: attempt to index local 'pos' (a boolean value)
      [02/07/2020 15:13:40] stack traceback:
      [02/07/2020 15:13:41]     [string "info = {..."]:145: in function <[string "info = {..."]:142>
      [02/07/2020 15:17:17] [ADM] Flash has logged out.
       
    • By Nelsoncj
      Olá dobradores, de todo o mundo, venho com muita felicidade anunciar achegada do Avatar Elements, um MMORPG fantástico, de inúmeras possibilidade, um mundo, a onde a magia acontece, venha fazer parte desse delicioso servidor.
      Escolhe entre 4 classes distintas 
      -Fire
      -Air
      -Wather 
      -Earth 
       
      Cada classe com suas spells únicas e maravilhosa, venha se aventurar no fantástico, mundo Avatar Elements, enfrente diversas missões, diversos Bosses. 
       
      Não pense muito venha experimentar a magia de ser um dobrador, entre em nosso site, crie sua conta, baixe nosso cliente. Aguardamos vocês.
       
       
      Nossas redes sociais!
       
      Site:
      Please login or register to see this link.
      Discord: 
      Please login or register to see this link.
      Facebook: 
      Please login or register to see this link.

      Please login or register to see this attachment.

      Please login or register to see this attachment.

      Please login or register to see this attachment.
    • By Balkalima
      Account Manager: 1/1 
      IP: thunderbaiak.servegame.com
      Please login or register to see this link.

      Please login or register to see this link.
       
      Olá tibianos e tibianas amantes de um bom PvP ⚔️, este é um projeto que comecei desenvolvendo solo e que continuo desenvolvendo, mas já se encontra em um bom estágio para que vocês possam jogar e se divertir! 🎮

      O intuito do servidor vai além de fornecer um PvP balanceado, mas também em ser divertido, trazendo sistemas que agreguem nesta diversão, sendo sistemas únicos ou alguns já conhecidos, e com muitos desafios a serem descobertos e concluídos. 
       
       
      Rates:
      Skill - 80x
      Magic - 60x
      Loot - 20x
      Spawn - 10x
       
      Xp:
       1 ~ 250 - 800x
      251 ~ 500 - 500x
      501 ~ 700 - 200x
      701 ~ 1000 - 100x
      1001 ~ Ad infinitum - 50x
       
       
       
      ----------- Dúvidas Frequentes -----------
      1. Tem donate ou algum tipo de microtransação que atrapalhe a gameplay?
      Não, não temos donate ou microtransações, pois desde o inicio do desenvolvimento, o intuito era fazer um servidor onde todos, possam se divertir igualmente e tivessem a mesa chance no PvP e que apenas a habilidade fosse o diferencial, portanto sistemas PaytoWin não seria tolerados, assim o único retorno financeiro que esperamos do servidor é apenas para pagar as despesas 
       
      2. Se o servidor está em desenvolvimento, vai ter reset?
      Não, o servidor seguirá o desenvolvimento em Rolling Release, assim seu progresso nunca será perdido. 
       
      3. Tem algo faltando no servidor? Qual a velocidade de atualização?
      Sim, existem algumas coisas que estão sendo feitas antes de entrarem no servidor, e outras que serão feitas posteriormente.
       
      Atualmente a velocidade de atualização depende do que deve ser feito, pois como não contamos com um mapper, tudo que envolva essa parte é feito por mim que sou desenvolvedor, assim naturalmente demora mais para ser concluído, mas sistemas que são independentes de mapa, são produzidos mais rapidamente.
       
      ------------------------------------------
       
      ----------------- Equipe ----------------
      Atualmente nossa equipe conta com um desenvolvedor e administrador, Balkalima, e um auxiliar de comunidade e também desenvolvedor, Kilua.
       
      Estamos a procura de um mapper, portanto se tiver interessado no projeto nos contate pelo 
      Please login or register to see this link.
       para conversarmos melhor 😉  
      ------------------------------------------
    • By Poccnn
      Olá. Depois de muitos anos sem frequentar esse site, resolvi trazer algo novo.
       
      Estou atualmente trabalhando em um projeto de Npcs igual os da cipsoft.
      Irei postar alguns dos quais já foram concluídos.
       
      Al Dee.xml
      <?xml version="1.0" encoding="UTF-8"?> <npc name="Al Dee" script="data/npc/scripts/Rookgaard/Al Dee.lua" walkinterval="2000" floorchange="0"> <health now="100" max="100"/> <look type="129" head="58" body="77" legs="88" feet="115" addons="0"/> <parameters> <parameter key="message_greet" value="Hello, hello, |PLAYERNAME|! Please come in, look, and buy! I'm a specialist for all sorts of tools. Just ask me for a trade to see my offers! You can also ask me for general hints about the game. You can also ask me about each citizen of the isle."/> <parameter key="message_farewell" value="Bye, bye |PLAYERNAME|."/> <parameter key="module_keywords" value="1" /> <parameter key="keywords" value="How are you;tools;offer;trade;gold;backpack;rope;shovel;weapon;armor;shield;food;potion;cookis;fishing;cooking;fish;torch;worms;bone;help;job;name;time;premium;king;sell;wares;stuff;dungeon;sewers;vital;rats;monsters;merchants;tibia;rookgaard;mainland;profession;island of destiny;thais;academy;bank;temple;citizen;Al Dee;Amber;Billy;Cipfried;Dallheim;Dixi;Hyacinth;Lily;Loui;Norma;Obi;Paulie;Santiago;Seymour;The Oracle;Tom;Willie;Zerbrus;Zirella;" /> <parameter key="keyword_reply1" value="I'm fine. I'm so glad to have you here as my customer." /> <parameter key="keyword_reply2" value="As an adventurer, you should always have at least a backpack, a rope, a shovel, a weapon, an armor and a shield." /> <parameter key="keyword_reply3" value="Just ask me for a trade to see my offers." /> <parameter key="keyword_reply4" value="Take a look in the trade window to your right." /> <parameter key="keyword_reply5" value="Well, no gold, no deal. Earn gold by fighting monsters and picking up the things they carry. Sell it to merchants to make profit!" /> <parameter key="keyword_reply6" value="I am a merchant. What can I do for you?" /> <parameter key="keyword_reply7" value="I am a merchant. What can I do for you?" /> <parameter key="keyword_reply8" value="I am a merchant. What can I do for you?" /> <parameter key="keyword_reply9" value="Oh, I'm sorry, but I don't deal with weapons. That's Obi's or Lee'Delle's business. I could offer you a pick in exchange for a small axe if you should happen to own one." /> <parameter key="keyword_reply10" value="Armor and shields can be bought at Dixi's or at Lee'Delle's. Dixi runs that shop near Obi's." /> <parameter key="keyword_reply11" value="Armor and shields can be bought at Dixi's or at Lee'Delle's. Dixi runs that shop near Obi's." /> <parameter key="keyword_reply12" value="Hmm, the best address to look for food might be Willie or Billy. Norma also has some snacks for sale." /> <parameter key="keyword_reply13" value="Sorry, I don't sell potions. You should visit Lily for that." /> <parameter key="keyword_reply14" value="I sell fishing rods and worms if you want to fish. Simply ask me for a trade." /> <parameter key="keyword_reply15" value="I sell fishing rods and worms if you want to fish. Simply ask me for a trade." /> <parameter key="keyword_reply16" value="I you want to find someone who may want to buy your cookies, you should meet Lily." /> <parameter key="keyword_reply17" value="No thanks. I don't like fish." /> <parameter key="keyword_reply18" value="No thank you. I can already overstock the market with torches." /> <parameter key="keyword_reply19" value="I have enough worms myself and don't want any more. Use them for fishing." /> <parameter key="keyword_reply20" value="You better put that bone back there where you dug it out." /> <parameter key="keyword_reply21" value="If you need general equipment, just ask me for a trade. I can also provide you with some general hints about the game." /> <parameter key="keyword_reply22" value=" I'm a merchant. Just ask me for a trade to see my offers." /> <parameter key="keyword_reply23" value="My name is Al Dee, but you can call me Al. Can I interest you in a trade?" /> <parameter key="keyword_reply24" value="It's about 0:00 am. I'm so sorry, I have no watches to sell. Do you want to buy something else?" /> <parameter key="keyword_reply25" value="As a premium adventurer you have many advantages. You really should check them out!" /> <parameter key="keyword_reply26" value="The king encouraged salesmen to travel here, but only I dared to take the risk, and a risk it was!" /> <parameter key="keyword_reply27" value="Just ask me for a trade to see what I buy from you." /> <parameter key="keyword_reply28" value="Just ask me for a trade to see my offers." /> <parameter key="keyword_reply29" value="Just ask me for a trade to see my offers." /> <parameter key="keyword_reply30" value=" If you want to explore the dungeons such as the sewers, you have to equip yourself with the vital stuff I am selling. It's vital in the deepest sense of the word." /> <parameter key="keyword_reply31" value="Oh, our sewer system is very primitive - it's so primitive that it's overrun by rats. But the stuff I sell is safe from them. Just ask me for a trade to see it!" /> <parameter key="keyword_reply32" value="Well, vital means - necessary for you to survive!" /> <parameter key="keyword_reply33" value="Rats plague our sewers. You can sell fresh rat corpses to Seymour or Tom the tanner." /> <parameter key="keyword_reply34" value="If you want to challenge monsters in the dungeons, you need some weapons and armor from the local merchants." /> <parameter key="keyword_reply35" value="To view the offers of a merchant, simply talk to him or her and ask for a trade. They will gladly show you their offers and also the things they buy from you." /> <parameter key="keyword_reply36" value="One day I will return to the continent as a rich, a very rich man!" /> <parameter key="keyword_reply37" value="On the island of Rookgaard you can gather important experiences to prepare yourself for mainland." /> <parameter key="keyword_reply38" value="Have you ever wondered what that 'main' is people are talking about? Well, once you've reached level 8, you should talk to the oracle. You can choose a profession afterwards and explore much more of Tibia." /> <parameter key="keyword_reply39" value="You will learn everything you need to know about professions once you've reached the Island of Destiny." /> <parameter key="keyword_reply40" value="The Island of Destiny can be reached via the oracle once you are level 8. This trip will help you choose your profession!" /> <parameter key="keyword_reply41" value="Thais is a crowded town." /> <parameter key="keyword_reply42" value="The big building in the centre of Rookgaard. They have a library, a training centre, a bank and the room of the oracle. Seymour is the teacher there." /> <parameter key="keyword_reply43" value="A bank is quite useful. You can deposit your money safely there. This way you don't have to carry it around with you all the time. You could also invest your money in my wares!" /> <parameter key="keyword_reply44" value="The monk Cipfried takes care of our temple. He can heal you if you're badly injured or poisoned." /> <parameter key="keyword_reply45" value="If you tell me the name of a citizen, I'll tell you what I know about him or her." /> <parameter key="keyword_reply46" value="Yep, that's me. Smart of you to notice that!" /> <parameter key="keyword_reply47" value="She's currently recovering from her travels in the academy. It's always nice to chat with her!" /> <parameter key="keyword_reply48" value="This is a local farmer. If you need fresh food to regain your health, it's a good place to go. He's only trading with premium adventurers though." /> <parameter key="keyword_reply49" value="He is just an old monk. However, he can heal you if you are badly injured or poisoned." /> <parameter key="keyword_reply50" value="ome call him a hero. He protects the town from monsters." /> <parameter key="keyword_reply51" value="She's Obi's granddaughter and deals with armors and shields. Her shop is south west of town, close to the temple." /> <parameter key="keyword_reply52" value="He mostly stays by himself. He's a hermit outside of town - good luck finding him." /> <parameter key="keyword_reply53" value="She sells health potions and antidote potions. Also, she buys blueberries and cookies in case you find any." /> <parameter key="keyword_reply54" value="No idea who that is." /> <parameter key="keyword_reply55" value="She used to sell equipment, but I think she has opened a small bar now. Talks about changing her name to 'Mary' and such, strange girl." /> <parameter key="keyword_reply56" value="He sells weapons. His shop is south west of town, close to the temple." /> <parameter key="keyword_reply57" value="He's the local bank clerk." /> <parameter key="keyword_reply58" value="He dedicated his life to welcome newcomers to this island." /> <parameter key="keyword_reply59" value="Seymour is a teacher running the academy. He has many important information about Tibia." /> <parameter key="keyword_reply60" value="You can find the oracle on the top floor of the academy, just above Seymour. Go there when you are level 8." /> <parameter key="keyword_reply61" value="He's the local tanner. You could try selling fresh corpses or leather to him." /> <parameter key="keyword_reply62" value="This is a local farmer. If you need fresh food to regain your health, it's a good place to go. However, many monsters also carry food such as meat or cheese. Or you could simply pick blueberries." /> <parameter key="keyword_reply63" value="Some call him a hero. He protects the town from monsters." /> <parameter key="keyword_reply64" value="Poor old woman, her son Tom never visits her." /> <parameter key="module_shop" value="1"/> <parameter key="shop_buyable" value="backpack,1988,10;bag,1987,4;fishing rod,2580,150;rope,2120,50;scroll,1949,5;scythe,2550,12;shovel,2554,10;torch,2050,2;worm,3976,1"/> <parameter key="shop_sellable" value="fishing rod,2580,30;shovel,2554,2;rope,2120,8"/> </parameters> </npc>  
      Al Dee.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 local shopModule = ShopModule:new() npcHandler:addModule(shopModule) 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, 'pick') or msgcontains(msg, 'small axe') then npcHandler:say('Picks are hard to come by. I trade them only in exchange for high quality small axes. Would you like to make that deal?', cid) talkState[talkUser] = 1 elseif(talkState[talkUser] == 1)then if(msgcontains(msg,'yes'))then local get = config[troca] if(doPlayerRemoveItem(cid,2559,1) == true)then npcHandler:say('Splendid! Here, take your pick.', cid) doPlayerAddItem(cid,2553,1) else npcHandler:say('Sorry, I am looking for a SMALL axe.', cid) end else npcHandler:say("Well, then don't.",cid) end talkState[talkUser] = 0 elseif not(foodSayString(msg))then npcHandler:say('sorry but I do not know what they wanted.', cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
      Amber.xml
      <?xml version="1.0" encoding="UTF-8"?> <npc name="Amber" script="data/npc/scripts/Rookgaard/Amber.lua" walkinterval="2000" floorchange="0"> <health now="100" max="100"/> <look type="136" head="58" body="113" legs="113" feet="95" addons="1"/> <parameters> <parameter key="message_greet" value="Oh hello, nice to see you |PLAYERNAME| Are you here to hear some stories of my {adventures} or do you need {help}"/> <parameter key="message_farewell" value="See you later, |PLAYERNAME|."/> <parameter key="module_keywords" value="1" /> <parameter key="keywords" value="How are you;job;adventure;sea;explore;tibia;time;dungeon;sewer;king;rookgaard;academy;help;information;destiny;thais;main;castle;magic;weapon;monsters;orcs;cyclops;minotaur;dragon;premium;bank;food;tools;rope;shovel;torch;raft;mission;quest;Al Dee;Amber;Billy;Cipfried;Dallheim;Dixi;Hyacinth;Lily;Loui;Norma;Obi;Paulie;Santiago;Seymour;The Oracle;Tom;Willie;Zerbrus;Zirella" /> <parameter key="keyword_reply1" value="I'm recovering from a sea passage." /> <parameter key="keyword_reply2" value="I'm an explorer who seeks adventures." /> <parameter key="keyword_reply3" value=" I fought fierce monsters, climbed the highest mountains, explored the deepest dungeons and crossed the sea on a raft." /> <parameter key="keyword_reply4" value="My voyage on the sea was exhausting. The weather was bad, the waves high and my raft quite simple. There's a certain excitement to it, though." /> <parameter key="keyword_reply5" value="I've been almost everywhere in Tibia." /> <parameter key="keyword_reply6" value="I'm trying to explore each spot of Tibia, and one day I'll have seen it all." /> <parameter key="keyword_reply7" value="Sorry, I lost my watch in a storm." /> <parameter key="keyword_reply8" value="I had no time to explore the dungeons of this isle yet, but I've seen two big caves in the East, and there is a ruined tower to the north-west. Oh, and there're the sewers" /> <parameter key="keyword_reply9" value="I like sewers. I made my very first battle experience in the sewers below Thais. The small sewer system of Rookgaard has some nasty rats to fight." /> <parameter key="keyword_reply10" value="King Tibianus is the ruler of Thais. The island of Rookgaard belongs to his kingdom." /> <parameter key="keyword_reply11" value="It's a nice little island on which you can learn how to fight. I can see it in your eyes - you want to become a famous adventurer and explorer just like me!" /> <parameter key="keyword_reply12" value="A fine institution, but it needs definitely more funds from the king." /> <parameter key="keyword_reply13" value="Well, I can give you general hints or tell you about my adventures and many other topics. Oh, and if you are bored, I might have a small quest for you." /> <parameter key="keyword_reply14" value="Well, I can give you general hints or tell you about my adventures and many other topics. Oh, and if you are bored, I might have a small quest for you." /> <parameter key="keyword_reply15" value="You will find your destiny. I'm sure it's something big and important." /> <parameter key="keyword_reply16" value="A fine city, but the king has some problems enforcing the law." /> <parameter key="keyword_reply17" value="You'll be surprised once you leave this island. The world outside there is gigantic." /> <parameter key="keyword_reply18" value="If you travel to Thais, you really should visit the marvellous castle there." /> <parameter key="keyword_reply19" value="Spells are only taught in the guildhalls of the mainland." /> <parameter key="keyword_reply20" value="The best weapons on this isle are just toothpicks, compared with the weapons warriors of the mainland wield." /> <parameter key="keyword_reply21" value="Oh, I fought orcs, cyclopses, minotaurs, even dragons, and many other creatures." /> <parameter key="keyword_reply22" value="Not the nicest guys you can encounter. I had some clashes with them and finally ended up being their prisoner for a few months." /> <parameter key="keyword_reply23" value="I don't like the way they look at you. Their eye seems to pierce right through you. Creepy!" /> <parameter key="keyword_reply24" value="They are nasty monsters, particularly as they have distance fighters and mages in their clans. My backpack is handmade from minotaur leather." /> <parameter key="keyword_reply25" value="Their breath is so hot! I had to cut my hair after my last encounter with a dragon because the ends were all burnt. That's what you gotta deal with as a female adventurer!" /> <parameter key="keyword_reply26" value="I wouldn't want to miss being a premium adventurer. Everything is so much easier!" /> <parameter key="keyword_reply27" value="I have almost no money with me anyway, so no need to deposit any at the bank." /> <parameter key="keyword_reply28" value="My favourite dish is salmon. Oh please, bring me some." /> <parameter key="keyword_reply29" value="The most important tools you need are a rope, a shovel and maybe a torch." /> <parameter key="keyword_reply30" value="One day I fell into a hole without having a rope. I was yelling for help for three whole days! Eventually a fisherman passed by and pulled me out with his own rope, lucky me." /> <parameter key="keyword_reply31" value="Sometimes I have the strong urge to use it to knock someone out." /> <parameter key="keyword_reply32" value="You know, on mainland you will be able to cast magic spells which provide you with light. You won't really need torches anymore." /> <parameter key="keyword_reply33" value="I left my raft at the south-eastern shore. I forgot my private notebook on it. If you could return it to me, I would be very grateful." /> <parameter key="keyword_reply34" value="I left my raft at the south-eastern shore. I forgot my private notebook on it. If you could return it to me, I would be very grateful." /> <parameter key="keyword_reply35" value="I left my raft at the south-eastern shore. I forgot my private notebook on it. If you could return it to me, I would be very grateful." /> <parameter key="keyword_reply36" value="I don't have much to say about him. I think he sells tools." /> <parameter key="keyword_reply37" value="Did you know my name is also the name of a gem?" /> <parameter key="keyword_reply38" value="He brought me some of his famous rat stew. I really didn't want to insult him, but I simply can't eat something like that. So I told him I'm a vegetarian and I only eat fish." /> <parameter key="keyword_reply39" value="A gentle person. You should visit him if you have questions or need healing." /> <parameter key="keyword_reply40" value="An extraordinary warrior. He's the first and last line of defence of Rookgaard." /> <parameter key="keyword_reply41" value="I don't really know her, but she seems to be a nice girl." /> <parameter key="keyword_reply42" value="Hyacinth is a great healer. He lives somewhere hidden on this isle." /> <parameter key="keyword_reply43" value="Hm, I think I haven't met her yet." /> <parameter key="keyword_reply44" value="Never seen him around." /> <parameter key="keyword_reply45" value="She has changed a lot since I last saw her." /> <parameter key="keyword_reply46" value="He's a funny little man." /> <parameter key="keyword_reply47" value="No, I didn't go to the bank yet." /> <parameter key="keyword_reply48" value="He promised to repair my raft." /> <parameter key="keyword_reply49" value="I think this poor guy was a bad choice as head of the academy." /> <parameter key="keyword_reply50" value="The oracle is said to show you your destiny once you are level 8." /> <parameter key="keyword_reply51" value="To me he seems a bit rude, but maybe that's just my impression." /> <parameter key="keyword_reply52" value="He's funny in his own way." /> <parameter key="keyword_reply53" value="An extraordinary warrior. He's the first and last line of defence of Rookgaard." /> <parameter key="keyword_reply54" value="She seriously asked me if she could have the remains of my raft as fire wood! Can you imagine that??" /> </parameters> </npc>  
      Amber.lua
      local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} local orcish = { ["Charach"] = "Hi", ["Futchi"] = "Bye", ["Mok"] = "Yes", ["Burp"] = "No", ["Ikem goshak"] = "Offer", ["Goshak"] = "Buy", ["Porak"] = "Weapon", ["Bata"] = "Armor or Helmet", ["Dora"] = "Shield", ["Burka Bata"] = "Sword", ["Charcha"] = "Sabre", ["Hakhak"] = "Hatchet", ["Burka"] = "Short Sword", ["Batuk"] = "Bow", ["Pixo"] = "Arrows", ["Tulak Bora"] = "Studded Armor", ["Aka Bora"] = "Leather Armor", ["Donga"] = "Brass Shield", ["Grofa"] = "Studded Helmet", ["Humak"] = "Human", ["Minotaur"] = "Minotaur", ["Ork"] = "Orcs", ["Arash"] = "Have", ["Ba"] = "Which", ["Bana"] = "Slave", ["Bata"] = "Long/Longer", ["Batash"] = "Here", ["Booz"] = "More", ["Buta"] = "Damn(ed)/Stupid", ["Ferut"] = "Come", ["Gort"] = "People", ["Ikem"] = "I/me", ["Karak"] = "Dominate", ["Karakim"] = "Dominate", ["Karek"] = "Dominate", ["Kiskesh"] = "All", ["Klamuk"] = "Paleskin", ["Maruk"] = "You/Your", ["Mora"] = "Before", ["Omark"] = "Must", ["Ouk"] = "We", ["Pashak"] = "Sell", ["Ta"] = "That/It", ["Taka"] = "What", ["Tefar"] = "Want", ["Ul"] = "For/To", ["Utash"] = "Gosh", ["Nixda"] = "Money", } 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 shopModule = ShopModule:new() npcHandler:addModule(shopModule) 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, 'orcish') or msgcontains(msg, 'prisoner') then npcHandler:say("I speak some Orcish words, not many though, just a few basics like 'yes' and 'no'.", cid) talkState[talkUser] = 1 elseif msgcontains(msg, 'salmon') then npcHandler:say("Yeah! If you give me some salmon, I'll tell you another Orcish word. Okay?", cid) talkState[talkUser] = 2 elseif msgcontains(msg, 'notebook') then npcHandler:say("Do you bring me my notebook?", cid) talkState[talkUser] = 3 elseif msgcontains(msg, 'addon') then if(getPlayerStorageValue(cid, 91361) > 1 and getPlayerStorageValue(cid, 91361) < os.time())then npcHandler:say("Just in time! Your backpack is finished. Here you go, I hope you like it..", cid) doPlayerAddOutfit(cid,136,1) doPlayerAddOutfit(cid,128,1) doPlayerSetStorageValue(cid, 91361, 1) elseif(getPlayerStorageValue(cid, 91361) > os.time())then npcHandler:say("it is not ready yet.", cid) elseif(getPlayerStorageValue(cid, 91361) == 1)then npcHandler:say("You already have a accessory like mine.", cid) else npcHandler:say("Ah, you noticed my new accessory? Sorry, this one is not for sale. It's handmade from rare {minotaur leather}.", cid) end elseif msgcontains(msg, 'minotaur leather') then npcHandler:say("Well, if you really like this backpack, I could make one for you, but minotaur leather is hard to come by these days. Are you willing to put some work into this?", cid) talkState[talkUser] = 4 elseif msgcontains(msg, 'backpack') then npcHandler:say("Ah, right, almost forgot about the backpack! Have you brought me 100 pieces of minotaur leather as requested?", cid) talkState[talkUser] = 5 elseif(talkState[talkUser] == 1)then if(msgcontains(msg,'yes'))then npcHandler:say("It's 'mok' in Orcish. I tell you more if you bring me some food.", cid) else npcHandler:say("In Orcish that's 'burp'. I tell you more if you bring me some food.",cid) end talkState[talkUser] = 0 elseif(talkState[talkUser] == 2)then if(msgcontains(msg,'yes'))then if(doPlayerRemoveItem(cid,2668,1))then for k,v in pairs(orcish[math.random(1,orcish.len())]) do npcHandler:say(k.." means "..v, cid) break end else npcHandler:say("You don't have any salmon!", cid) end else npcHandler:say("Ok, then I won't tell you another Orcish word.",cid) end talkState[talkUser] = 0 elseif(talkState[talkUser] == 3)then if(msgcontains(msg,'yes'))then if(doPlayerRemoveItem(cid,1972,1))then npcHandler:say("thank you.", cid) else npcHandler:say("Mhm, whatever you have there, it is not my notebook.", cid) end else npcHandler:say("Too bad.",cid) end talkState[talkUser] = 0 elseif(talkState[talkUser] == 4)then if(msgcontains(msg,'yes'))then npcHandler:say("Alright then, if you bring me 100 pieces of fine minotaur leather I will see what I can do for you. You probably have to kill really many minotaurs though... so good luck!", cid) else npcHandler:say("Ok.",cid) end talkState[talkUser] = 0 elseif(talkState[talkUser] == 5)then if(msgcontains(msg,'yes'))then if(doPlayerRemoveItem(cid,5878,100))then npcHandler:say("Great! Alright, I need a while to finish this backpack for you. Come ask me later, okay?.", cid) setPlayerStorageValue(cid, 91361,os.time()+(60*60*2)) else npcHandler:say("I need 100 minotaur leather.", cid) end else npcHandler:say("Too bad.",cid) end talkState[talkUser] = 0 elseif not(foodSayString(msg))then npcHandler:say('sorry but I do not know what they wanted.', cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
       
      Lily.xml
      <?xml version="1.0" encoding="UTF-8"?> <npc name="Lily" script="data/npc/scripts/Rookgaard/Lily.lua" walkinterval="2000" floorchange="0"> <health now="100" max="100"/> <look type="138" head="78" body="119" legs="105" feet="115" addons="0"/> <parameters> <parameter key="message_greet" value="Welcome |PLAYERNAME|! You look a little stressed today. If you like to view my offers of potions, just ask me for a trade. In case you're looking for the marketplace and dungeons, just follow the path to the east!/> <parameter key="message_farewell" value="Take care, |PLAYERNAME|."/> <parameter key="module_keywords" value="1" /> <parameter key="keywords" value="monsters;job;name;Lily;mainland;druid;tibia;Hyacinth;Crunor;" /> <parameter key="keyword_reply1" value="Sadly, our little village of Rookgaard is invaded by monsters. From the dungeons they creep to the surface and attack the city. We always need adventurers helping us to fight them." /> <parameter key="keyword_reply2" value="I'm a druid, bound to the spirit of nature. My potions will help you if you feel bad. I also buy blueberries and cookies. Just ask me for a trade." /> <parameter key="keyword_reply3" value="My name is Lily, like the flower. It also stands for purity, just like my potions are!" /> <parameter key="keyword_reply4" value="Yes?" /> <parameter key="keyword_reply5" value="The main continent is huge! The gods of Tibia created everything from great seas, deep jungles and large deserts." /> <parameter key="keyword_reply6" value="Being a druid is a wonderful profession. You control the forces of nature and can heal others." /> <parameter key="keyword_reply7" value="Tibia is our beautiful world, created by the gods. Being a druid, I'm a worshipper of Crunor." /> <parameter key="keyword_reply8" value="Hyacinth also sells small health potions. He lives outside the village, in a hidden place." /> <parameter key="keyword_reply9" value="Crunor is the great lord of trees and the creator of all plants. Despite what some people believe, he didn't create the monsters, though." /> <parameter key="module_shop" value="1"/> <parameter key="shop_buyable" value="antidote potion,8474,50;small health potion,8704,20;"/> <parameter key="shop_sellable" value="cookie,2687,1;empty potion flask,7636,5;vial,2006,5;"/> </parameters> </npc>  
      Lily.lua
       
      local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} local tipo,count,item,price,more 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 shopModule = ShopModule:new() npcHandler:addModule(shopModule) function tibiaTime(min, sec) suffix = '' varh = (min*60+sec)/150 tibH = math.floor(varh) tibM = math.floor(60*(varh-tibH)) if tonumber(tibH) > 11 then tibH = tonumber(tibH) - 12 suffix = ' pm' else suffix = ' am' end if tibH == 0 then tibH = 12 end if (tibH < 10) then tibH = '0'..tibH end if (tibM < 10) then tibM = '0'..tibM end return (tibH..':'..tibM..suffix) end function creatureSayCallback(cid, type, msg) tipo,count,item = msg:trade() if(not npcHandler:isFocused(cid)) then return false end local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if msgcontains(msg, 'time') then npcHandler:say("It is about "..tibiaTime(os.date('%M'), os.date('%S'))..". But does it really matter? Don't rush yourself and enjoy all these little moments.", cid) elseif msgcontains(msg, 'blueberry')then npcHandler:say("how many blueberry do you have?", cid) talkState[talkUser] = 1 elseif(talkState[talkUser] == 1)then if(count >= 5)then npcHandler:say('I pay '..math.proxInteger(count/5)..' gps on '..count..' blueberry. accepted?', cid) talkState[talkUser] = 2 elseif(count > 100)then npcHandler:say('Tell me counter equal or less than 100.', cid) else npcHandler:say('I pay 1 gp for every 5 blueberry.', cid) end elseif(talkState[talkUser] == 2)then if msgcontains(msg, 'yes') then if(doPlayerRemoveItem(cid,2677,count) == true)then npcHandler:say('thank you very much!',cid) doPlayerAddMoney(cid,math.proxInteger(count/5)) else npcHandler:say('Hummm...',cid) end else npcHandler:say('Sorry for my bad offer.',cid) end talkState[talkUser] = 0 elseif not(foodSayString(msg))then npcHandler:say('sorry but I do not know what they wanted.', cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
      funções requeridas por tais scripts
      string.trade = function(str) --[[( Marcryzius )]]-- local tab,str = {},str:lower() tab[1] = str:match('sell') or 'buy' -- Retorna se vai comprar ou vender. tab[2] = getCount(str) < 1 and 1 or getCount(str) -- Retorna a quantidade. tab[3] = str:match(tab[1]..(str:match('(%d+)') and "%s%d+%s" or " ").."(.+)") -- Retorna o nome do item. if not(tab[3])then local name = '' for nome in str:gmatch("(%a+)") do if(nome)then name = name..(name ~= '' and ' ' or '')..nome end end tab[3] = name end return unpack(tab) end function math.proxInteger(value) --[[( Marcryzius )]]-- -- Função criada para determinar o valor inteiro mais proximo de uma fração. local value = tonumber(value) if not(value)then return 0,print('Function error: math.proxInteger() > valor => '..type(value)) end return value-math.floor(value) < 0.5 and math.floor(value) or math.ceil(value) end  
      postarei outros posteriormente.
       
×
×
  • Create New...