Ir para conteúdo

jNo

Membro
  • Registro em

  • Última visita

Tudo que jNo postou

  1. Era para ser 30 minutos, mas esta sendo 16 hrs quando uso. 1 script action, ao clicar no item, recebe mensagens aleatorias como pop up a cada vez que ele clica, um total de 20 msg. local config = { rate = 2, -- Rate que vai ficar o Scroll. time = 30, -- Tempo dado pelo Scroll. storage = 20011 } local function endExpRate(cid) if not isPlayer(cid) then return end doPlayerSetRate(cid, SKILL__LEVEL, 6.0) setPlayerStorageValue(cid, config.storage, -1) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_RED, "Your extra experience time has ended.") end function onUse(cid, item, fromPosition, itemEx, toPosition) local timeLeft = getPlayerStorageValue(cid, 20011) if timeLeft > os.time() then local timeTable = os.date('*t', timeLeft - (os.time() + 3600)) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, string.format("You still have %d %s %d %s %d %s left of extra experience.", timeTable.hour, timeTable.hour > 1 and "hours" or "hour", timeTable.min, timeTable.min > 1 and "minutes" or "minute", timeTable.sec, timeTable.sec > 1 and "seconds" or "second")) return true end doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, string.format("Your extra experience rate is now: %d. It will last for %d hours.", config.rate, config.time)) doPlayerSetRate(cid, SKILL__LEVEL, config.rate) setPlayerStorageValue(cid, config.storage, os.time() + config.time * 60 * 1000) addEvent(endExpRate, config.time * 60 * 1000, cid) doRemoveItem(item.uid, 1) return true end
  2. Não encontrei! Link?
  3. Da para adicionar criaturas acima da versão 8.60, ou o limite é até 8.60 mesmo?
  4. Obrigado aos dois.
  5. ja estava, ainda não funciona
  6. Achei que já estava bem claro, mas vamos lá. No meu otserver tem um tipo de dinheiro maior que crystal (2160) que é o gold ingot (9971), 100 crystal, ou 1kk como preferir, equivale a 1 gold ingot. Nesse script, ele só vende o item por crystal coin, não reconhece o outro tipo de dinheiro, gold ingot, então por exemplo: Se o item vale 1kk, e eu comprar com crystal coin, da certo... mas se eu comprar com gold ingot, não.... E a questão da alanca, ela não muda a posição quando usada
  7. Eu entendi, mas, não tem como você por pra obrigar o player estar no x sqm pra funcionar? E outra, fazer em item, porém o item não deve sumir
  8. Amigo, você não consegue mudar uma coisa no script? tipo, eu tenho no ot dinheiro gold ingot, id 9971, fazer com que o script reconheça isso tb? pq so funciona com o crystal coin, e outra, minha alavanca é a 10030, pq ela não vai pra esquerda? Ja mudei no itens xml...
  9. Alguém pode limitar um tempo de intervalo de 5 segundos para usar a alavanca nesse script? local config = { price = 50, -- Quantidade de items necessário para comprar. count = 20, -- Quantidade que irá vender. item = 7618, -- ID do item que vai vender. need = 2160 -- ID do item necessário. } function onUse(cid, item) local pos = getCreaturePosition(cid) if item.itemid == 1945 then if doPlayerRemoveItem(cid, config.need, config.price) then doPlayerAddItem(cid, config.item, config.count) doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "Você acaba de comprar "..config.count.." "..getItemNameById(config.item)..".") doSendMagicEffect(pos, CONST_ME_MAGIC_BLUE) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "Desculpe, você precisa de ".. config.price .." ".. getItemNameById(config.need) .." para comprar.") doSendMagicEffect(pos, CONST_ME_POFF) end end return true end
  10. Esse é o em item?
  11. Vi um script num ot, achei muito interessante, você fica no X sqm e usa a alavanca, e é teleportado pra sua casa, se puder, em um action tb pra adcionar um item, mas precisa funcionar so em area pz pra nego n usar pk
  12. Funcionou, dúvida sanada, obrigado!
  13. Funcional, e em action, você consegue?
  14. @rogaforyn2 vai servir, duvidas sanadas, obrigado, reputado.
  15. Perfeito! Ja estourei os rep por hoje, fica pra amanhã, esqueço não. Sera que você consegue consertar esse?
  16. @rogaforyn2 não apresenta erros, mas quando falo pra reparar a firewalker, ele repara a soft, e quando falo pra reparar soft, n repara
  17. Falaaaaaaa, la vem eu com mais um problema! Tem como configurar para reparar firewalker boots também? E mudar para 120k ambos 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, 'soft') or msgcontains(msg, 'boots')) then selfSay('Do you want to repair your worn soft boots for 20000 gold coins?', cid) talkState[talkUser] = 1 elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 1) then if(getPlayerItemCount(cid, 10021) >= 1) then if(doPlayerRemoveMoney(cid, 20000) == TRUE) then doPlayerRemoveItem(cid, 10021, 1) doPlayerAddItem(cid, 2640) selfSay('Here you are.', cid) else selfSay('Sorry, you don\'t have enough gold.', cid) end else selfSay('Sorry, you don\'t have the item.', cid) end talkState[talkUser] = 0 elseif(msgcontains(msg, 'no') and isInArray({1}, talkState[talkUser]) == TRUE) then talkState[talkUser] = 0 selfSay('Ok then.', cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
  18. Resolveu mano, que leigo que eu sou, apesar que não fez sentido, mas resolveu, obrigado! Vou te reputar depois, acabou por hoje.
  19. @KotZletY Porra, saiu perfeito, é exatamente como eu queria, e não deu nenhum erro. Com certeza esse é o !frags mais inteligente ja feito. Obrigado.
  20. local config = { useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')), advancedFragList = getBooleanFromString(getConfigValue('advancedFragList')) } function onSay(cid, words, param, channel) if(not config.useFragHandler) then return false end local time = os.time() local times = {today = (time - 86400), week = (time - (7 * 86400))} local contents, result = {day = {}, week = {}, month = {}}, db.getResult("SELECT `pd`.`date`, `pd`.`level`, `p`.`name` FROM `player_killers` pk LEFT JOIN `killers` k ON `pk`.`kill_id` = `k`.`id` LEFT JOIN `player_deaths` pd ON `k`.`death_id` = `pd`.`id` LEFT JOIN `players` p ON `pd`.`player_id` = `p`.`id` WHERE `pk`.`player_id` = " .. getPlayerGUID(cid) .. " AND `k`.`unjustified` = 1 AND `pd`.`date` >= " .. (time - (30 * 86400)) .. " ORDER BY `pd`.`date` DESC") if(result:getID() ~= -1) then repeat local content = { name = result:getDataString("name"), level = result:getDataInt("level"), date = result:getDataInt("date") } if(content.date > times.today) then table.insert(contents.day, content) elseif(content.date > times.week) then table.insert(contents.week, content) else table.insert(contents.month, content) end until not result:next() result:free() end local size = { day = table.maxn(contents.day), week = table.maxn(contents.week), month = table.maxn(contents.month) } if(config.advancedFragList) then local result = "Frags gained today: " .. size.day .. "." if(size.day > 0) then for _, content in ipairs(contents.day) do result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level end result = result .. "\n" end result = result .. "\nFrags gained this week: " .. (size.day + size.week) .. "." if(size.week > 0) then for _, content in ipairs(contents.week) do result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level end result = result .. "\n" end result = result .. "\nFrags gained this month: " .. (size.day + size.week + size.month) .. "." if(size.month > 0) then for _, content in ipairs(contents.month) do result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level end result = result .. "\n" end local skullEnd = getPlayerSkullEnd(cid) if(skullEnd > 0) then result = result .. "\nYour " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd) end doPlayerPopupFYI(cid, result) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You currently have " .. size.day .. " frags today, " .. (size.day + size.week) .. " this week and " .. (size.day + size.week + size.month) .. " this month.") if(size.day > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Last frag at " .. os.date("%d %B %Y %X", contents.day[1].date) .. " on level " .. contents.day[1].level .. " (" .. contents.day[1].name .. ").") end local skullEnd = getPlayerSkullEnd(cid) if(skullEnd > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Your " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd)) end end return true end
  21. Mas no script e vocations xml ja ta configurado '-' Você começa Druid, ai usando, !promotion, deveria ir pra Elder Druid, depois !promotion de novo, deveria ir pra Special Elder Druid
  22. Não existe, a parte de baixo eu que criei como exemplo de como deveria ficar. Só existe ate isso: 13:05 You currently have 2 frags today, 2 this week and 2 this month. 13:05 Last frag at 12 March 2017 13:03:11 on level 1041 (Peso).
  23. Então, essa action, quando não tem frags, você clica no item, e "diz que funciona", porém, quando você esta com frags e skull, "fica pofando, saindo fumaça no char, mas nao remove skull nem frags". E uma talk, !removefrags, que rouba 20kk do player, mas remove todos os frags, e tira skull. tfs 0.4 -- [( Script created by Matheus for TibiaKing.com )] -- function onUse(cid, item, fromPosition, item2, toPosisition) local rskulls = {green = SKULL_GREEN, red = SKULL_RED, black = SKULL_BLACK} if isInArray(rskulls, getPlayerSkullType(cid)) then doPlayerSendCancel(cid,"You don't remover your frags and skulls.") doSendMagicEffect(getPlayerPosition(cid), 2) else db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. getPlayerGUID(cid) .. ")") doCreatureSetSkullType(cid, 0) doCreatureSay(cid, "Your frags and skulls is cleaned!", 19) doSendMagicEffect(getPlayerPosition(cid), 26) doRemoveItem(item.uid, 1) return TRUE end end

Informação Importante

Confirmação de Termo