Ir para conteúdo
Propaganda

Noob

Membro
  • Total de Posts

    38
  • Registro em

  • Última visita

Tudo que Noob postou

  1. minimapWidget = nil minimapButton = nil minimapWindow = nil fullmapView = false loaded = false oldZoom = nil oldPos = nil function init() minimapWindow = g_ui.loadUI('minimap', modules.game_interface.getRightPanel()) minimapWindow:setContentMinimumHeight(64) if not minimapWindow.forceOpen then minimapButton = modules.client_topmenu.addRightGameToggleButton('minimapButton', tr('Minimap') .. ' (Ctrl+M)', '/images/topbuttons/minimap', toggle) minimapButton:setOn(true) end minimapWidget = minimapWindow:recursiveGetChildById('minimap') local gameRootPanel = modules.game_interface.getRootPanel() g_keyboard.bindKeyPress('Alt+Left', function() minimapWidget:move(1,0) end, gameRootPanel) g_keyboard.bindKeyPress('Alt+Right', function() minimapWidget:move(-1,0) end, gameRootPanel) g_keyboard.bindKeyPress('Alt+Up', function() minimapWidget:move(0,1) end, gameRootPanel) g_keyboard.bindKeyPress('Alt+Down', function() minimapWidget:move(0,-1) end, gameRootPanel) g_keyboard.bindKeyDown('Ctrl+M', toggle) g_keyboard.bindKeyDown('Ctrl+Shift+M', toggleFullMap) minimapWindow:setup() connect(g_game, { onGameStart = online, onGameEnd = offline, }) connect(LocalPlayer, { onPositionChange = updateCameraPosition }) if g_game.isOnline() then online() end end function terminate() if g_game.isOnline() then saveMap() end disconnect(g_game, { onGameStart = online, onGameEnd = offline, }) disconnect(LocalPlayer, { onPositionChange = updateCameraPosition }) local gameRootPanel = modules.game_interface.getRootPanel() g_keyboard.unbindKeyPress('Alt+Left', gameRootPanel) g_keyboard.unbindKeyPress('Alt+Right', gameRootPanel) g_keyboard.unbindKeyPress('Alt+Up', gameRootPanel) g_keyboard.unbindKeyPress('Alt+Down', gameRootPanel) g_keyboard.unbindKeyDown('Ctrl+M') g_keyboard.unbindKeyDown('Ctrl+Shift+M') minimapWindow:destroy() if minimapButton then minimapButton:destroy() end end function toggle() if not minimapButton then return end if minimapButton:isOn() then minimapWindow:close() minimapButton:setOn(false) else minimapWindow:open() minimapButton:setOn(true) end end function onMiniWindowClose() if minimapButton then minimapButton:setOn(false) end end function online() loadMap() updateCameraPosition() minimapWidget:setZoom(-1) end function offline() saveMap() end function loadMap() local clientVersion = g_game.getClientVersion() g_minimap.clean() loaded = false local minimapFile = '/minimap.otmm' local dataMinimapFile = '/data' .. minimapFile local versionedMinimapFile = '/minimap' .. clientVersion .. '.otmm' if g_resources.fileExists(dataMinimapFile) then loaded = g_minimap.loadOtmm(dataMinimapFile) end if not loaded and g_resources.fileExists(versionedMinimapFile) then loaded = g_minimap.loadOtmm(versionedMinimapFile) end if not loaded and g_resources.fileExists(minimapFile) then loaded = g_minimap.loadOtmm(minimapFile) end if not loaded then print("Minimap couldn't be loaded, file missing?") end minimapWidget:load() end function saveMap() local clientVersion = g_game.getClientVersion() local minimapFile = '/minimap' .. clientVersion .. '.otmm' g_minimap.saveOtmm(minimapFile) minimapWidget:save() end function updateCameraPosition() local player = g_game.getLocalPlayer() if not player then return end local pos = player:getPosition() if not pos then return end if not minimapWidget:isDragging() then if not fullmapView then minimapWidget:setCameraPosition(player:getPosition()) end minimapWidget:setCrossPosition(player:getPosition()) end end function toggleFullMap() if not fullmapView then fullmapView = true minimapWindow:hide() minimapWidget:setParent(modules.game_interface.getRootPanel()) minimapWidget:fill('parent') minimapWidget:setAlternativeWidgetsVisible(true) else fullmapView = false minimapWidget:setParent(minimapWindow:getChildById('contentsPanel')) minimapWidget:fill('parent') minimapWindow:show() minimapWidget:setAlternativeWidgetsVisible(false) end local zoom = oldZoom or 0 local pos = oldPos or minimapWidget:getCameraPosition() oldZoom = minimapWidget:getZoom() oldPos = minimapWidget:getCameraPosition() minimapWidget:setZoom(zoom) minimapWidget:setCameraPosition(pos) end
  2. Manda seu minimap.lua ai
  3. 🔥 Serviços para Poketibia – Sistemas, Correções e Mapeamento 🔥 Ofereço serviços especializados para servidores de Poketibia, garantindo qualidade, eficiência e inovação para o seu projeto! 💻 Serviços Disponíveis ✅ Correção de Bugs (servidor e cliente OTC). ✅ Melhoria e Otimização de Sistemas. ✅ Criação de Sistemas Personalizados. ✅ Serviços de Mapper (edição e criação de mapas). ⚡ Sistemas Prontos para Entrega ✔ Plantação em House. ✔ Berry Pot System. ✔ Tickets de Bônus (EXP & CATCH). ✔ Zorua System. ✔ Sistema de Bônus de Captura para cada Pokébola (OTP). ⚠ Atendo apenas servidores baseados em TFS 0.3.6! 🚀 Precisa de um sistema sob medida ou suporte técnico? Entre em contato e leve seu servidor para o próximo nível!
  4. Amigo testa meu script ai de roleta de itens talvez te ajude local config = { effect = 341, -- efeito em cima do jogador effectReward = 246, -- efeito em cima do premio effectLever = 241, -- efeito em cima da alavanca eventCoin = 2160, -- valor para jogar qtdCoin = 300, -- quantidade do coin para jogar. lose = true, -- se ira ter a opção de não ganhar nada itemLose = 2638, -- id do item que representara a perca (Obs: não se esqueça de adiciona-lo a lista de items) effectLose = 342, -- efeito em cima do premio quando perder exaust = 10.0, -- Segundos de exaust storage = 23111, -- Storage do exaust used = 2, -- Tempo da duração da roleta used_storage = 23112, -- Storage pra verificar se a roleta esta sendo usada used = 10, poss = { [1] = {x = 797, y = 2707, z = 7}, -- Coloque a coordenada da POS1 no Map Editor [2] = {x = 797, y = 2706, z = 7}, -- Coloque a coordenada da POS2 no Map Editor [3] = {x = 797, y = 2705, z = 7}, -- Coloque a coordenada da POS3 no Map Editor - local do premio [4] = {x = 797, y = 2704, z = 7}, -- Coloque a coordenada da POS4 no Map Editor [5] = {x = 797, y = 2703, z = 7} -- Coloque a coordenada da POS5 no Map Editor }, items = { -- id = id do item - chance = chance de aparecer o item - count = a quantidade de item que a pessoa ira ganhar [1] = {id = 13088, chance = 2, count = 1}, [2] = {id = 2183, chance = 2, count = 1}, [3] = {id = 12618, chance = 2, count = 1}, [4] = {id = 11441, chance = 15, count = 5}, [5] = {id = 2160, chance = 2, count = 1}, [6] = {id = 15441, chance = 2, count = 1}, [7] = {id = 11449, chance = 10, count = 5}, [8] = {id = 10503, chance = 1, count = 1}, [9] = {id = 12939, chance = 2, count = 31}, [10] = {id = 13394, chance = 2, count = 1}, [11] = {id = 11449, chance = 4, count = 1}, [12] = {id = 12196, chance = 10, count = 1}, [13] = {id = 2638, chance = 100, count = 10}, } } local slot1, slot2, slot3, slot4, slot5 local function cleanTile(item, i) doCleanTile(config.poss[i], true) doCreateItem(item, 1, config.poss[i]) end local function raffle(item) if slot4 ~= nil then slot5 = slot4 cleanTile(1617, 5) doCreateItem(slot5.id, slot5.count, config.poss[5]) end if slot3 ~= nil then slot4 = slot3 cleanTile(1617, 4) doCreateItem(slot4.id, slot4.count, config.poss[4]) end if slot2 ~= nil then slot3 = slot2 cleanTile(1485, 3) doCreateItem(slot3.id, slot3.count, config.poss[3]) end if slot1 ~= nil then slot2 = slot1 cleanTile(1617, 2) doCreateItem(slot2.id, slot2.count, config.poss[2]) end slot1 = {id = item.id, count = item.count} cleanTile(1617, 1) doCreateItem(slot1.id, slot1.count, config.poss[1]) end local function result(uid) if isPlayer(uid) then if config.lose and slot3.id == config.itemLose then doSendMagicEffect(getCreaturePosition(uid), CONST_ME_POFF) doSendMagicEffect(config.poss[3], config.effectLose) doPlayerSendTextMessage(uid, MESSAGE_STATUS_CONSOLE_BLUE, "[ROLETA] Que azar, tente novamente!.") else doSendMagicEffect(getCreaturePosition(uid), config.effect) doSendMagicEffect(config.poss[3], config.effectReward) doPlayerSendTextMessage(uid, MESSAGE_STATUS_CONSOLE_BLUE, "[ROLETA] Voce ganhou " .. slot3.count .. " " .. getItemNameById(slot3.id) .. ". Parabens!") doPlayerAddItem(uid, slot3.id, slot3.count) end end end function onUse(cid, item, pos, itemEx, posEx) if item.itemid == 1945 then doTransformItem(item.uid, item.itemid + 1) end if item.itemid == 1946 then doTransformItem(item.uid, item.itemid - 1) end if getGlobalStorageValue(config.used_storage) <= os.time() then if not exhaustion.check(cid, config.storage) then if getPlayerItemCount(cid, config.eventCoin) >= config.qtdCoin then local rand = math.random(10, 30) doSendMagicEffect(pos, config.effectLever) setGlobalStorageValue(config.used_storage, rand + 5 + os.time()) exhaustion.set(cid, config.storage, rand) doPlayerRemoveItem(cid, config.eventCoin, config.qtdCoin) local loop = 0 slot1 = nil slot2 = nil slot3 = nil slot4 = nil slot5 = nil for i = 1, #config.poss do if i == 3 then cleanTile(1485, i) else cleanTile(1617, i) end end while rand >= loop do local roll = math.random(1, 100) index = math.random(#config.items) if roll <= config.items[index].chance then local item = config.items[index] loop = loop + 1 addEvent(raffle, loop * 1000, item) end end addEvent(result, (rand + 2) * 1000, cid) else doSendMagicEffect(getCreaturePosition(cid), CONST_ME_POFF) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[ROLETA] Voce precisa ter " .. config.qtdCoin .. " " .. getItemNameById(config.eventCoin) .. " na BP!.") end else doSendMagicEffect(fromPosition, CONST_ME_POFF) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Exhaustion, aguarde " .. exhaustion.get(cid, config.storage) .. " segundos para usar a roleta novamente!") return false end return true else doSendMagicEffect(getCreaturePosition(cid), CONST_ME_POFF) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "[ROLETA] Sorteio em andamento, espere finalizar para iniciar outro.") end end Em actions.xml coloca isso <action uniqueid="43578" event="script" value="nome do seu arquivo .lua"/>
  5. 🔥 Serviços para Poketibia – Sistemas, Correções e Mapeamento 🔥 Ofereço serviços especializados para servidores de Poketibia, garantindo qualidade, eficiência e inovação para o seu projeto! 💻 Serviços Disponíveis ✅ Correção de Bugs (servidor e cliente OTC). ✅ Melhoria e Otimização de Sistemas. ✅ Criação de Sistemas Personalizados. ✅ Serviços de Mapper (edição e criação de mapas). ⚡ Sistemas Prontos para Entrega ✔ Plantação em House. ✔ Berry Pot System. ✔ Tickets de Bônus (EXP & CATCH). ✔ Zorua System. ✔ Sistema de Bônus de Captura para cada Pokébola (OTP). ⚠ Atendo apenas servidores baseados em TFS 0.3.6! 🚀 Precisa de um sistema sob medida ou suporte técnico? Entre em contato e leve seu servidor para o próximo nível!
  6. manda o script da spell que quer deixa sem delay
  7. Noob

    Npc Saga

    Testa ai amigo 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 temp_Saga2 = 10 -- tempo em minutos local g_stor_Saga2 = 5000 local function saga2V(cid) if isCreature(cid) and isInRange(getCreaturePosition(cid), {x= 2273, y=3666, z= 7}, {x= 2351, y=3742, z= 7}) then doTeleportThing(cid,{x= 2050, y=2095, z= 7}) setPlayerSaga(cid, 2, 1) doPlayerSendTextMessage(cid,22,"Seu tempo acabou") end end function onCreatureSay(cid, type, msg) if (getDistanceToCreature(cid) > 1) then return true end local talkUser = NPCHANDLER_CONVbehavior == CONVERSATION_DEFAULT and 0 or cid local msg = string.lower(msg) if msgcontains(msg, "hi") then if not (getPlayerSaga(cid, 2, 1) or getPlayerSaga(cid, 5, 1) or getPlayerSaga(cid, 8, 1)) then sendNpcDialog(cid, getNpcCid(), "[SAGA SYSTEM] Não posso falar com você neste momento", {"Fechar"}) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) return true end local sagaTable = { [2] = {"Olá " .. getCreatureName(cid) .. " Vejo que você se tornou um genin recentemente. Para começar a fazer missões, você precisa treinar primeiro.", "Treinar"}, [5] = {"Olá " .. getCreatureName(cid) .. " O chakra do Gaara durante o exame chunin estava fora do comum! Precisamos pará-lo!", "Deter"}, [8] = {"Sasuke foi sequestrado e está sendo levado para o covil do Orochimaru! Precisamos impedi-los!", "Parar"}, } for saga, data in pairs(sagaTable) do if getPlayerSaga(cid, saga, 1) then sendNpcDialog(cid, getNpcCid(), data[1], {"Fechar", data[2]}) break end end return true end if isInArray({"treino", "treinar", "training", "train"}, msg) and getPlayerSaga(cid, 2, 1) then sendNpcDialog(cid, getNpcCid(), "Para concluir o treino, basta me derrotar e pegar meus gizos. Você está pronto?", {"Fechar", "Pronto"}) talkState[talkUser] = 2 elseif isInArray({"yes", "pronto"}, msg) and getPlayerSaga(cid, 2, 1) and talkState[talkUser] == 2 then if getGlobalStorageValue(g_stor_Saga2) - os.time() <= 0 then sendNpcDialog(cid, getNpcCid(), "Boa Sorte!", {"Fechar"}) sendNpcDialog(cid, getNpcCid(), "Você tem "..temp_Saga2.." minutos para completar a saga", {"Fechar"}) setGlobalStorageValue(g_stor_Saga2, temp_Saga2*60 + os.time()) addEvent(saga2V, temp_Saga2*60*1000, cid) doSetCreatureOutfit(cid, {lookType = 350}, -1) doPlayerNextSaga(cid) doTeleportThing(cid, {x= 2300, y=3698, z= 7}) removeSummons(cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) else local seetime = getGlobalStorageValue(g_stor_Saga2)-os.time() local minutes, seconds = math.floor(seetime/60), seetime%60 sendNpcDialog(cid, getNpcCid(), string.format("Alguém fez esta saga recentemente. Aguarde %s minutos e %s segundos.", minutes, seconds), {"Fechar"}) end elseif isInArray({"deter", "deter-lo", "stop"}, msg) and getPlayerSaga(cid, 5, 1) then sendNpcDialog(cid, getNpcCid(), "Tem certeza que pode fazer isso? O Gaara pode ser muito perigoso.", {"Fechar", "Sim"}) talkState[talkUser] = 6 elseif isInArray({"yes", "certeza", "sim"}, msg) and getPlayerSaga(cid, 5, 1) and talkState[talkUser] == 6 then doPlayerNextSaga(cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) elseif isInArray({"para", "parar", "stop"}, msg) and getPlayerStorageValue(cid, 40000) == 8 then sendNpcDialog(cid, getNpcCid(), "Precisamos de toda ajuda possível! Se quer ajudar, vá até o Shikamaru.", {"Fechar", "Ajudar"}) talkState[talkUser] = 11 elseif isInArray({"ajudar"}, msg) and getPlayerSaga(cid, 8, 1) and talkState[talkUser] == 11 then doPlayerNextSaga(cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) elseif msg == "no" then selfSay("Muito bem, genin. Volte para a academia shinobi e retorne depois!", cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
  8. 🔥 Serviços para Poketibia – Sistemas, Correções e Mapeamento 🔥 Ofereço serviços especializados para servidores de Poketibia, garantindo qualidade, eficiência e inovação para o seu projeto! 💻 Serviços Disponíveis ✅ Correção de Bugs (servidor e cliente OTC). ✅ Melhoria e Otimização de Sistemas. ✅ Criação de Sistemas Personalizados. ✅ Serviços de Mapper (edição e criação de mapas). ⚡ Sistemas Prontos para Entrega ✔ Plantação em House. ✔ Berry Pot System. ✔ Tickets de Bônus (EXP & CATCH). ✔ Zorua System. ✔ Sistema de Bônus de Captura para cada Pokébola (OTP). ⚠ Atendo apenas servidores baseados em TFS 0.3.6! 🚀 Precisa de um sistema sob medida ou suporte técnico? Entre em contato e leve seu servidor para o próximo nível!
  9. me chama privado te inforno no pv
  10. Acho que essa base foi feita em cima da base alaska eu acho ou ate da própria naja.
  11. Tem sim mais creio que grátis não ira conseguir achar.
  12. 🔥 Serviços para Poketibia – Sistemas, Correções e Mapeamento 🔥 Ofereço serviços especializados para servidores de Poketibia, garantindo qualidade, eficiência e inovação para o seu projeto! 💻 Serviços Disponíveis ✅ Correção de Bugs (servidor e cliente OTC). ✅ Melhoria e Otimização de Sistemas. ✅ Criação de Sistemas Personalizados. ✅ Serviços de Mapper (edição e criação de mapas). ⚡ Sistemas Prontos para Entrega ✔ Plantação em House. ✔ Berry Pot System. ✔ Tickets de Bônus (EXP & CATCH). ✔ Zorua System. ✔ Sistema de Bônus de Captura para cada Pokébola (OTP). 🚀 Precisa de um sistema sob medida ou suporte técnico? Entre em contato e leve seu servidor para o próximo nível!
×
  • Criar Novo...