Ir para conteúdo

mullino

Membro
  • Registro em

  • Última visita

Tudo que mullino postou

  1. mullino postou uma resposta no tópico em Suporte Tibia OTServer
    boa noite galerinha do TK estou com um erro no meu evento. toda vez que vai iniciar ele da esse erro [Erro] Tower tentou ser iniciado ja ligado, favor verificar o codigo. (Roksas). [Erro] Tower tentou ser iniciado ja ligado, favor verificar o codigo. (Roksas). [Erro] Tower tentou ser iniciado ja ligado, favor verificar o codigo. (Roksas). Voces podem me ajudar a resolver?? ele funciona normal abre e funciona normal mas fica dando esse erro da distro. GRANTOWER = {} GRANTOWER.PREPARETIME = 2 -- Tempo até liberar a entrada para o evento. GRANTOWER.CLOSETIME = 15 -- Tempo em minutos de duração do evento. GRANTOWER.LEVEL = 80 -- Mínimo de level para participar do evento. GRANTOWER.MAXGUILD = 7 -- Máximo de players por guild dentro do evento. GRANTOWER.DATES = {{"Monday", "19:30"}, {"Tuesday", "19:30"}, {"Wednesday", "19:30"}, {"Thursday", "19:30"}, {"Friday", "19:30"}, {"Saturday", "19:30"}, {"Sunday", "19:30"}} -- Dias e horários que ocorrem o evento. GRANTOWER.ENTER = {x = 1183, y = 2284, z = 9} -- A posição da entrada do castelo, aonde os players são mandados pelo NPC. GRANTOWER.TOWERPOSITION = {x = 1188, y = 2255, z = 6} -- Posição aonde fica o Gran Tower (o monstro). GRANTOWER.AREA = {{x = 1168, y = 2230, z = 9}, {x = 1207, y = 2288, z = 6}} --[[A primeira posição é o canto superior esquerdo do mapa do castelo, e a segunda é o canto direito inferior OBSERVAÇÃO IMPORTANTE: O script foi modificado por mim (xWhiteWolf) para aguentar diferentes andares, apenas coloque a posição dos cantos e o primeiro até o ultimo andar que ele irá remover todo mundo em todos os andares quando alguém matar a gran tower, pra remover isso apenas coloque o z do mesmo andar da gran tower e apenas os membros que estão nesse andar serão teleportados, contudo isso pode ocasionar que pessoas consigam ficar dentro do castelo mesmo após o evento ter sido encerrado!]] GRANTOWER.AURAPERCENT = 0.8 --- porcentagem do dano que irá levar (0.8 = 80%) significa que ele ignora 20% de dano! (adicionado por xWhiteWolf) GRANTOWER.SHURIAURA = true --- colocar true/false se quiser ativar/desativar a aura de shurikens pro player que tem a gran aura. (adicionado por xWhiteWolf) --// Favor não mexer daqui para baixo se não souber oque está fazendo!!! GRANTOWER.EMPTYWINNER = "# [Nobody] #" GRANTOWER.PREPARE = 201405051746 GRANTOWER.RUNNING = 201405051747 GRANTOWER.AURA = 201405052018 GRANTOWER.DESTROYCOUNT = 201405051800 GRANTOWER.FINALWINNER = 201405051805 GRANTOWER.SAVELASTWINNER = 201405061333 GRANTOWER.SAVEWINNERGUILDID = 201405061403 function doPrepareGranTower() if ((getGlobalStorageValue(GRANTOWER.PREPARE) ~= 1) and (getGlobalStorageValue(GRANTOWER.RUNNING) ~= 1)) then setGlobalStorageValue(GRANTOWER.PREPARE, 1) addEvent(doStartGranTower, GRANTOWER.PREPARETIME * 60 * 1000) addEvent(doBroadcastMessage, ((GRANTOWER.PREPARETIME / 2) * 60 * 1000), "[Gran Tower] Missing "..tostring((GRANTOWER.PREPARETIME / 2)).." minutes NPC Melkrapo will release the entrance to the event, get ready!") doBroadcastMessage("[Gran Tower] The event will be started in "..tostring(GRANTOWER.PREPARETIME).." minutes, please prepare your weapons and your team.") else print("[Erro] Gran Tower tentou ser iniciado ja ligado, favor verificar o codigo. (Roksas).") end return true end function doStartGranTower() if ((getGlobalStorageValue(GRANTOWER.PREPARE) ~= -1) and (getGlobalStorageValue(GRANTOWER.RUNNING) ~= 1)) then setGlobalStorageValue(GRANTOWER.RUNNING, 1) setGlobalStorageValue(GRANTOWER.PREPARE, -1) setGlobalStorageValue(GRANTOWER.SAVEWINNERGUILDID, -1) setGlobalStorageValue(GRANTOWER.FINALWINNER, GRANTOWER.EMPTYWINNER) setGlobalStorageValue(GRANTOWER.SAVELASTWINNER, GRANTOWER.EMPTYWINNER) setGlobalStorageValue(GRANTOWER.DESTROYCOUNT, 0) doCreateMonster("Gran Tower", GRANTOWER.TOWERPOSITION) addEvent(doBroadcastMessage, ((GRANTOWER.CLOSETIME - 1) * 60 * 1000), "[Gran Tower] The event will be closed in one minute. Hurry up!") addEvent(doCloseGranTower, GRANTOWER.CLOSETIME * 60 * 1000) doBroadcastMessage("[Gran Tower] Open event! Run to destroy the Gran Tower.") else print("[Erro] Gran Tower tentou ser iniciado já ligado, favor verificar o código.") end return true end function doCloseGranTower() if ((getGlobalStorageValue(GRANTOWER.PREPARE) ~= 1) and (getGlobalStorageValue(GRANTOWER.RUNNING) ~= -1)) then for index, creature in ipairs(getGranTowerPlayers()) do doTeleportThing(creature, getTownTemplePosition(getPlayerTown(creature))) end for index, creature in ipairs(getPlayersOnline()) do if (getPlayerGuildId(creature) >= 1) then if getPlayerGuildId(creature) ~= getGlobalStorageValue(GRANTOWER.SAVEWINNERGUILDID) then setPlayerStorageValue(creature, GRANTOWER.AURA, -1) end end end setGlobalStorageValue(GRANTOWER.RUNNING, -1) if (getCreatureByName("Gran Tower")) then doRemoveCreature(getCreatureByName("Gran Tower"), true) end local TMP_WINNER = getGlobalStorageValue(GRANTOWER.FINALWINNER) doBroadcastMessage("[Gran Tower] The event was completed with "..tostring(getGlobalStorageValue(GRANTOWER.DESTROYCOUNT)).." wrecks to Gran Tower, the final winner was "..(TMP_WINNER)..".") setGlobalStorageValue(GRANTOWER.DESTROYCOUNT, -1) setGlobalStorageValue(GRANTOWER.SAVELASTWINNER, TMP_WINNER) setGlobalStorageValue(GRANTOWER.FINALWINNER, -1) local TMP_WINNER = nil end return true end function getGranTowerPlayers() -- xWhiteWolf local players = {} local andares = math.abs(GRANTOWER.AREA[1].z - GRANTOWER.AREA[2].z) for index, creature in ipairs(getPlayersOnline()) do local z = 0 local pos1 = {x = GRANTOWER.AREA[1].x, y = GRANTOWER.AREA[1].y, z = GRANTOWER.AREA[1].z} local pos2 = {x = GRANTOWER.AREA[2].x, y = GRANTOWER.AREA[2].y, z = GRANTOWER.AREA[2].z} for i = 0, andares do z = z or 0 pos1.z = pos1.z > pos2.z and pos2.z + z or pos1.z + z pos2.z = pos1.z z = 1 if isInArea(getThingPos(creature), pos1, pos2) then table.insert(players, creature) end end end return players end function getGranTowerGuild(guild_id) -- xWhiteWolf local players = {} local andares = math.abs(GRANTOWER.AREA[1].z - GRANTOWER.AREA[2].z) for index, creature in ipairs(getPlayersOnline()) do local z = 0 local pos1 = {x = GRANTOWER.AREA[1].x, y = GRANTOWER.AREA[1].y, z = GRANTOWER.AREA[1].z} local pos2 = {x = GRANTOWER.AREA[2].x, y = GRANTOWER.AREA[2].y, z = GRANTOWER.AREA[2].z} for i = 0, andares do z = z or 0 pos1.z = pos1.z > pos2.z and pos2.z + z or pos1.z + z pos2.z = pos1.z z = 1 if isInArea(getThingPos(creature), pos1, pos2) then if (getPlayerGuildId(creature) == guild_id) then table.insert(players, creature) end end end end return players end -- // Gran Aura \/ function newColor(n) local n = tonumber(n) or 0 local n = n + 19 return tonumber(n) or 0 end function newColor(n) local n = tonumber(n) or 132 local n = n - 19 return tonumber(n) or 132 end -- comentario: se a cor for preta o addon vai para branco sendo que o certo é diminuir 19.. local events = {} function changeOutfit(uid) -- arrumado por xWhiteWolf e adicionado a opção da Shuri local sec = 0.5 local temp = getCreatureOutfit(uid) if (type(temp) == "number") then return true end if getGlobalStorageValue(GRANTOWER.SAVELASTWINNER) ~= getCreatureName(uid) then if getGlobalStorageValue(GRANTOWER.SAVEWINNERGUILDID) ~= getPlayerGuildId(uid) then return true end end if GRANTOWER.SHURIAURA then local pos = getCreaturePosition(uid) local effectPos = { [1] = {x = pos.x - 2, y = pos.y - 2, z = pos.z}, [2] = {x = pos.x + 2, y = pos.y + 2, z = pos.z} } for i = 1, #effectPos do position = effectPos[i + 1] or effectPos[i - 1] doSendDistanceShoot(effectPos[i], position, 27) end end local outfit = { lookType = temp.lookType, lookHead = newColor(temp.lookHead), lookBody = newColor(temp.lookBody), lookLegs = newColor(temp.lookLegs), lookFeet = newColor(temp.lookFeet), lookAddons = getCreatureOutfit(uid).lookAddons, } doSetCreatureOutfit(uid, outfit, sec) local event = addEvent(function() if isCreature(uid) then changeOutfit(uid) end end, 3.0 * sec * 450) events[uid] = event return true end
  2. fragsLimit = 12 * 60 * 60 fragsSecondLimit = 1 * 24 * 60 * 60 fragsThirdLimit = 1 * 24 * 60 * 60 fragsToRedSkull = 60 fragsSecondToRedSkull = 700 fragsThirdToRedSkull = 3800 redSkullLength = 1 * 24 * 60 * 60 fragsToBlackSkull = 500 fragsSecondToBlackSkull = 3500 fragsThirdToBlackSkull = 14000 blackSkulledDeathHealth = 40 blackSkulledDeathMana = 0 blackSkullLength = 2 * 24 * 60 * 60 useBlackSkull = true notationsToBan = 3 warningsToFinalBan = 4 warningsToDeletion = 5 banLength = 7 * 24 * 60 * 60 killsBanLength = 7 * 24 * 60 * 60 finalBanLength = 30 * 24 * 60 * 60 ipBanLength = 2 * 24 * 60 * 60 fragsToBanishment = 7 fragsSecondToBanishment = 21 fragsThirdToBanishment = 41 troca essa parte
  3. qual sua verçao?
  4. Boa tarde galerinha do TK Descobri um bug na minha distro tem como vcs me ajudarem? Nas potions Quando o player está healando no Elf bot com potions Se ele estiver heal ele não consegue fazer nada enquanto não acabar de healar Não consegue abrir bp. Não consegue deslogar Puxar ring Achei que era no spells . Mas fui na minha Source e tirei o exaust todo das spells aí testei tá normal mas quando fui testar as potions descobri que e nela meu problema. Alguém pode me ajudar resolver isso. Obrigado
  5. Já está add mas não mostrava Mostrava sim no serve log Não saia de cima do player a quantidade
  6. mullino postou uma resposta no tópico em Suporte Tibia OTServer
    boa noite galerinha do tk mais uma vez venho pedir a ajuda de vcs em um sitema de raid que deu erro [Error - TalkAction Interface] data/talkactions/scripts/killuaRaidSystem2.0.lua:onSay Description: data/lib/killuaRaidSystem2.0.lua:44: bad argument #2 to 'random' (interval is empty) stack traceback: [C]: in function 'random' data/lib/killuaRaidSystem2.0.lua:44: in function 'summon' data/lib/killuaRaidSystem2.0.lua:52: in function 'start' data/talkactions/scripts/killuaRaidSystem2.0.lua:15: in function <data/talkactions/scripts/killuaRaidSystem2.0.lua:1> --[[ Sistema de invasões automáticas Desenvolvido por Vítor Bertolucci (Killua) ]] killuaRaids = {} killuaRaids.raids = { {name = "Aladdins", city = "Baiak New", monsters = {"Aladdin"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, {name = "Escaravelhos", city = "Baiak New", monsters = {"Escaravelho"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, {name = "Ghalapagos", city = "Baiak New", monsters = {"Ghalapago"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, {name = "Ghalapagos", city = "Baiak New", monsters = {"Ghalapago"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, {name = "Escaravelhos", city = "Baiak New", monsters = {"Escaravelho"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, {name = "Aladdins", city = "Baiak New", monsters = {"Aladdin"}, fromTo = { {{x=164,y=57,z=7},{x=176,y=39,z=7}},{{x=169,y=40,z=7},{x=156,y=57,z=7}}, {{x=139,y=41,z=7},{x=173,y=57,z=7}}, {{x=161,y=32,z=7},{x=138,y=60,z=7}},{{x=179,y=59,z=7},{x=132,y=23,z=7}},{{x=173,y=33,z=7},{x=178,y=27,z=7}},{{x=181,y=22,z=7},{x=197,y=39,z=7}},{{x=208,y=40,z=7},{x=208,y=50,z=7}},{{x=204,y=62,z=7},{x=194,y=57,z=7}},{{x=178,y=67,z=7},{x=104,y=61,z=7}},{{x=102,y=54,z=7},{x=103,y=46,z=7}},{{x=153,y=61,z=7},{x=96,y=41,z=7}},{{x=83,y=39,z=7},{x=110,y=34,z=7}},{{x=132,y=47,z=7},{x=138,y=54,z=7}} } }, } killuaRaids.messages = { "Uma legião de @ está invadindo #, corram para proteger a cidade!", "Um grupo de @ foi visto adentrando #, é uma invasão!", "@ estão invadindo #, corram para salvar a cidade!" } killuaRaids.sort = function() return killuaRaids.raids[math.random(#killuaRaids.raids)] end killuaRaids.warn = function(message,times) local time = times - 1 if time == 0 then return end doBroadcastMessage(message) addEvent(killuaRaids.warn,10000,message,time) end killuaRaids.summon = function(raid,times) local time = times - 1 if time == 0 then return end local fromTo = raid.fromTo[math.random(#raid.fromTo)] local position = {x = math.random(fromTo[1].x, fromTo[2].x), y = math.random(fromTo[1].y, fromTo[2].y), z = fromTo[1].z} doCreateMonster(raid.monsters[math.random(#raid.monsters)],position) doSendMagicEffect(position,CONST_ME_FIREAREA) addEvent(killuaRaids.summon,500,raid,time) end killuaRaids.start = function(raid) killuaRaids.warn(killuaRaids.messages[math.random(#killuaRaids.messages)]:gsub("@",raid.name):gsub("#",raid.city),10) killuaRaids.summon(raid,1000) end des de ja agradeço a ajuda de vcs Ajuda @Vodkart
  7. @Sttorm muito obrigado mano funcionou certinho como sempre os seus codigos me ajudou bastante.. sem palavras para agradecer... obrigado mesmo irmao
  8. local config = { removeOnUse = "false", usableOnTarget = "yes", -- can be used on target? (fe. healing friend) splashable = "no", realAnimation = "yes", -- make text effect visible only for players in range 1x1 healthMultiplier = 1.4, manaMultiplier = 1.4 } local bonus = 1.15 config.removeOnUse = getBooleanFromString(config.removeOnUse) config.usableOnTarget = getBooleanFromString(config.usableOnTarget) config.splashable = getBooleanFromString(config.splashable) config.realAnimation = getBooleanFromString(config.realAnimation) local POTIONS = { [8704] = {empty = 7636, splash = 2, percentHealth = 2, percentMana = 0, health = {50, 100}}, -- small health potion [7618] = {empty = 7636, splash = 2, percentHealth = 3, percentMana = 0, health = {250, 450}}, -- health potion [7588] = {empty = 7634, splash = 2, percentHealth = 4, percentMana = 0, health = {200, 400}, level = 1, vocations = {3, 4, 7, 8, 11, 12}, vocStr = "knights and paladins"}, -- strong health potion [7591] = {empty = 7635, splash = 2, percentHealth = 10, percentMana = 0, health = {500, 700}, level = 1, vocations = {4, 8, 12}, vocStr = "knights"}, -- great health potion [8473] = {empty = 7635, splash = 2, percentHealth = 14, percentMana = 0, health = {1250, 1490}, level = 1, vocations = {4, 8, 12}, vocStr = "knights"}, -- ultimate health potion [7620] = {empty = 7636, splash = 7, percentHealth = 0, percentMana = 10, mana = {250, 400}, vocations = {4, 8, 12}, vocStr = "knights"}, -- mana potion [7589] = {empty = 7634, splash = 7, percentHealth = 0, percentMana = 4, mana = {110, 190}, level = 1, vocations = {1, 2, 3, 5, 6, 7, 9, 10, 11}, vocStr = "sorcerers, druids and paladins"}, -- strong mana potion [7590] = {empty = 7635, splash = 7, percentHealth = 0, percentMana = 8, mana = {855, 1030}, level = 1, vocations = {1, 2, 5, 6, 9, 10}, vocStr = "sorcerers and druids"}, -- great mana potion [8472] = {empty = 7635, splash = 3, percentMana = 6, percentHealth = 18, health = {1150, 1250}, mana = {415, 615}, level = 1, vocations = {3, 7, 11}, vocStr = "paladins"} -- great spirit potion } local exhaust = createConditionObject(CONDITION_EXHAUST) setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 100)) function onUse(cid, item, fromPosition, itemEx, toPosition) local potion = POTIONS[item.itemid] if(not potion) then return false end if(not isPlayer(itemEx.uid) or (not config.usableOnTarget and cid ~= itemEx.uid)) then if(not config.splashable) then return false end if(toPosition.x == CONTAINER_POSITION) then toPosition = getThingPos(item.uid) end doDecayItem(doCreateItem(2016, potion.splash, toPosition)) doTransformItem(item.uid, potion.empty) return true end if(hasCondition(cid, CONDITION_EXHAUST_HEAL)) then doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED) return true end if(((potion.level and getPlayerLevel(cid) < potion.level) or (potion.vocations and not isInArray(potion.vocations, getPlayerVocation(cid)))) and not getPlayerCustomFlagValue(cid, PLAYERCUSTOMFLAG_GAMEMASTERPRIVILEGES)) then doCreatureSay(itemEx.uid, "Only " .. potion.vocStr .. (potion.level and (" of level " .. potion.level) or "") .. " or above may drink this fluid.", TALKTYPE_ORANGE_1) return true end local health = potion.health local added_health = math.ceil(((potion.percentHealth / 100) * getCreatureMaxHealth(cid) ) * config.healthMultiplier) added_health = potion.percentHealth == 0 and 0 or math.random(added_health - 80, added_health + 90) if(health and not doCreatureAddHealth(itemEx.uid, added_health)) then return false end local mana = potion.mana local added_mana = math.ceil(( (potion.percentMana / 100) * getCreatureMaxMana(cid) ) * config.manaMultiplier) added_mana = potion.percentMana == 0 and 0 or math.random(added_mana - 80, added_mana + 90) if(mana and not doPlayerAddMana(itemEx.uid, added_mana)) then return false end if isInArray({8704, 7618, 7588, 7591, 8473}, item.itemid) then doSendAnimatedText(getPlayerPosition(cid), "Ahhhh...", 180) elseif isInArray({7620, 7589, 7590, 8472}, item.itemid) then doSendAnimatedText(getPlayerPosition(cid), "Ahhhh...", 17) end doSendMagicEffect(getThingPos(itemEx.uid), 30) if realAnimation then for i, tid in ipairs(getSpectators(getCreaturePosition(cid), 1, 1)) do if(isPlayer(tid)) then end end end doAddCondition(cid, exhaust) if(not potion.empty or config.removeOnUse) then doRemoveItem(item.uid, 1) return true end end esse ai amigo @Sttorm
  9. Boa noite galerinha do TK Venho mais uma vez pedir a ajuda de vcs sobre um script de potions eu tenho um que mostra a quantidade que esta healando mas nao quero usar ele o que eu quero usar nao mostra a quantidade que esta healando alguem de coraçao bom pode me mostrar onde altero pra que ele mostre a quantidade de heal script que mostra quanto ta healando local config = { removeOnUse = "no", usableOnTarget = "yes", -- can be used on target? (fe. healing friend) splashable = "yes", range = -1, area = {1, 1} -- if not set correctly, the message will be sent only to user of the item } local multiplier = { health = 1.0, mana = 1.0 } local POTIONS = { [8704] = {empty = 8704, splash = 42, rate = 0.5,}, -- small health potion [7618] = {empty = 7618, splash = 42, rate = 0.5}, -- health potion [7588] = {empty = 7588, splash = 42, rate = 1.0, level = 50, vocations = {3, 4, 7, 8, 11, 12}, vocStr = "knights and paladins"}, -- strong health potion [7591] = {empty = 7591, splash = 42, rate = 1.1, level = 80, vocations = {4, 8, 12}, vocStr = "knights"}, -- great health potion [8473] = {empty = 8473, splash = 42, rate = 1.3, level = 130, vocations = {4, 8, 12}, vocStr = "knights"}, -- ultimate health potion [7620] = {empty = 7620, splash = 47, rateMana = 0.2}, -- mana potion [7589] = {empty = 7589, splash = 47, rateMana = 1.3, level = 50, vocations = {1, 2, 3, 5, 6, 7}, vocStr = "sorcerers, druids and paladins"}, -- strong mana potion [7590] = {empty = 7590, splash = 47, rateMana = 1.5, level = 80, vocations = {1, 2, 5, 6, 9, 10}, vocStr = "sorcerers and druids"}, -- great mana potion [8472] = {empty = 8472, splash = 43, rate = 0.8, rateMana = 0.8, level = 80, vocations = {3, 7, 11}, vocStr = "paladins"} -- great spirit potion } for index, potion in pairs(POTIONS) do if(type(index) == 'number')then for k, v in pairs(config) do if(not potion[k]) then potion[k] = v end end if(potion.removeOnUse) then potion.removeOnUse = getBooleanFromString(potion.removeOnUse) end if(potion.usableOnTarget) then potion.usableOnTarget = getBooleanFromString(potion.usableOnTarget) end if(potion.splashable) then potion.splashable = getBooleanFromString(potion.splashable) end if(type(potion.health) == 'table' and table.maxn(potion.health) > 1) then potion.health[1] = math.ceil(potion.health[1] * multiplier.health) potion.health[2] = math.ceil(potion.health[2] * multiplier.health) else potion.health = nil end if(type(potion.mana) == 'table' and table.maxn(potion.mana) > 1) then potion.mana[1] = math.ceil(potion.mana[1] * multiplier.mana) potion.mana[2] = math.ceil(potion.mana[2] * multiplier.mana) else potion.mana = nil end POTIONS[index] = potion end end -------------------------------- local exh_sto = 93939 -- Storage. local exh_time = 0.5 -- Segundos. -------------------------------- function onUse(cid, item, fromPosition, itemEx, toPosition) -------------------------------- if getCreatureStorage(cid, exh_sto) > os.time() then return doPlayerSendCancel(cid, "Exhaustion!!") end -------------------------------- local potion = POTIONS[item.itemid] if(not potion) then return false end if(not isPlayer(itemEx.uid) or (not potion.usableOnTarget and cid ~= itemEx.uid)) then if(not potion.splashable or not potion.splash) then return false end if(toPosition.x == CONTAINER_POSITION) then toPosition = getThingPosition(item.uid) end return true end if(((potion.level and getPlayerLevel(itemEx.uid) < potion.level) or (potion.vocations and not isInArray(potion.vocations, getPlayerVocation(itemEx.uid)))) and not getPlayerCustomFlagValue(cid, PLAYERCUSTOMFLAG_GAMEMASTERPRIVILEGES)) then doCreatureSay(itemEx.uid, "Only " .. potion.vocStr .. (potion.level and (" of level " .. potion.level) or "") .. " or above may drink this fluid.", TALKTYPE_MONSTER, false, cid) return true end if(potion.range > 0 and cid ~= itemEx.uid and getDistanceBetween(getThingPosition(cid), getThingPosition(itemEx.uid)) > potion.range and not getPlayerCustomFlagValue(cid, PLAYERCUSTOMFLAG_CANUSEFAR)) then doPlayerSendDefaultCancel(cid, RETURNVALUE_TOOFARAWAY) return true end local playerlevel = getPlayerLevel(itemEx.uid) if(potion.rateMana and not doTargetCombatMana(0, itemEx.uid, playerlevel*potion.rateMana, playerlevel*potion.rateMana, CONST_ME_MAGIC_BLUE)) then return false end if(potion.rate and not doTargetCombatHealth(0, itemEx.uid, COMBAT_HEALING, playerlevel*potion.rate, playerlevel*potion.rate, CONST_ME_MAGIC_BLUE)) then return false end -------------------------------- doCreatureSetStorage(cid, exh_sto, exh_time+os.time()) -------------------------------- if(type(potion.area) == 'table' and table.maxn(potion.area) > 1) then for i, tid in ipairs(getSpectators(getThingPosition(itemEx.uid), potion.area[1], potion.area[2])) do if(isPlayer(tid)) then doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_MONSTER, false, tid) end end else doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_MONSTER, false, itemEx.uid) if(itemEx.uid ~= cid) then doCreatureSay(itemEx.uid, "Aaaah...", TALKTYPE_MONSTER, false, cid) end end return true end e aqui o que nao mostra quanto que esta healando local config = { removeOnUse = "false", usableOnTarget = "yes", -- can be used on target? (fe. healing friend) splashable = "no", realAnimation = "yes", -- make text effect visible only for players in range 1x1 healthMultiplier = 1.4, manaMultiplier = 1.7 } local bonus = 1.15 config.removeOnUse = getBooleanFromString(config.removeOnUse) config.usableOnTarget = getBooleanFromString(config.usableOnTarget) config.splashable = getBooleanFromString(config.splashable) config.realAnimation = getBooleanFromString(config.realAnimation) local POTIONS = { [8704] = {empty = 7636, splash = 2, percentHealth = 2, percentMana = 0, health = {50, 100}}, -- small health potion [7618] = {empty = 7636, splash = 2, percentHealth = 3, percentMana = 0, health = {250, 450}}, -- health potion [7588] = {empty = 7634, splash = 2, percentHealth = 4, percentMana = 0, health = {200, 400}, level = 1, vocations = {3, 4, 7, 8, 11, 12}, vocStr = "knights and paladins"}, -- strong health potion [7591] = {empty = 7635, splash = 2, percentHealth = 10, percentMana = 0, health = {500, 700}, level = 1, vocations = {4, 8, 12}, vocStr = "knights"}, -- great health potion [8473] = {empty = 7635, splash = 2, percentHealth = 14, percentMana = 0, health = {1250, 1490}, level = 1, vocations = {4, 8, 12}, vocStr = "knights"}, -- ultimate health potion [7620] = {empty = 7636, splash = 7, percentHealth = 0, percentMana = 10, mana = {250, 400}, vocations = {4, 8, 12}, vocStr = "knights"}, -- mana potion [7589] = {empty = 7634, splash = 7, percentHealth = 0, percentMana = 4, mana = {110, 190}, level = 1, vocations = {1, 2, 3, 5, 6, 7, 9, 10, 11}, vocStr = "sorcerers, druids and paladins"}, -- strong mana potion [7590] = {empty = 7635, splash = 7, percentHealth = 0, percentMana = 8, mana = {855, 1030}, level = 1, vocations = {1, 2, 5, 6, 9, 10}, vocStr = "sorcerers and druids"}, -- great mana potion [8472] = {empty = 7635, splash = 3, percentMana = 6, percentHealth = 18, health = {1150, 1250}, mana = {415, 615}, level = 1, vocations = {3, 7, 11}, vocStr = "paladins"} -- great spirit potion } local exhaust = createConditionObject(CONDITION_EXHAUST) setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions') - 100)) function onUse(cid, item, fromPosition, itemEx, toPosition) local potion = POTIONS[item.itemid] if(not potion) then return false end if(not isPlayer(itemEx.uid) or (not config.usableOnTarget and cid ~= itemEx.uid)) then if(not config.splashable) then return false end if(toPosition.x == CONTAINER_POSITION) then toPosition = getThingPos(item.uid) end doDecayItem(doCreateItem(2016, potion.splash, toPosition)) doTransformItem(item.uid, potion.empty) return true end if(hasCondition(cid, CONDITION_EXHAUST_HEAL)) then doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED) return true end if(((potion.level and getPlayerLevel(cid) < potion.level) or (potion.vocations and not isInArray(potion.vocations, getPlayerVocation(cid)))) and not getPlayerCustomFlagValue(cid, PLAYERCUSTOMFLAG_GAMEMASTERPRIVILEGES)) then doCreatureSay(itemEx.uid, "Only " .. potion.vocStr .. (potion.level and (" of level " .. potion.level) or "") .. " or above may drink this fluid.", TALKTYPE_ORANGE_1) return true end local health = potion.health local added_health = math.ceil(((potion.percentHealth / 100) * getCreatureMaxHealth(cid) ) * config.healthMultiplier) added_health = potion.percentHealth == 0 and 0 or math.random(added_health - 80, added_health + 90) if(health and not doCreatureAddHealth(itemEx.uid, added_health)) then return false end local mana = potion.mana local added_mana = math.ceil(( (potion.percentMana / 100) * getCreatureMaxMana(cid) ) * config.manaMultiplier) added_mana = potion.percentMana == 0 and 0 or math.random(added_mana - 80, added_mana + 90) if(mana and not doPlayerAddMana(itemEx.uid, added_mana)) then return false end if isInArray({8704, 7618, 7588, 7591, 8473}, item.itemid) then doSendAnimatedText(getPlayerPosition(cid), "Ahhhh...", 180) elseif isInArray({7620, 7589, 7590, 8472}, item.itemid) then doSendAnimatedText(getPlayerPosition(cid), "Ahhhh...", 17) end doSendMagicEffect(getThingPos(itemEx.uid), 30) if realAnimation then for i, tid in ipairs(getSpectators(getCreaturePosition(cid), 1, 1)) do if(isPlayer(tid)) then end end end doAddCondition(cid, exhaust) if(not potion.empty or config.removeOnUse) then doRemoveItem(item.uid, 1) return true end end alguem pode ajudar ?? e sim no config lua ja esta abilitado igual eu falei com o potions do primeiro script ele mostra helando normal a quantidade mas ja com o segundo ele so mostra o efeito " haaaa " e nao mostra a quantidade que esta healando.
  10. sim toda quest da uma storage, dai e so vc colocar o tile da area que vc quer que passe , somente que tem a storage daquela quest ...bem melhor q fazer item pra passar... ou faz uma quest valendo um item que au dar use ganhe acesso aquela area colocando no tile tbm. igual uma area vip..
  11. </instant> <instant name="Haste" words="utani hur" lvl="14" mana="60" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="6" needlearn="0" event="script" value="support/haste.lua"/> <instant name="Charge" words="utani tempo hur" lvl="25" mana="100" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="131" needlearn="0" event="script" value="support/charge.lua"> <vocation id="4;8;12"/> </instant> <instant name="Swift Foot" words="utamo tempo san" lvl="55" mana="400" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="1,1000" icon="134" needlearn="0" event="script" value="support/swift foot.lua"> <vocation id="3;7;11"/> </instant> <instant name="Challenge" words="exeta res" lvl="20" mana="30" prem="1" aggressive="0" exhaustion="1000" groups="3,1000" icon="93" needlearn="0" event="script" value="support/challenge.lua"> <vocation id="8"/><vocation id="12"/> </instant> <instant name="Strong Haste" words="utani gran hur" lvl="20" mana="100" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="39" needlearn="0" event="script" value="support/strong haste.lua"> <vocation id="1;5;9"/> <vocation id="2;6;10"/> </instant> <instant name="Ultimate Light" words="utevo vis lux" lvl="26" mana="140" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="75" needlearn="0" event="script" value="support/ultimate light.lua"> <vocation id="1;5;9"/> <vocation id="2;6;10"/> </instant> <instant name="Cancel Invisibility" words="exana ina" lvl="26" mana="200" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="90" needlearn="0" event="script" value="support/cancel invisibility.lua"> <vocation id="3;7;11"/> </instant> <instant name="Invisibility" words="utana vid" lvl="35" mana="440" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="45" needlearn="0" event="script" value="support/invisible.lua"> <vocation id="1;5;9"/> <vocation id="2;6;10"/> <vocation id="3;7;11"/> </instant> <instant name="Sharpshooter" words="utito tempo san" lvl="60" mana="450" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="2,1000" icon="135" needlearn="0" event="script" value="support/sharpshooter.lua"> <vocation id="3;7;11"/> </instant> <instant name="Protector" words="utamo tempo" lvl="55" mana="200" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="1,1000" icon="132" needlearn="0" event="script" value="support/protector.lua"> <vocation id="4;8;12"/> </instant> <instant name="Blood Rage" words="utito tempo" lvl="60" mana="290" prem="1" aggressive="0" selftarget="1" exhaustion="1000" groups="3,1000" icon="133" needlearn="0" event="script" value="support/blood rage.lua"> <vocation id="4;8;12"/> </instant>
  12. bom dia galerinha do TK gostaria da ajuda de voces para entender essas spells por group pq estou colocando as minhas spells por group mas eu nao entendo essa parte groups="4,2000" icon="62" quais spells se encaixa ne nesse group groups="4,2000" "1,5000" "3,1000" "1,1000" e pra que serve esse icon= "62 " ? qual a funçao dele na spells ? obrigado
  13. mullino postou uma resposta no tópico em Suporte Tibia OTServer
    Boa noite galerinha do TK Descobri um bug na minha distro tem como vcs me ajudarem? No exaust Quando o player está healando com magia no Elf bot e com potions Se ele estiver usando esses heal ele não consegue fazer nada enquanto não acabar de healar Não consegue abrir bp . Não consegue usar outro tipo de magias Não consegue deslogar Puxar ring Nada disso funciona se ele estiver healando .... Pesquisei na Aki no fórum e algumas pessoas falaram que é na source , mas não achei nada para modificar.... Alguém pode me ajudar a resolver esse problema!?
  14. ja fiz issu usei 2 db e nada mas vou tentar de novo
  15. Bom dia Galerinha DO TK estou com um erro no meu site toda vez que clico na aba VIEW SHOP OFFER (EDIT/DELETE) da um erro Could not load Items! Ajudem por favor
  16. boa noite galerinha do TK eu tenho um sistema de vip no meu ot Feito pelo nosso amigo @Vodkart function getCharacterAcess(cid) local query = db.getResult("SELECT `vipacess` FROM `players` WHERE `id` = "..getPlayerGUID(cid)) if query:getID() ~= -1 then return query:getDataInt("vipacess") end end function getCharacterDays(cid) local acess = math.ceil((getCharacterAcess(cid) - os.time())/(86400)) return acess <= 0 and 0 or acess end function HaveCharaterAcess(cid) return getCharacterDays(cid) > 0 and true or false end function setAcessTime(cid, time) return db.executeQuery("UPDATE `players` SET `vipacess` = "..time.." WHERE `id` = "..getPlayerGUID(cid)) end function addCharacterAcess(cid, days) local add = (days <= 0 and 1 or days)*86400 local time = getCharacterDays(cid) == 0 and (os.time() + add) or (getCharacterAcess(cid) + add) return setAcessTime(cid, time) end function doRemoveCharacterAcess(cid, days) local remove = days*86400 local time = getCharacterAcess(cid) - remove return setAcessTime(cid, (time <= 0 and 1 or time)) end function getVipAcessDate(cid) if HaveCharaterAcess(cid) then return os.date("%d/%m/%y %X", getCharacterAcess(cid)) end return false end ele funciona normal perfeito... exceto por nao mostrar no site que o player é vip, mostra free account queria que quando o player usase o item que da a vip pra ele. function onUse(cid, item, fromPosition, itemEx, toPosition) local days = 30 addCharacterAcess(cid, (days <= 0 and 1 or days)) doRemoveItem(item.uid) return doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você tem "..getCharacterDays(cid).." dias de VIP, ela acaba em "..getVipAcessDate(cid)) end no site tbm mostrasse que ele é vip e ao inver de mostrar assim..... mostrasse Player Vip. obrigado desde ja
  17. @Vodkart opa bleza?? vc fez esse sistema gostaria de saber se tem como colocar para aparecer no site que o player é vip?? pq nao aparece no site quando clico nao... mostra q o player é free queria que mostrasse vip
  18. divine scape e de trocar de lugar um player com o outro muito util no x1 A Divine Bash: ela dá um dano referente ao Skill e Level do Player e dá um Stun de 2 segundos. A Divine Scape: Ela apenas troca de lugar com um player que está como Target, essa magia nao pode ser utilizada em monstros pq poderiam sair de traps facil em quests
  19. obrigado + Rep ai mano pode ajudar com mais uma @alisonrenna pode ajudar com mais essa aki [Error - Spell Interface] data/spells/scripts/attack/divine scape.lua:onCastSpell Description: (luaGetThingPosition) Thing not found [Error - Spell Interface] data/spells/scripts/attack/divine scape.lua:onCastSpell Description: (luaGetThingPosition) Thing not found script---- function onCastSpell(cid, var) local jogadorpos = getCreaturePosition(cid) local target = getCreatureTarget(cid) local monsterpos = getCreaturePosition(target) if target and isPlayer(target) then doTeleportThing(cid,monsterpos) doTeleportThing(target,jogadorpos) doSendMagicEffect(jogadorpos, 65) doSendMagicEffect(monsterpos, 65) else doPlayerSendTextMessage(cid,20,'Nao e possivel usar essa magia em monstros.') end return true end tem outra tbm [Error - Spell Interface] data/spells/scripts/attack/divine bash.lua:onCastSpell Description: (luaDoTargetCombatCondition) Creature not found [Error - Spell Interface] data/spells/scripts/attack/divine bash.lua:onCastSpell Description: (luaDoCreatureSetNoMove) Creature not found script local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, true) setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1) setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatFormula(combat, COMBAT_FORMULA_SKILL, 5, 0, 5, 0) function onCastSpell(cid, var) local exhausted = createConditionObject(CONDITION_EXHAUST) setConditionParam(exhausted, CONDITION_PARAM_TICKS,4000) local target = variantToNumber(var) doTargetCombatCondition(0, target, exhausted, CONST_ME_MAGIC_RED) doCreatureSetNoMove(target, true) addEvent(doCreatureSetNoMove, 2000, target, false) return doCombat(cid, combat, var) end
  20. ok vou tentar deu certo oooo
  21. boa tarde galerinha do tk estou com um erro nas minhas spells alguem pode me ajudar [Error - Spell Interface] data/spells/scripts/attack/divine scape.lua:onCastSpell Description: (luaGetThingPosition) Thing not found [Error - Spell Interface] data/spells/scripts/attack/divine scape.lua:onCastSpell Description: (luaGetThingPosition) Thing not found script---- function onCastSpell(cid, var) local jogadorpos = getCreaturePosition(cid) local target = getCreatureTarget(cid) local monsterpos = getCreaturePosition(target) if target and isPlayer(target) then doTeleportThing(cid,monsterpos) doTeleportThing(target,jogadorpos) doSendMagicEffect(jogadorpos, 65) doSendMagicEffect(monsterpos, 65) else doPlayerSendTextMessage(cid,20,'Nao e possivel usar essa magia em monstros.') end return true end tem outra tbm [Error - Spell Interface] data/spells/scripts/attack/divine bash.lua:onCastSpell Description: (luaDoTargetCombatCondition) Creature not found [Error - Spell Interface] data/spells/scripts/attack/divine bash.lua:onCastSpell Description: (luaDoCreatureSetNoMove) Creature not found script local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, true) setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1) setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatFormula(combat, COMBAT_FORMULA_SKILL, 5, 0, 5, 0) function onCastSpell(cid, var) local exhausted = createConditionObject(CONDITION_EXHAUST) setConditionParam(exhausted, CONDITION_PARAM_TICKS,4000) local target = variantToNumber(var) doTargetCombatCondition(0, target, exhausted, CONST_ME_MAGIC_RED) doCreatureSetNoMove(target, true) addEvent(doCreatureSetNoMove, 2000, target, false) return doCombat(cid, combat, var) end ajudem por favor @Vodkart
  22. vou testar aki agora certinho brother sera que eu tinha copiado o outro e achando que foi o ultimo?? resolvido pode fexar o topico brothe obrigado
  23. copiei mano olha la como ta local tpId = 1387 local pos, topos = {x=151, y=40, z=7},{x=95, y=182, z=7} function onSay(cid,words,param,channel) local t = getTileItemById(pos, tpId) if param == "close" then if t then doRemoveItem(t.uid, 1) doSendMagicEffect(pos, CONST_ME_POFF) doBroadcastMessage("O teleporte [Dice Event] foi fechado!") else doPlayerSendCancel(cid, "Desculpe, mas nao tem nenhum teleport no momento.") end return true end doCreateTeleport(tpId, topos, pos) doBroadcastMessage("Dice Event O teleport para o dice event está aberto perto do NPC Gran Tower!!") return true end so tirei a outra parte
  24. mesma coisa fala descupe mas ja existe um tp criado

Informação Importante

Confirmação de Termo