Jump to content

kamus9629

Visconde
  • Posts

    291
  • Joined

  • Last visited

  • Days Won

    1

Reputation Activity

  1. Upvote
    kamus9629 reacted to Satou in Nto Panzer V3   
    Salve Salve Pessoal do Xtibia hj vim postar o servidor do NTO PANZER V3 com o client
    E o Servidor Nao Contem o Mapa
     
    Algumas Vocaçoes que o servidor possui
     
     
     
    Servidor - http://adf.ly/1OfRLs
    Client - http://adf.ly/1OfOvU
     
    Scan :
     
    https://www.virustotal.com/pl/file/a62f73e607aec299d1fe772727c44298e82809cf412c65e08e70a1dec1d06909/analysis/1442861532/
     
    Creditos : Kazuya , Sirius(Satou)
  2. Upvote
    kamus9629 reacted to GamerGoiano in PokeAimar (Level System) 8.54 2020 (Com Sources)   
    Versão corrigida pelo @Jair Kevick
    https://mega.nz/file/bkFmDaIZ#dvrsamLjPvCzIhq-OmT8_xAlj97fiy8QUYIApL3csGM

    Me mandaram esse servidor e eu decidi deixar ele jogável porque muita gente tinha dificuldade em deixar online.
    Como deixar online:
    Basta criar um banco de dados com o xampp (use o xampp mais recente), com o nome poketibia e do lado onde está utf, escolhe Agrupamento (Colation) após isso é só importar o banco de dados que ta junto com o servidor.
    Ai é só abrir o servidor, esperar carregar e depois abrir o cliente e logar
    Conta god: GOD / 123456
    Download: https://www.mediafire.com/file/3atv44omlf3f036/PokeAimar.rar/file
    Vem com Sources e SPR+Dat Editável
    Scan: https://www.virustotal.com/gui/file/828a6e443c29221b9cd46f3fffe5f65c63bbb8e8ffc109a4fc91554d9c10e752/detection
    Créditos: Kaboflow, PDA, Psoul, Pstorm, Gengo, TFS Team, Cipsoft, DxP, PokemasterX.
    É um mistão de scripts do fórum + scripts próprios, acima listados os responsáveis pela criação do datapack e servidor.
    Descrição:
    Level System 100%
    1ª e 2ª geração completos
    Kanto e Ilhas Laranjas 100%
    Tv System 100%
    (Techinical Machine) Ensinar Moves pros Pokes 100%
    Daycare e Egg System 100%
    Duel System (PVP) 100%
    Gym System 100%
    Berries (Plantar, Colher e Usar) 100%
    Fly, Surf, Ride, Dive e Headbutt 100%
    Mastery System (Especializar em Elemento) 100%
    Tournament System 100%
    Saffari Zone 100%
    Poke Balls Effects 100%
    Pokemons na Character List 100%
    Poke Bar 100%
    Atravessar seu pokemon 100%
    Relógio In-Game 100%
    New Pokedex 100%
     



  3. Upvote
    kamus9629 got a reaction from GOD Vitor in Como Compilar Otclient sem erro   
    Créditos: EduBart - Sources do OTClient Kyogron - MinGW c/ Libs Wend - Tutorial / Tópico no TK Avuenja - Tópico das Sources 0.6.7 Eu(Banker) - Vídeo-Tutorial
    Link Testado ta funcionando
    Link Copilar Otclient https://www.youtube.com/watch?v=wlpYMsJvQg4&t=687s
    Possivel Erro  Link : 
     
     
    Antes de utilizar o CMake, acesse no menu Options > Warning Messages... > Supress Warnings > Marque as opções Developer Warnings e Deprecated Warnings.
     

  4. Thanks
    kamus9629 reacted to DarkWore in [DxP] Depot não salva nada   
    Vá na source em player.cpp e procure na função Depot* Player::getDepot(uint32_t depotId, bool autoCreateDepot) por:
    if(it != depots.end()) return it->second.first; Abaixo coloque:
    //create a new depot? if(autoCreateDepot) { Item* locker = Item::CreateItem(ITEM_LOCKER); if(Container* container = locker->getContainer()) { if(Depot* depot = container->getDepot()) { container->__internalAddThing(Item::CreateItem(ITEM_DEPOT)); addDepot(depot, depotId); return depot; } } g_game.freeThing(locker); std::cout << "Failure: Creating a new depot with id: " << depotId << ", for player: " << getName() << std::endl; } Até onde me lembro esse problema ocorre porque foi removido essa parte do código na source do DXP, acredito que isso resolva seu problema.
     
    Créditos a @wlucas8190 pela correção no tópico original do DXP.
    Link original da correção: 
     
  5. Thanks
    kamus9629 reacted to Hyaki in HELP LOOK INFORMATION   
    Na pasta lib procure o arquivo "somefuctions.lua" e procure pela função "getPlayerDesc" nela vai ter essas informações que você quer alterar!
  6. Thanks
    kamus9629 reacted to Yan Oliveira in Potion de Pokemon Certa quantidade de HP [Resolvido]   
    Opa, foi bobeira minha, mas eu refiz o código, testei e agora está funcionando:
    -- REFEITO POR YAN18 PARA RESTAURAR VIDA POR VALOR CONSTANTE -- function doHealOverTime(cid, hp, effect) if not isCreature(cid) then return true end doSendMagicEffect(getThingPos(cid), effect) doCreatureAddHealth(cid, math.floor(hp)) end local potions = { [1456] = {effect = 13, hp = 50000}, -- super potion [1451] = {effect = 13, hp = 50000}, -- great potion [384] = {effect = 12, hp = 50000}, -- ultra potion [385] = {effect = 14, hp = 50000}, -- hyper potion [392] = {effect = 14, hp = 50000}, -- full restore [667] = {effect = 14, hp = 50000}, -- full restore [668] = {effect = 14, hp = 50000}, -- full restore [669] = {effect = 14, hp = 50000}, -- full restore [670] = {effect = 14, hp = 50000}, -- full restore [671] = {effect = 14, hp = 50000}, -- full restore } function onUse(cid, item, frompos, item2, topos) local pid = getThingFromPosWithProtect(topos) if not isSummon(pid) or getCreatureMaster(pid) ~= cid then return doPlayerSendCancel(cid, "You can only use potions on your own Pokemons!") end if getCreatureHealth(pid) == getCreatureMaxHealth(pid) then return doPlayerSendCancel(cid, "This pokemon is already at full health.") end if getPlayerStorageValue(pid, 173) >= 1 then setPlayerStorageValue(pid, 173, -1) end if getPlayerStorageValue(cid, 52481) >= 1 then return doPlayerSendCancel(cid, "You can't do that while a duel.") end if getPlayerStorageValue(cid, 990) >= 1 then doPlayerSendCancel(cid, "You can't use potion during gym battles.") return true end doCreatureSay(cid, "".. getCreatureName(pid)..", take this potion!", TALKTYPE_MONSTER) doSendMagicEffect(getThingPos(pid), 0) setPlayerStorageValue(pid, 173, 1) doRemoveItem(item.uid, 1) local a = potions[item.itemid] doHealOverTime(pid, a.hp, a.effect) doPlayerSendCancel(cid, "Your monsters recovered " ..a.hp.. " of HP.") return true end Ai para configurar o HP, você precisa mudar os valores na variável hp de cada potion (item) na tabela potions onde está 50000 para todos.
  7. Thanks
    kamus9629 reacted to Tony Araujo in [C++] Unique Item System - ATUALIZADO! (No-bugs)   
    [C++] Unique Item System
    testado: TFS - 0.3.6 (porém acredito que funcione em outros)
    autor: Tony Araújo (OrochiElf)
    contribuição: gristony
     
     
    Olá galera, beleza? Então, tem tanto tempo que eu não faço minhas contribuições e hoje eu resolvi postar um sistema bastante simples, porém de extrema necessidade e importância nos servidores que dão items iniciais aos jogadores, especialmente os poketibias. Então com esse sistema o jogador fica impossibilitado de jogar o item fora e também de fazer trocas com outros jogadores, sendo literalmente únicos. Eu criei ele em cima do código do TFS 0.3.6, porém é um sistema com o código completamente simples, então acredito que se instalado atentamente em outras versões, funcione sem problemas.
    Bom, sem mais delongas vamos ao que interessa.
     
     
    Vá ao game.cpp e procure por esta função:
    bool Game::playerMoveItem(uint32_t playerId, const Position& fromPos, uint16_t spriteId, int16_t fromStackpos, const Position& toPos, uint8_t count)  
    Então, dentro desta mesma função, você procura por esta condição aqui.
    if(!player->hasCustomFlag(PlayerCustomFlag_CanThrowAnywhere)) { if((std::abs(playerPos.x - mapToPos.x) > item->getThrowRange()) || (std::abs(playerPos.y - mapToPos.y) > item->getThrowRange()) || (std::abs(mapFromPos.z - mapToPos.z) * 4 > item->getThrowRange())) { player->sendCancelMessage(RET_DESTINATIONOUTOFREACH); return false; } }  
     E logo abaixo adicione esta condição:
    Item* tmpItem = NULL; Container* tmpContainer = NULL; if(tmpContainer = item->getContainer()) { for(ContainerIterator it = tmpContainer->begin(); it != tmpContainer->end(); ++it) { if(tmpItem = (*it)->getItem()) { boost::any value = tmpItem->getAttribute("unique"); if(!value.empty() && getMap()->getTile(toPos)) { player->sendCancel("Has a unique item in this bag, you can't drop this item."); return false; } } } } boost::any value = item->getAttribute("unique"); if(!value.empty() && (!toCylinder->getItem() && toCylinder != player && toCylinder->getParent() != player || toCylinder->getItem() && toCylinder->getItem()->isGroundTile() || toCylinder->getItem() && toCylinder->getItem()->getContainer() && !toCylinder->getItem()->getContainer()->getDepot() && toCylinder->getItem()->getParent() != player)) { player->sendCancel("It is a unique item, you can't drop this item."); return false; }  
    Certo. Continuando no game.cpp, você vai procurar pela função:
    ReturnValue Game::internalMoveItem(Creature* actor, Cylinder* fromCylinder, Cylinder* toCylinder, int32_t index, Item* item, uint32_t count, Item** _moveItem, uint32_t flags /*= 0*/)  
    Dentro da função, você procura pela condição:
    //update item(s) if(item->isStackable())  
    E troque por esta:
    //update item(s) if(item->isStackable()) { if(toItem && toItem->getID() == item->getID()) { boost::any item_value = item->getAttribute("unique"); boost::any toItem_value = toItem->getAttribute("unique"); if(!item_value.empty() && !toItem_value.empty() || item_value.empty() && toItem_value.empty()) { n = std::min((uint32_t)100 - toItem->getItemCount(), m); toCylinder->__updateThing(toItem, toItem->getID(), toItem->getItemCount() + n); updateItem = toItem; } } if(m - n > 0) { moveItem = Item::CreateItem(item->getID(), m - n); boost::any value = item->getAttribute("unique"); if(!value.empty()) moveItem->setAttribute("unique", 1); } else moveItem = NULL; if(item->isRemoved()) freeThing(item); }  
    Sem sair do game.cpp, você procura pela função:
    bool Game::playerRequestTrade(uint32_t playerId, const Position& pos, int16_t stackpos, uint32_t tradePlayerId, uint16_t spriteId)  
    Dentro dela, você procura pela condição:
    if(!tradeItem || tradeItem->getClientID() != spriteId || !tradeItem->isPickupable() || (tradeItem->isLoadedFromMap() && (tradeItem->getUniqueId() != 0 || (tradeItem->getActionId() != 0 && tradeItem->getContainer())))) { player->sendCancelMessage(RET_NOTPOSSIBLE); return false; }  
    E logo abaixo você adiciona a condição:
    boost::any value = tradeItem->getAttribute("unique"); if(!value.empty()) { player->sendTextMessage(MSG_INFO_DESCR, "It is a unique item, you can't trade this item."); return false; } Item* tmpItem = NULL; Container* tmpContainer = NULL; if(tmpContainer = tradeItem->getContainer()) { for(ContainerIterator it = tmpContainer->begin(); it != tmpContainer->end(); ++it) { if(tmpItem = (*it)->getItem()) { boost::any value = tmpItem->getAttribute("unique"); if(!value.empty()) { player->sendTextMessage(MSG_INFO_DESCR, "Has a unique item in this bag, you can't trade this item."); return false; } } } }  
    Pronto, seu sistema de unique está instalado e pronto para ser utilizado. Para você setar o item unique, basta:
    doItemSetAttribute(item.uid, "unique", 1)  
    Algumas imagens
     
    Bom, é isso galera, espero que gostem e façam bom proveito. ;D
     

  8. Upvote
    kamus9629 reacted to FlamesAdmin in Unique Item?   
    function onUse(cid, item, fromPosition, itemEx, toPosition) if getPlayerStorageValue(cid, 326989) <= 0 then local item = doPlayerAddItem(cid, ItemID, Quantidade) doItemSetAttribute(item, "unique", 1) setPlayerStorageValue(cid, 326989, 1) return true else doPlayerSendTextMessage(cid, 20, "You already completed this quest!") return true end end  
  9. Thanks
    kamus9629 reacted to Gabrieltxu in HELP ERRO NEW STONE EVOLUCAO   
    Da algum erro? 
    Tem que estar setado como multi uso tambem. (Multi Use)
  10. Upvote
    kamus9629 got a reaction from alacazan in [Creaturescripts] Walking Effect On Outfit   
    Explica isso direito ai 
     
  11. Upvote
    kamus9629 reacted to JulianoZN in [Resolvido] NAO consigo Copilar O otclient   
    o MinGW e no disco local C:\
     
    o Path e na variavel de ambiente
     
    Caso nao tiver o Path
    clica em Novo

     
  12. Thanks
    kamus9629 reacted to Yan Oliveira in Pedido de NPC que da quests paralelas   
    Sobre o pedido do tópico, começando pelo primeiro NPC, vá em Data/NPC e crie um arquivo Carl.xml (lembrando que coloquei o nome do arquivo do mesmo nome do npc, caso queira mudar nome do npc sugiro mudar o do arquivo para ficar fácil de fazer manutenções futuras), após criar adicione o seguinte código dentro: 
    <?xml version="1.0" encoding="UTF-8"?> <npc name="Carl" script="Carl.lua" walkinterval="0" floorchange="0" access="5" level="1" maglevel="1"> <health now="150" max="150"/> <look type="516" head="10" body="15" legs="20" feet="25"/> <parameters> <parameter key="message_greet" value="Olá |PLAYERNAME|, o que você procura?"/> </parameters> </npc> Agora vá em Data/NPC/Scripts e crie um arquivo Carl.lua e adicione o seguinte código dentro:
    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 -- VARIÁVEIS -- local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid msg = string.lower(msg) local nome_segundo_npc = "Joey" local storage = 9999 ----------------------------------- [ DIALOGO COM NPC] --------------------------------- if msgcontains(msg, 'help') or msgcontains(msg, 'ajuda') or msgcontains(msg, 'missao') then if getPlayerStorageValue(cid, storage) == 1 then selfSay("Você deve falar diretamente com o NPC " ..nome_segundo_npc, cid) talkState[talkUser] = 0 return true else selfSay("Você gostaria de fazer a missão do NPC " ..nome_segundo_npc.. " ?", cid) talkState[talkUser] = 1 return true end elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'sim')) and talkState[talkUser] == 1 then selfSay("Agora você está autorizado para fazer a missão do NPC "..nome_segundo_npc.. "!", cid) setPlayerStorageValue(cid, storage, 1) talkState[talkUser] = 0 return true elseif (msgcontains(msg, 'no') or msgcontains(msg, 'não') or msgcontains(msg, 'nao')) and talkState[talkUser] == 1 then selfSay("Ok, fale comigo novamente caso queira fazer a missão do NPC " ..nome_segundo_npc.. ".", cid) talkState[talkUser] = 0 return true end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
    Segundo NPC:
     
    Agora iremos criar o segundo NPC, vá em Data/NPC e crie um arquivo Joey.xml e adicione o código dentro:
    <?xml version="1.0" encoding="UTF-8"?> <npc name="Joey" script="Joey.lua" walkinterval="0" floorchange="0" access="5" level="1" maglevel="1"> <health now="150" max="150"/> <look type="1421" head="114" body="119" legs="114" feet="114"/> <parameters> <parameter key="message_greet" value="Olá |PLAYERNAME|, em que posso ajudar? Diga {help}, {ajuda} ou {missão} para mais informações."/> </parameters> </npc> E vá em Data/NPC/Scripts, crie um arquivo Joey.lua e adicione o código dentro:
    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 -- VARIÁVEIS -- local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid msg = string.lower(msg) local nome_primeiro_npc = "Carl" local nome_terceiro_npc = "Peter" local id_item = 12163 local quantidade_item = 100 local id_item_recebido = 16563 local quantidade_item_recebido = 1 ----------------------------------- [ DIALOGO COM NPC] --------------------------------- if msgcontains(msg, 'help') or msgcontains(msg, 'ajuda') or msgcontains(msg, 'missao') then if getPlayerStorageValue(cid, 9999) == 1 then -- STORAGE DO PRIMEIRO NPC, OU SEJA, VERIFICA SE FALOU COM PRIMEIRO NPC. if getPlayerStorageValue(cid, 10000) == 1 then -- VERIFICA SE JÁ FEZ A MISSÃO DO SEGUNDO NPC selfSay("Você já fez minha missão, agora você deve falar diretamente com o NPC " ..nome_terceiro_npc.. ".", cid) talkState[talkUser] = 0 return true else selfSay("Preciso que você me traga " ..quantidade_item.. " seeds. Você trouxe?", cid) talkState[talkUser] = 1 return true end else selfSay("Você deve falar com o NPC " ..nome_primeiro_npc.. " para conseguir fazer minha missão.", cid) talkState[talkUser] = 0 return true end elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'sim')) and talkState[talkUser] == 1 then if getPlayerItemCount(cid, id_item) >= quantidade_item then doPlayerRemoveItem(cid, id_item, quantidade_item) selfSay("Você me trouxe as " ..quantidade_item.. " que eu precisava. Agora você consegue falar com o NPC " ..nome_terceiro_npc.. ".", cid) doPlayerAddItem(cid, id_item_recebido, quantidade_item_recebido) doSendMagicEffect(getThingPos(cid), 29) setPlayerStorageValue(cid, 10000, 1) talkState[talkUser] = 0 return true else selfSay("Você não trouxe a quantidade de seeds que eu preciso. Me traga " ..quantidade_item.. " seeds para prosseguir com a missão.", cid) talkState[talkUser] = 0 return true end return true end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
    Terceiro NPC
     
    Agora com o terceiro e último NPC, vá em Data/NPC e crie um arquivo Peter.xml e adicione o código dentro:
    <?xml version="1.0" encoding="UTF-8"?> <npc name="Peter" script="Peter.lua" walkinterval="0" floorchange="0" access="5" level="1" maglevel="1"> <health now="150" max="150"/> <look type="1413" head="114" body="119" legs="114" feet="114" corpse="2212"/> <parameters> <parameter key="message_greet" value="Olá |PLAYERNAME|, o que você procura aqui? Diga {help}, {ajuda} ou {missão} para mais informações."/> </parameters> </npc> E vá em Data/NPC/Scripts e crie um arquivo Peter.lua e adicione o código dentro:
    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 -- VARIÁVEIS -- local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid msg = string.lower(msg) local nome_segundo_npc = "Joey" ----------------------------------- [ DIALOGO COM NPC] --------------------------------- if msgcontains(msg, 'help') or msgcontains(msg, 'ajuda') or msgcontains(msg, 'missao') then if getPlayerStorageValue(cid, 10000) == 1 then -- VERIFICA SE FALOU COM SEGUNDO NPC if getPlayerStorageValue(cid, 10001) == 1 then -- VERIFICA SE TERMINOU A TASK selfSay("Você já completou minha missão.", cid) talkState[talkUser] = 0 return true else selfSay("Preciso que você derrote alguns {Charmanders} para mim. Você quer fazer essa missão?", cid) talkState[talkUser] = 1 return true end else selfSay("Você deve falar com o NPC " ..nome_segundo_npc.. " para conseguir fazer minha missão.", cid) talkState[talkUser] = 0 return true end elseif (msgcontains(msg, 'yes') or msgcontains(msg, 'sim') or (msgcontains(msg, 'task'))) and talkState[talkUser] == 1 then local id_item = 12545 local quantidade_item = 1 local exp = 10000 if getPlayerStorageValue(cid, 10002) == 1 then selfSay("Você completou minha missão! Receba sua recompensa.", cid) doPlayerAddExp(cid, exp) doPlayerAddItem(cid, id_item, quantidade_item) doSendAnimatedText(getThingPos(cid), exp, 27) setPlayerStorageValue(cid, 72451, 1) talkState[talkUser] = 0 return true else if getPlayerStorageValue(cid, 10002) < 0 then selfSay("Vá derrotar todos os {Charmanders} para mim.") setPlayerStorageValue(cid, 35000, 0) talkState[talkUser] = 0 return true elseif getPlayerStorageValue(cid, 10002) == 0 then selfSay("Você ainda não derrotou todos os {100 Charmanders}. Termine a missão primeiro antes de falar comigo.") talkState[talkUser] = 0 return true end return true end return true elseif (msgcontains(msg, 'no') or msgcontains(msg, 'não')) and talkState[talkUser] == 1 then selfSay("Ok, fale comigo novamente caso queira fazer minha missão.", cid) talkState[talkUser] = 0 return true end end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())  
    Agora é a configuração da task.
     
    Vá em Data/Creaturescripts/Scripts crie um arquivo chamado task_peter.lua e adicione o código dentro:
    local nome_terceiro_npc = "Peter" local storage_npc = 10002 local storage_contador = 10003 local pokemon = { [1] = {name = "Charmander", count = 100}, } local nome = pokemon[1].name local restante function onKill(cid, target) for _, t in ipairs(pokemon) do local quantidade = t.count if getCreatureName(target) == nome then if getPlayerStorageValue(cid, storage_npc) == 0 then if getPlayerStorageValue(cid, storage_contador) == quantidade then doPlayerSendTextMessage(cid, 27, "Não há mais " ..nome.. " para derrotar.") doPlayerSendTextMessage(cid, 20, "Parabéns! Você concluiu a task do " ..nome_terceiro_npc) setPlayerStorageValue(cid, storage_contador, getPlayerStorageValue(cid, storage_contador) + 1) setPlayerStorageValue(cid, storage_npc, 1) return true elseif getPlayerStorageValue(cid, storage_contador) < quantidade then -- AS STORAGES COMEÇAM COM -1, ENTÃO NESSA PARTE EU APENAS DEFINO COMO 0 PARA NA LINHA SEGUINTE JÁ IR PARA 1. NÃO COLOQUE RETURN NESSE LAÇO PORQUE VAI ENCERRAR O ESCOPO E NÃO VAI CONTAR CORRETAMENTE -- if getPlayerStorageValue(cid, storage_contador) < 0 then setPlayerStorageValue(cid, storage_contador, 0) end setPlayerStorageValue(cid, storage_contador, getPlayerStorageValue(cid, storage_contador) + 1) restante = quantidade - getPlayerStorageValue(cid, storage_contador) doPlayerSendTextMessage(cid, 27, "Faltam " ..restante.. " " ..nome.. "s para derrotar.") return true end elseif (getPlayerStorageValue(cid, storage_npc) < 0) or (getPlayerStorageValue(cid, storage_npc) > 0) then return true end return true end return true end end  
    Agora vá em Data/Creaturescripts e abra o creaturescripts.xml e adicione o evento:
    <event type="kill" name="task_peter" script="task_peter.lua"/>  
    E por último, vá em Data/Creaturescripts/Scripts ou Data/Creaturescripts/Scripts/Player (dependendo da base tem essa divisão de diretório) e procure pelo arquivo login.lua e procure pela parte dos registros de evento e adicione após o último a linha:
    registerCreatureEvent(cid, "task_peter")  
    Explicação:
     
    Pelo que entendi o primeiro NPC não pedirá nada, só dará acesso ao player, então para o player falar com o segundo NPC ele tem que falar com o primeiro antes! Eu deixei também o valor das storages em sequência para ficar mais fácil de alterar, e deixei o segundo com o valor 10000 como pediu. 
     
    Eu tinha feito os scripts faz tempo haha, mas eu estava testando na base DXP e nela não funciona o evento onKill, não da erro mas não funciona haha, ai perdi um tempinho até descobrir kk. Mas está ai a série de missão de npc.
     
    Testei aqui e todos os NPCs estão funcionando normalmente e a task do creaturescript está funcionando normal também, mas qualquer problema me fale.
  13. Upvote
    kamus9629 got a reaction from Poke X Ice in Segredo Sprite   
    https://www.facebook.com/Segredo-Spriters-119431992040772/

     
     

  14. Upvote
    kamus9629 got a reaction from TioSpiderBlack in Tibia Edit, Aumentar limite dos sprites e effects do Old Tibia.   
    A UM GRAVE ERRO NISSO A SOUCER ITEM EXTENDIDO  TEM QE ALTERAR 
    KKK PEGARAO SCRIPTER DO CRISTOFER KKK 
  15. Upvote
    kamus9629 got a reaction from Grayfullbuster in [8.54] Base Shinobi Online / OTNaruto {DOWNLOAD}   
    TEM SOUCER ?
  16. Upvote
    kamus9629 got a reaction from VelhoBarreiro in Proteger Spriter   
    Como Proteger Suas Sprite   ABRA PASTA Object Builder     Abaixe Notepad++
    https://notepad-plus-plus.org/

     
    MODIFIQUE A Dat e Spr Por Um Numero gigante Para Que object Build Bug E Aparessa Signitude 0 ASSIM ELES NAO CONSEGUIRAO Abrir com object Buid So Voce Porque so voce tem o codigo

     
     
    Depois Que Salva O Arquivo Abra Object Build

     
     
    Vai Em Arquivo e COPILAR COMO

    PROCURE OQUE VOCE EDITOU
     

     
    FINALIZER  CONFIRMANDO PRONTO

       









  17. Upvote
    kamus9629 reacted to VelhoBarreiro in [Design] Faça seu pedido   
    Desculpa @Whoami...
    Fiz esse tambem!!!

    Pedido entregue:

    Facebook cover - Daredevil x Punisher (OTMarvel)

    Link direto


  18. Upvote
    kamus9629 got a reaction from MalucoDoidao in Servidor Naruto Izzy (By João)   
    ?
  19. Upvote
    kamus9629 got a reaction from victorcain in NTO LEAGUES V0.1   
  20. Upvote
    kamus9629 reacted to Robinhood in [Encerrado] Cria 1 site para narutibia 7.81   
    Tenta usar o UniServ.
    Alem de ser mais facil, é bem melhor que xampp.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...