Ir para conteúdo

Summ

Membro
  • Registro em

  • Última visita

Tudo que Summ postou

  1. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    Tenta : function onSay(cid, words, param) if not getPlayerCondition(cid, CONDITION_INFIGHT) then doTeleportThing(cid, {x=1030, y=910, z=7}); doSendMagicEffect(getPlayerPosition(cid),3); doPlayerSendTextMessage(cid, 19, "Teleportado!"); else doPlayerSendTextMessage(cid, 19, "Somente sem battle."); end return 1; end
  2. EffectPos.lua level = 300; -- LEVEL function effectPos(cid) local config = { tidpos = getCreaturePos(cid); effect = xxxx; -- EFFEITO } local tableeffect = { [1] = {x=tidpos.x-1, y=tidpos.y-1, z=tidpos.z}; [2] = {x=tidpos.x, y=tidpos.y-1, z=tidpos.z}; [3] = {x=tidpos.x+1, y=tidpos.y-1, z=tidpos.z}; [4] = {x=tidpos.x+1, y=tidpos.y, z=tidpos.z}; [5] = {x=tidpos.x+1, y=tidpos.y+1, z=tidpos.z}; [6] = {x=tidpos.x, y=tidpos.y+1, z=tidpos.z}; [7] = {x=tidpos.x-1, y=tidpos.y+1, z=tidpos.z}; [8] = {x=tidpos.x-1, y=tidpos.y, z=tidpos.z}; } for x = 1, 8 do addEvent(function () if isCreature(cid) and not getTileInfo(getThingPos(cid)).protection then doSendMagicEffect(tableeffect[x], config.effect); end end , 1000) end return 1; end function onAdvance(cid, skill, oldLevel, newLevel) skill = SKILL_LEVEL; if skill == level then effectPos(cid); doPlayerSendTextMessage(cid, 19, "Congratulations !!"); doSendMagicEffect(getPlayerPosition(cid), CONST_ME_FIREWORK_YELLOW); end return 1; end function onLogin(cid) if getPlayerLevel(cid) >= level then effectPos(cid); end return 1; end Tag : <event type="login" name="EffectPos" event="script" value="EffectPos.lua"/> <event type="advance" name="EffectPos" event="script" value="EffectPos.lua"/> Ps : registrar EffectPos em login.lua antes do ultimo return true EffectText.lua local config = { ["1-5"] = 120; -- [VOCATION] = CORES; ["2-6"] = 130; ["3-7"] = 140; ["4-8"] = 150; } function effectText(cid) local texts = "´ . ,"; for vocations, color in pairs(config) do local v = vocations:explode("-"); if getPlayerVocation(cid) == (tonumber(v[1]) or tonumber(v[2])) then eff = doSendAnimatedText(getThingPos(cid), texts, color); break end end if isPlayer(cid) then eff() addEvent(function() if isPlayer(cid) then effectText(cid); end end, 600) end return 1; end function onLogin(cid) effectText(cid) return 1; end Tag : <event type="login" name="EffectText" event="script" value="EffectText.lua"/> Como é CALLBACK onLogin não precisa registrar... Config do EffectPos.lua : não sei o numero do effect que tu quer então deixei pra tu colocar : local config = { tidpos = getCreaturePos(cid); effect = xxxx; -- EFFEITO } e o level : level = 300; -- LEVEL Config do EffectText.lua : como eu não sabia os id da cor deixei pra tu colocar hahaha local config = { ["1-5"] = 120; -- [VOCATION] = CORES; ["2-6"] = 130; ["3-7"] = 140; ["4-8"] = 150; } não faço a miníma ideia de que cor são esses números .-. Abrçs
  3. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    /\ mais simplificado ainda hu3 function onKill(cid, target, lastHit) local config = { [500] = {10129, 10129}; [1000] = {10128, 10128}; [2000] = {10127, 10127} } for frags, item in pairs(config) do if getPlayerFrags(cid) == frags and getPlayerStorageValue(cid, item[1]) < 1 then local quest = doPlayerAddItem(cid, item[2]); doItemSetAttribute(quest, "description", "Esse item foi obtido por "..getPlayerName(cid).."."); setPlayerStorageValue(cid, item[1], 1); doSendMagicEffect(getPlayerPosition(cid), CONST_ME_HOLYAREA); end end return 1; end
  4. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    posta o script inteiro se possível.
  5. Não entendi o que é esses "risquinhos", se tu tiver uma imagem ou vídeo pra maior entendimento, eu ficaria grato
  6. ???? e outra posta seu vocations.XML
  7. <?xml version="1.0" encoding="UTF-8"?> <vocations> <vocation id="0" name="None" description="none" needpremium="0" gaincap="5" gainhp="5" gainmana="5" gainhpticks="6" gainhpamount="1" gainmanaticks="6" gainmanaamount="1" manamultiplier="4.0" attackspeed="2000" soulmax="100" gainsoulticks="120" fromvoc="0" attackable="no"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="1" name="Sorcerer" description="a sorcerer" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="50" gainmanaticks="3" gainmanaamount="50" manamultiplier="1.1" attackspeed="500" soulmax="100" gainsoulticks="120" fromvoc="1"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="2" name="Druid" description="a druid" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="6" gainhpamount="50" gainmanaticks="3" gainmanaamount="50" manamultiplier="1.1" attackspeed="500" soulmax="100" gainsoulticks="120" fromvoc="2"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="1.8" sword="1.8" axe="1.8" distance="1.8" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="3" name="Paladin" description="a paladin" needpremium="0" gaincap="20" gainhp="10" gainmana="15" gainhpticks="4" gainhpamount="50" gainmanaticks="4" gainmanaamount="50" manamultiplier="1.4" attackspeed="500" soulmax="100" gainsoulticks="120" fromvoc="3"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.2" club="1.2" sword="1.2" axe="1.2" distance="1.1" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> <vocation id="4" name="Knight" description="a knight" needpremium="0" gaincap="25" gainhp="15" gainmana="5" gainhpticks="3" gainhpamount="50" gainmanaticks="6" gainmanaamount="50" manamultiplier="3.0" attackspeed="500" soulmax="100" gainsoulticks="120" fromvoc="4"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.1" club="1.1" sword="1.1" axe="1.1" distance="1.4" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> <vocation id="5" name="Master Sorcerer" description="a master sorcerer" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="50" gainmanaticks="2" gainmanaamount="100" manamultiplier="1.1" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="1" lessloss="30"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="6" name="Elder Druid" description="an elder druid" needpremium="1" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="50" gainmanaticks="2" gainmanaamount="100" manamultiplier="1.1" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="2" lessloss="30"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="1.8" sword="1.8" axe="1.8" distance="1.8" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="7" name="Royal Paladin" description="an royal paladin" needpremium="1" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="50" gainmanaticks="3" gainmanaamount="100" manamultiplier="1.4" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="3" lessloss="30"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.2" club="1.2" sword="1.2" axe="1.2" distance="1.1" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> <vocation id="8" name="Elite Knight" description="an elite knight" needpremium="1" gaincap="25" gainhp="15" gainmana="5" gainhpticks="2" gainhpamount="50" gainmanaticks="4" gainmanaamount="100" manamultiplier="3.0" attackspeed="500" soulmax="200" gainsoulticks="15" fromvoc="4" lessloss="30"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.1" club="1.1" sword="1.1" axe="1.1" distance="1.4" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> <!-- <vocation id="9" name="Epic Master Sorcerer" description="an epic master sorcerer" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="10" gainmanaticks="2" gainmanaamount="10" manamultiplier="1.1" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="5" lessloss="50"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="2.0" sword="2.0" axe="2.0" distance="2.0" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="10" name="Epic Elder Druid" description="an epic elder druid" needpremium="0" gaincap="10" gainhp="5" gainmana="30" gainhpticks="4" gainhpamount="10" gainmanaticks="2" gainmanaamount="10" manamultiplier="1.1" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="6" lessloss="50"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.5" club="1.8" sword="1.8" axe="1.8" distance="1.8" shielding="1.5" fishing="1.1" experience="1.0"/> </vocation> <vocation id="11" name="Epic Royal Paladin" description="an epic royal paladin" needpremium="0" gaincap="20" gainhp="10" gainmana="15" gainhpticks="3" gainhpamount="10" gainmanaticks="3" gainmanaamount="10" manamultiplier="1.4" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="7" lessloss="50"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.2" club="1.2" sword="1.2" axe="1.2" distance="1.1" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> <vocation id="12" name="Epic Elite Knight" description="an epic elite knight" needpremium="0" gaincap="25" gainhp="15" gainmana="5" gainhpticks="8" gainhpamount="10" gainmanaticks="4" gainmanaamount="10" manamultiplier="3.0" attackspeed="2000" soulmax="200" gainsoulticks="15" fromvoc="8" lessloss="50"> <formula meleeDamage="1.0" distDamage="1.0" wandDamage="1.0" magDamage="1.0" magHealingDamage="1.0" defense="1.0" magDefense="1.0" armor="1.0"/> <skill fist="1.1" club="1.1" sword="1.1" axe="1.1" distance="1.4" shielding="1.1" fishing="1.1" experience="1.0"/> </vocation> --> </vocations>
  8. Eu também pensava assim, mas depois que comecei a frequentar o fórum com mais frequência percebi que isso não influenciariam em nada, sabe porque ? No fórum existe 3 tipos de pessoas : as que querem ajudar, as que querem aprender e as que estão apenas pra pedir... No caso isso seria pra beneficiar as pessoas que vem apenas para pedir, levando em conta que 90% desse pessoal não sabe nem criar um tópico na área correta, clicar em busca ali no canto direito e digitar pra ver se tem tal conteúdo, ou até mesmo lerem algum tutorial, criar um canto com apenas resposta resolvidas não adiantaria em nada. Sobre os download acho que isso não é culpa nem de quem posta, porque tem sites de download, que se em determinado tempo ninguém baixar, eles deletam tal arquivo, e sobre scripts não funcionais ta certo que tem muitos tópicos que não funciona, mas talvez possa não funcionar pra você e sim para outras pessoas, e partir desses scripts outros scripters pegam e melhoram e criam algo melhor, não é culpa de quem posta e sim do usuário que pega, não ter nenhum conhecimento necessário para faze-lo funcionar. É minha opnião. Abrçs Ps : 4 tipo de pessoa : as que entram apenas por entrar, seja pra bater papo, conversar com amigos, etc...
  9. function onTime() local days = {"Monday", "Tuesday"}; local message = "O evento foi aberto!!"; if isInArray(days, os.date("%A")) then doBroadcastMessage(message, MESSAGE_STATUS_WARNING); end return true end
  10. 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 configs ={ 2590; -- Storage "Querido como voce esta? Espero que tenha tratado de sua saude mande-me noticias"; --- Texto da carta } local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid if msgcontains(msg, 'promotion') then if getPlayerStorageValue(cid, configs[1]) < 1 then if getPlayerVocation(cid) <= 4 then selfSay("So you need a promotion? I can give her for you, but first, give this letter to my brother, he always ask me if i'm god, bad, you now...", cid) local item = doPlayerAddItem(cid,2597,1); doSetItemText(item, configs[2]); else selfSay("Sorry, you alredy have a promotion.", cid); end elseif getPlayerStorageValue(cid, configs[1]) == 1 then selfSay("Hey, you delivered, thanks man, here is your promotion!", cid); local vocation = getPlayerVocation(cid) + 4; doPlayerSetVocation(cid, vocation); doSendMagicEffect(getCreaturePosition(cid),CONST_ME_MAGIC_BLUE); else selfSay("I'm waiting you deliver the letter...", cid); end end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
  11. local effect = 30 -- Efeito que vai usar local storage = 9994 -- Storage que o player precisa ter local tempo = 5 -- Tempo em segundos function onLogin(cid) if getPlayerStorageValue(cid, storage) == 1 then sendEffect(cid) end return true end function sendEffect(cid) if isPlayer(cid) then doSendMagicEffect(getThingPos(cid), effect) addEvent(sendEffect, tempo*1000, cid) else return false end return true end #editado
  12. usa esse vai funcionar nessa versão que tu usa : http://www.tibiaking.com/forum/topic/32118-compilar-otserver-em-linux-ubuntu-1004/
  13. Summ postou uma resposta no tópico em Suporte OTServer Derivados
    #Nunca mexi com otclient : else if (isMonster()) { if (m_name.find("Champion")){ m_informationColor = Color(0x6A, 0x5A, 0xCD); } else if (m_name.find("Elite")){ m_informationColor = Color(0xFF, 0xD7, 0x00); } else if (m_name.find("Unique")){ m_informationColor = Color(0xFF, 0x45, 0x00); } else { m_informationColor = Color(0xBE, 0xBE, 0xBE); } }
  14. Summ postou uma resposta no tópico em Playground (Off-topic)
    infelizmente perdi segundos preciosos da minha vida lendo isso .-.
  15. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    function onUse(cid) local configs = { vipcoins = xxxx; -- Id do coins -- Primeiro item : 50% de chance, segundo 40%, terçeiro 30%, '' 15%, '' 5% items = {xxxx, xxxx, xxxx, xxxx, xxxx}; -- Id dos items } local rand = math.random(1, 140); if doPlayerRemoveItem(cid, configs.vipcoins, 1) then if rand <= 50 then -- 50% doPlayerAddItem(cid, configs.items[1], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 90 then -- 40% doPlayerAddItem(cid, configs.items[2], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 120 then -- 30% doPlayerAddItem(cid, configs.items[3], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 135 then -- 15% doPlayerAddItem(cid, configs.items[4], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 140 then -- 5% doPlayerAddItem(cid, configs.items[5], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); end else doPlayerSendTextMessage(cid, 19, 'You no have vipcoins.'); end return true end Testei e funcionando 100%.
  16. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    function onUse(cid) local configs = { vipcoins = xxxx; -- Id do coins -- Primeiro item : 50% de chance, segundo 40%, terçeiro 30%, '' 15%, '' 5% items = {xxxx, xxxx, xxxx, xxxx, xxxx}; -- Id dos items } math.randomseed(os.time()); local rand = math.random(1, 140); if doPlayerRemoveItem(cid, configs.vipcoins, 1) then if rand <= 50 then -- 50% doPlayerAddItem(cid, configs.items[1], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 90 then -- 40% doPlayerAddItem(cid, configs.items[2], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 120 then -- 30% doPlayerAddItem(cid, configs.items[3], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 135 then -- 15% doPlayerAddItem(cid, configs.items[4], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); elseif rand <= 140 then -- 5% doPlayerAddItem(cid, configs.items[5], 1); doPlayerSendTextMessage(cid, 19, 'Congratulations !!'); doSendMagicEffect(getThingPos(cid), 14); end else doPlayerSendTextMessage(cid, 19, 'You no have vipcoins.'); end return true end
  17. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    -- Storage IDs -- config = { Fassassino = 22115; Sassassino = 22116; } 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:lower(), 'addon1') then if getPlayerStorageValue(cid, config.Fassassino) < 1 then selfSay('Tem certeza ?', cid); talkState[talkUser] = 1; else selfSay('Parece que voce ja tem este addon, nao tente me zombar filho!', cid); talkState[talkUser] = 0; end elseif msgcontains(msg:lower(), 'yes') and talkState[talkUser] == 1 then if getPlayerItemCount(cid,2160) >= 1 then if doPlayerRemoveItem(cid,2160,1) then selfSay('Ah, certo! Aqui esta o seu addon, volte sempre.', cid); doSendMagicEffect(getCreaturePosition(cid), 13); doPlayerAddOutfit(cid, 152, 1); doPlayerAddOutfit(cid, 156, 1); setPlayerStorageValue(cid, config.Fassassino, 1); talkState[talkUser] = 0; end else selfSay('Voce nao tem todos os itens necessarios.', cid); talkState[talkUser] = 0; end end if msgcontains(msg:lower(), 'addon2') then if getPlayerStorageValue(cid, config.Sassassino) < 1 then selfSay('Tem certeza ?', cid); talkState[talkUser] = 2; else selfSay('Parece que voce ja tem este addon, nao tente me zombar filho!', cid); talkState[talkUser] = 0; end elseif msgcontains(msg:lower(), 'yes') and talkState[talkUser] == 2 then if getPlayerItemCount(cid, 2160) >= 1 then if doPlayerRemoveItem(cid, 2160, 1) then selfSay('Ah, certo! Aqui esta o seu addon, volte sempre.', cid); doSendMagicEffect(getCreaturePosition(cid), 13); doPlayerAddOutfit(cid, 152, 2); doPlayerAddOutfit(cid, 156, 2); setPlayerStorageValue(cid, config.Sassassino, 1); talkState[talkUser] = 0; end else selfSay('Voce nao tem todos os itens necessarios.', cid); talkState[talkUser] = 0; end end if msgcontains(msg:lower(), 'no') and talkState[talkUser] == 1 or talkState[talkUser] == 2 then selfSay('Tudo bem entao. Volte quando voce tem todos os itens necessarios.', cid); talkState[talkUser] = 0; end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
  18. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) 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 -- Storage IDs -- fassassino = 22015 sassassino = 22016 newaddon = 'Ah, certo! Aqui esta o seu addon, volte sempre.' noitems = 'Voce nao tem todos os itens necessarios.' noitems2 = 'Voce nao tem todos os itens necessarios.' already = 'Parece que voce ja tem este addon, nao tente me zombar filho!' function AssassinoFirst(cid, message, keywords, parameters, node) if(not npcHandler:isFocused(cid)) then return false end local addon = getPlayerStorageValue(cid,fassassino) if addon < 1 then if getPlayerItemCount(cid,2160) >= 1 and getPlayerItemCount(cid,2160) >= 1 then if doPlayerRemoveItem(cid,2160,1) and doPlayerRemoveItem(cid,2160,1) then npcHandler:say('Ah, certo! Aqui esta o seu addon, volte sempre.') doSendMagicEffect(getCreaturePosition(cid), 13) setPlayerStorageValue(cid,fassassino,1) if getPlayerSex(cid) == 1 then doPlayerAddOutfit(cid, 152, 1) elseif getPlayerSex(cid) == 0 then doPlayerAddOutfit(cid, 156, 2) end end else selfSay(noitems) end else selfSay(already) end end function AssassinoSecond(cid, message, keywords, parameters, node) if(not npcHandler:isFocused(cid)) then return false end local addon = getPlayerStorageValue(cid,sassassino) if addon < 1 then if getPlayerItemCount(cid,2160) >= 1 then if doPlayerRemoveItem(cid,2160,1) then npcHandler:say('Ah, certo! Aqui esta o seu addon, volte sempre.') doSendMagicEffect(getCreaturePosition(cid), 13) setPlayerStorageValue(cid,sassassino,1) if getPlayerSex(cid) == 1 then doPlayerAddOutfit(cid, 152, 2) elseif getPlayerSex(cid) == 0 then doPlayerAddOutfit(cid, 156, 1) end end else selfSay(noitems) end else selfSay(already) end end node2 = keywordHandler:addKeyword({'addon1'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Voce pode comprar o segundo addon por. Voce tem-los com voce?'}) node2:addChildKeyword({'yes'}, AssassinoFirst, {}) node2:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Tudo bem entao. Volte quando voce tem todos os itens necessarios.', reset = true}) node3 = keywordHandler:addKeyword({'addon2'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Voce pode comprar o segundo addon por. Voce tem-los com voce?'}) node3:addChildKeyword({'yes'}, AssassinoSecond, {}) node3:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Tudo bem entao. Volte quando voce tem todos os itens necessarios.', reset = true}) npcHandler:addModule(FocusModule:new())
  19. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    Tem como me dizer quantos items são ? e qual a porcentagem de ganhar de cada um ?
  20. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    Debian 6, 7, 7.5, 8...
  21. Summ postou uma resposta no tópico em Suporte Tibia OTServer
    local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) 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 -- Storage IDs -- fassassino = 22005 sassassino = 22006 newaddon = 'Ah, certo! Aqui esta o seu addon, volte sempre.' noitems = 'Voce nao tem todos os itens necessarios.' noitems2 = 'Voce nao tem todos os itens necessarios.' already = 'Parece que voce ja tem este addon, nao tente me zombar filho!' function AssassinoFirst(cid, message, keywords, parameters, node) if(not npcHandler:isFocused(cid)) then return false end addon = getPlayerStorageValue(cid,fassassino) if addon == -1 then if getPlayerItemCount(cid,2160) >= 1 and getPlayerItemCount(cid,2160) >= 1 then if doPlayerRemoveItem(cid,2160,1) and doPlayerRemoveItem(cid,2160,1) then npcHandler:say('Ah, certo! Aqui esta o seu addon, volte sempre.') doSendMagicEffect(getCreaturePosition(cid), 13) setPlayerStorageValue(cid,fassassino,1) if getPlayerSex(cid) == 1 then doPlayerAddOutfit(cid, 152, 1) elseif getPlayerSex(cid) == 0 then doPlayerAddOutfit(cid, 156, 2) end end else selfSay(noitems) end else selfSay(already) end end function AssassinoSecond(cid, message, keywords, parameters, node) if(not npcHandler:isFocused(cid)) then return false end addon = getPlayerStorageValue(cid,sassassino) if addon == -1 then if getPlayerItemCount(cid,2160) >= 1 then if doPlayerRemoveItem(cid,2160,1) then npcHandler:say('Ah, certo! Aqui esta o seu addon, volte sempre.') doSendMagicEffect(getCreaturePosition(cid), 13) setPlayerStorageValue(cid,sassassino,1) if getPlayerSex(cid) == 1 then doPlayerAddOutfit(cid, 152, 2) elseif getPlayerSex(cid) == 0 then doPlayerAddOutfit(cid, 156, 1) end end else selfSay(noitems) end else selfSay(already) end end node2 = keywordHandler:addKeyword({'addon1'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Voce pode comprar o segundo addon por. Voce tem-los com voce?'}) node2:addChildKeyword({'yes'}, AssassinoFirst, {}) node2:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Tudo bem entao. Volte quando voce tem todos os itens necessarios.', reset = true}) node3 = keywordHandler:addKeyword({'addon2'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Voce pode comprar o segundo addon por. Voce tem-los com voce?'}) node3:addChildKeyword({'yes'}, AssassinoSecond, {}) node3:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Tudo bem entao. Volte quando voce tem todos os itens necessarios.', reset = true}) npcHandler:addModule(FocusModule:new())
  22. Summ postou uma resposta no tópico em Eventos de Mapping
    Voto no mapa 2, o estilo me agradou bastante
  23. what ? basta clicar em banco de dados e criar uma nova "database"...
  24. o player que fala tem a storage idiom = 8971 ?

Informação Importante

Confirmação de Termo