Ir para conteúdo

Líderes

Conteúdo Popular

Exibindo conteúdo com a maior reputação em 06/24/21 em todas áreas

  1. [TFS 1.3] Teleport Trashing

    Myalitth reagiu a Toruk por uma resposta no tópico

    1 ponto
    Tente: local tile = Tile(toPosition) if tile and tile:getItemByType(ITEM_TYPE_TELEPORT) then self:sendCancelMessage(RETURNVALUE_NOTPOSSIBLE) self:getPosition():sendMagicEffect(CONST_ME_POFF) return false end Se não der, tente trocar o "tile::getItemByType(ITEM_TYPE_TELEPORT)" por "tile:getItemById(1387)".
  2. [TFS 1.3] Teleport Trashing

    Myalitth reagiu a Toruk por uma resposta no tópico

    1 ponto
    Só adicionar as linhas na função "function Player:onMoveItem". local tile = Tile(toPosition):getItemByType(ITEM_TYPE_TELEPORT) if tile then self:sendCancelMessage(RETURNVALUE_NOTPOSSIBLE) self:getPosition():sendMagicEffect(CONST_ME_POFF) return false end
  3. (Action) Double Exp Global

    Enenra reagiu a Tio Rusher por uma resposta no tópico

    1 ponto
    Estou com o tempo bem apertado, mas pode usar isso como base Servidor/mods/nome.xml <?xml version="1.0" encoding="UTF-8"?> <mod name="Double Exp Global" enabled="yes" author="MatheusMkalo/Tio Rusher" forum="Xtibia/Tibia King"> <!-- Configuração --> <config name="PotionExpConfigs"><![CDATA[ ------ CONFIGURE SEU SCRIPT ------ TRUE ou FALSE configs = { time = 720, ---- Tempo em minutos needpa = FALSE, needlvl = {FALSE, level = 1}, costmana = {FALSE, mana = 1}, addrate = 100, -- Exp que vai adicionar em % removeonuse = TRUE } function getTime(s) local n = math.floor(s / 60) s = s - (60 * n) return n, s end CreatureEventChecker = function(event, ...) if isCreature(arg[1]) then event(unpack(arg)) end end creatureEvent = function(event, delay, ...) addEvent(CreatureEventChecker, delay, event, unpack(arg)) end function getPlayerExtraExpRate(cid) return (getPlayerRates(cid)[8]-1)*100 end ]]></config> <!-- exppotion.lua --> <action itemid="7440" event="script"><![CDATA[ -- ID do item domodlib('PotionExpConfigs') if getPlayerStorageValue(cid, 62164) >= 1 then doRemoveItem(item.uid, 1) return broadcastMessage("Um Double Exp foi ativado, e bla bla bla", MESSAGE_STATUS_CONSOLE_BLUE) end if configs.needpa and not isPremium(cid) then return doPlayerSendCancel(cid, "Voce precisa ser uma conta premmium para usar este item.") end if configs.needlvl[1] and getPlayerLevel(cid) < configs.needlvl.level then return doPlayerSendCancel(cid, "Voce precisa do nivel " .. configs.needlvl.level .. " para usar este item") end if configs.costmana[1] then if getCreatureMana(cid) < configs.costmana.mana then return doPlayerSendCancel(cid, "Voce precisa " .. configs.costmana.mana .. " mana para usar este item") else doCreatureAddMana(cid, -configs.costmana.mana) end end if configs.removeonuse then doRemoveItem(item.uid, 1) end for i = configs.time*60, 1, -1 do local a = math.floor(i/60) .. ":" .. i - (60 * math.floor(i/60)) if #a < 4 then a = string.sub(a,1,2) .. "0" .. string.sub(a, 3) end if i == configs.time*60 then creatureEvent(doPlayerSendCancel, configs.time*60*1000, cid, "O efeito do Elexir do Conhecimento se esgotou") end creatureEvent(doPlayerSendCancel, (configs.time*60-i)*1000, cid, "O Efeito do Elixir do conhecimento expira em: "..a.."minutos") end doPlayerSetExperienceRate(cid, (1+(configs.addrate/100))+(getPlayerExtraExpRate(cid)/100)) creatureEvent(doPlayerSetExperienceRate, configs.time *60*1000, cid, 1+(getPlayerExtraExpRate(cid)/100-(configs.addrate/100))) doPlayerSendTextMessage(cid, 22, "Agora voce esta sob o efeito do Elixir do conhecimento e ganhara double exp") setPlayerStorageValue(cid, 62164, os.time()) caixinha = creatureEvent(setPlayerStorageValue, configs.time *60*1000, cid, 62164, 0) return TRUE ]]></action> <creaturescript type="login" name="ExpPotion" event="script"><![CDATA[ domodlib('PotionExpConfigs') local time = configs.time if os.time()-getPlayerStorageValue(cid, 62164) < time *60 then doPlayerSetExperienceRate(cid, (1+(configs.addrate/100))+(getPlayerExtraExpRate(cid)/100)) creatureEvent(doPlayerSetExperienceRate, (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) * 1000, cid, 1+(getPlayerExtraExpRate(cid)/100-(configs.addrate/100))) creatureEvent(setPlayerStorageValue, (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) * 1000 , cid, 62164, 0) for i = (time*60-(os.time()-getPlayerStorageValue(cid, 62164))), 1, -1 do local a = math.floor(i/60) .. ":" .. i - (60 * math.floor(i/60)) if #a < 4 then a = string.sub(a,1,2) .. "0" .. string.sub(a, 3) end if i == (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) then creatureEvent(doPlayerSendCancel, (time*60-(os.time()-getPlayerStorageValue(cid, 62164)))*1000, cid, "O Efeito do Elixir do conhecimento chegou ao fim") end creatureEvent(doPlayerSendCancel, ((time*60-(os.time()-getPlayerStorageValue(cid, 62164)))-i)*1000, cid, "O Efeito do Elixir do conhecimento expira em: "..a.." minutos") end end return TRUE ]]></creaturescript> </mod>
  4. Duvidas Store In game

    jpma reagiu a Bruxo Ots por uma resposta no tópico

    1 ponto
    Vai em data/modules/scripts/gamestore/gamestore.lua {name = "Snow Pelt", thingId = 102, type = GameStore.OfferTypes.OFFER_TYPE_MOUNT, price = 5, icons = {"o890.png"}, description = "This mount looks so hot!"}, } Usei essa linha como exemplo, mais acho que é isso cara.....se eu entendi né.
Líderes está configurado para São Paulo/GMT-03:00

Informação Importante

Confirmação de Termo