Ir para conteúdo

PedroSTT

Banido
  • Registro em

  • Última visita

Tudo que PedroSTT postou

  1. Isso acontece pq seu servidor tem limite de 255 effects
  2. Source além de ser uma gambiarra , contém traps e foi jogada em cima de um servidor com mais erros ainda ... tópico denunciado.
  3. PedroSTT postou uma resposta no tópico em Action, MoveEvent, TalkAction & Spell
    Olá galera , do TibiaKing , venho trazer pra vocês um bike sistem por movements. QUAL A DIFERENÇA DESSE SISTEMA PARA O ANTIGO ? ( POR ACTIONS) Esse sistema evita aquele famoso bug do player dar use na bike e jogar pra outro amigo dar use , fazendo os dois terem bike. COMO ESSE SISTEMA FUNCIONA ?? Funciona por movements , ao equipar( no slot do ring[configurável]) ganha a outfit e a speed ( configuráveis) XML <movevent type="Equip" itemid="2195" slot="ring" event="script" value="bike.lua"/> <movevent type="DeEquip" itemid="2195" slot="ring" event="script" value="bike.lua"/> SCRIPT local bike = {lookType = 100, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0} --- Esse vai ser Homen local bike1 = {lookType = 101, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0} --- Esse vai ser mulher local speed = 20 --- Velocidade que a bike dará local storage = 3421 function onEquip(cid, item, slot) if not isPlayer(cid) and not isPremium(cid) then -- tire o primeiro not, atras do isPlayer para ativar o premium doPlayerSendCancel(cid, "Only premium members are allowed to mount.") return true end if getPlayerSex(cid) == 1 then -- Homem doChangeSpeed(cid, speed) doSetCreatureOutfit(cid, bike, -1) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, storage, 1) elseif getPlayerSex(cid) == 0 then -- Girl doChangeSpeed(cid, speed) doSetCreatureOutfit(cid, bike1, -1) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, storage, 1) end return true end function onDeEquip(cid, item, slot) doRemoveCondition(cid, CONDITION_OUTFIT) doChangeSpeed(cid, -speed) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, storage, 0) end
  4. function onUse(cid, item, frompos, itemEx, topos) local bike = {lookType = 738, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0} --- Esse vai ser Homen local bike1 = {lookType = 737, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0} --- Esse vai ser mulher local speed = 20 --- Velocidade que a bike terá. if isPlayer(cid) and not isPremium(cid) and premium == true then doTeleportThing(cid, fromPosition, false) doPlayerSendCancel(cid, "Only premium accounts can mount.") return true end if item.uid ~= getPlayerSlotItem(cid, CONST_SLOT_RING).uid then doPlayerSendCancel(cid, "Put in the correct slot.") return true end if getPlayerStorageValue(cid, 17001) == 1 or getPlayerStorageValue(cid, 63215) == 1 or getPlayerStorageValue(cid, 17000) == 1 then doPlayerSendCancel(cid, "Dismount your pokemon to ride.") return true end if getPlayerStorageValue(cid, 32001) == 1 then doRemoveCondition(cid, CONDITION_OUTFIT) doChangeSpeed(cid, -speed) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, 32001, -1) else local base = getCreatureBaseSpeed(cid) if getPlayerSex(cid) == 1 then -- homem doChangeSpeed(cid, base + speed) doSetCreatureOutfit(cid, bike, -1) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, 32001, 1) elseif getPlayerSex(cid) == 0 then -- homem doChangeSpeed(cid, base + speed) doSetCreatureOutfit(cid, bike1, -1) doSendMagicEffect(getPlayerPosition(cid), 18) setPlayerStorageValue(cid, 32001, 1) end end return true end
  5. local storage = 3234 local horas = 24 -- tempo para pegar dnv em horas local tabela = {2160, 2152, 2148} -- ID dos itens. function onUse(cid, item, frompos, item2, topos) if getPlayerStorageValue(cid, config.storage) >= os.time() then doPlayerSendTextMessage(cid,25, "voce so pode pegar a cada 24 horas") return true end setPlayerStorageValue(cid, config.storage, os.time() + horas * 3600000 ) doPlayerAddItem(cid, tabela[math.random(#tabela)], 1) doSendMagicEffect(getCreaturePosition(cid), 2) doPlayerSendTextMessage(cid,25, "voce recebeu seu premio") return true end
  6. Já testei em meu próprio otserver , a ultima script que postei aqui está funcionando 100%.
  7. function Normal(cid) local vel = 200 -- velocidade que o player ganhou ao usar a Spell doChangeSpeed(cid, -vel) end function onCastSpell(cid, var) local mninja = {lookType = 377, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local fninja = {lookType = 368, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local second = 10000 local speed = 200 local sex = getPlayerSex(cid) local tempo = 10 -- segundos para voltar a speed normal if sex == 0 then doSetCreatureOutfit(cid, fninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) else doSetCreatureOutfit(cid, mninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) end return true end
  8. function Normal(cid) doRegainSpeedLevel(cid) end function onCastSpell(cid, var) local mninja = {lookType = 377, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local fninja = {lookType = 368, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local second = 10000 local speed = 200 local sex = getPlayerSex(cid) local tempo = 10 -- segundos para voltar a speed normal if sex == 0 then doSetCreatureOutfit(cid, fninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) else doSetCreatureOutfit(cid, mninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) end return true end
  9. local storage = 243656 -- Coloque a Storage Que Controla o Sistema de Bike function onDeEquip(cid, item, slot) if getPlayerStorageValue(cid, storage) = 1 then doPlayerSendCancel(cid, "Voce nao pode remover a bike enquanto esta montado.") return false end end
  10. function Normal(cid) local base = getCreatureBaseSpeed(cid) doChangeSpeed(cid, base) end function onCastSpell(cid, var) local mninja = {lookType = 377, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local fninja = {lookType = 368, lookHead = 0, lookBody = 0, lookLegs = 0, lookFeet = 0, lookTypeEx = 0, lookAddons = 3} local second = 10000 local speed = 200 local sex = getPlayerSex(cid) local tempo = 10 -- segundos para voltar a speed normal if sex == 0 then doSetCreatureOutfit(cid, fninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) else doSetCreatureOutfit(cid, mninja, second) doChangeSpeed(cid, speed) addEvent(Normal, tempo * 1000, cid) end return true end
  11. Yes, it is action, but it is not for 5 players and nor does it summon any monster, each player to be teleported has to pull the lever once every 24 hours
  12. local config = { storage = 9844, -- storage days = 1 -- days to use a lever } function onUse(cid, item, frompos, item2, topos) local teleport = {x=986, y=926, z=7} -- Coordinates to where the player will be teleported. if getPlayerStorageValue(cid, config.storage) >= os.time() then doPlayerSendTextMessage(cid,25, string.format('You can teleport after %d day%s', config.days, config.days ~= 1 and "s" or "")) return true end doPlayerSendTextMessage(cid, 25, string.format('Congratulations! You you are teleported, you can get your item after %d day%s', config.days, config.days ~= 1 and "s" or "")) setPlayerStorageValue(cid, config.storage, os.time() + config.days * 86400) doTeleportThing(cid, teleport) doSendMagicEffect(getCreaturePosition(cid), 2) return true end
  13. Como a script não é da TFS 1.3 , não ia funcionar mesmo. Tentei adaptar , teste a script function onLogin(cid) creature:registerEvent(cid, "EffectOutLogin") creature:registerEventt(cid, "OutfitEffects") return creature:setOutfit(cid,{lookType = creature:getOutfit(cid).lookType, lookHead = creature:getOutfit(cid).lookHead, lookBody = creature:getOutfit(cid).lookBody, lookLegs = creature:getOutfit(cid).lookLegs, lookFeet = creature:getOutfit(cid).lookFeet, lookAddons = creature:getOutfitt(cid).lookAddons}) end local events = {} function onOutfit(cid, old, current) local effect = { [136] = 3, [128] = 3, -- citizen [270] = 27,[273] = 27, -- jester [156] = 61,[152] = 61, -- assassin [147] = 44,[143] = 44, -- barbarian [148] = 45,[144] = 45, -- druid [157] = 68,[153] = 68, -- beggar [149] = 36,[145] = 36, -- wizard [279] = 65,[278] = 65, -- brotherwood [137] = 39,[129] = 39, -- hunter [141] = 66,[133] = 66, -- summoner [142] = 34,[134] = 34, -- warrior [155] = 31,[151] = 31, -- pirate [158] = 46,[154] = 46, -- shaman [288] = 6,[289] = 6 -- demonhunter } local o,c= effect[old.lookType],effect[current.lookType] if group:getAccess()()(cid) > 2 then return true end function WalkEffect(cid, c, pos) if not creature:isCreature(cid) then return LUA_ERROR end if c then frompos = getThing(cid) if frompos.x ~= pos.x or frompos.y ~= pos.y or frompos.z ~= pos.z then position:sendMagicEffect(frompos, c) end events[player:getGuid()(cid)] = addEvent(WalkEffect, 100, cid, c, frompos) end return true end WalkEffect(cid, c, {x=0, y=0, z=0}) return true end
  14. PedroSTT postou uma resposta no tópico em Suporte Tibia OTServer
    XML <event type="think" name="Slot" event="script" value="slot.lua"/> Script local config = { tempo = 5, --tempo em segundos texto = "[TOP]", --não use mais de 9 caracteres efeito = TEXTCOLOR_LIGHTBLUE --efeito para a função doSendAnimatedText } function Effect(cid) doSendAnimatedText(getCreaturePosition(cid), config.texto, config.efeito) end function onThink(cid, interval) local slot = { head = 2474, -- ID do item que ficara no Slot Head armor = 2503, -- ID do item que ficara no Slot Armor legs = 2504, -- ID do item que ficara no Slot Legs boots = 2195, -- ID do item que ficara no Slot Boots ring = 2164 -- ID do item que ficara no Slot Ring } if getPlayerSlotItem(cid, 1).itemid == slot.head then if getPlayerSlotItem(cid, 4).itemid == slot.armor then if getPlayerSlotItem(cid, 7).itemid == slot.legs then if getPlayerSlotItem(cid, 8).itemid == slot.boots then if getPlayerSlotItem(cid, 9).itemid == slot.ring then addEvent(Effect, config.tempo * 1000, cid) end end end end end end Registrar no login.lua registerCreatureEvent(cid, "Slot")
  15. 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 local config = { count = 1, -- qnt do item que ira receber item = 9942, -- item que ira receber sto = 10000 -- Storage } if(msgcontains(msg, 'yes' or 'sim' )) then if getPlayerStorageValue(cid, config.sto) == 1 then local name = getItemNameById(config.item) doPlayerAddItem(cid, config.item, config.count) doPlayerSendTextMessage(cid, 27, "voce recebeu "..config.count.." "..name.." .") else doPlayerSendTextMessage(cid, 27, "voce precisa ter a storage") end return false end end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
  16. @Hokograma Não precisa repetir a script não , basta preencher as colunas.
  17. @Hokograma Pelo o que eu percebi , o ID dos itens não estão iguais nas scripts , esse é o erro no vai.lua local id = 8302 -- Id do edo pergaminho no pega.lua local id = 8301 -- Id do outro pergaminho que conterá o summon Entendeu ? nas 2 script , coloque o ID do pergaminho que conterá o edo tensei.
  18. O problema já foi resolvido no private.
  19. @Hokograma Pelo oque eu vi, você se esqueceu de configurar essa parte if item.itemid == 11390 then Coloque o ID do pergaminho que contem o [EDO TENSEI] Madara.
  20. @Hokograma Atualizei novamente as scrits , LEMBRANDO QUE OS ITENS PARA FAZER O EDO TENSEI TEM QUE SER DE ID'S diferentes. Sobre os bugs que você falou que ocorreu com você , testei em minha própria base e está 100%; configure corretamente.
  21. @Hokograma , Obrigado pelo report , o bug ja foi corrigido. Mude for edo_tensei, v in pairs(mtrs) do Para for edo_tensei, v in pairs(edo) do
  22. -------- Exaust config local waittime = 1.5 -- Tempo de exhaustion local storage = 250002 -------- Exaust Config local tempo = 4 -- tempo em segundos. local outfit = {lookType = 645, lookHead = 0, lookBody = 114, lookLegs = 114, lookFeet = 114, lookTypeEx = 0, lookAddons = 3} -- Outfit local effect = {5} -- effect no player, caso queira apenas 1, basta remover os outros numeros. local health = 9999999999999999999 -- A cada 1 segundo quantos aumentar de vida local text = 'IMORTAL!!' local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0) local condition = createConditionObject(CONDITION_REGENERATION) setConditionParam(condition, CONDITION_PARAM_SUBID, 1) setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE) setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000) setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, 50000000000000000) setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 500) setConditionParam(condition, CONDITION_PARAM_OUTFIT, outfit) setCombatCondition(combat, condition) local sys = createConditionObject(CONDITION_OUTFIT) setConditionParam(sys, CONDITION_PARAM_TICKS, tempo*50000) addOutfitCondition(sys, outfit) setCombatCondition(combat, sys) if exhaustion.check(cid, storage) then doPlayerSendCancel(cid, "You are exhausted") return false end function magicEffect9(tempo9,tempo9,cid) if (isCreature(cid)) then if getCreatureCondition(cid, CONDITION_REGENERATION, 1) then for i=1, #effect do local position = {x=getPlayerPosition(cid).x+0, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z} doSendMagicEffect(position, effect) doSendAnimatedText(getCreaturePos(cid), text, TEXTCOLOR_RED) doSetCreatureOutfit(cid, outfit, -1) end end end end local cooldown = 19 function onCastSpell99(cid) doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "CD: Jashin ritual.") end function onCastSpell(cid, var) if getPlayerStorageValue(cid, 10569) == 1 then doSendAnimatedText((getCreaturePosition(cid)), "Socorro!", 255) doSendMagicEffect(getCreaturePosition(cid), 19) doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED) return false elseif getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then doCombat(cid, combat, var) tempo9 = 0 while (tempo9 ~= (tempo*1500)) do addEvent(onCastSpell99, cooldown*10000, cid) addEvent(magicEffect9, tempo9, tempo9, tempo*1500, cid) addEvent(doRemoveCondition, tempo*1000, cid, CONDITION_OUTFIT) tempo9 = tempo9 + 1500 end doCreatureSay(cid, "Jashin RITUAL!", TALKTYPE_MONSTER) else doPlayerSendCancel(cid, "Desculpe, Mais você ainda está com efeito da magia.") end end
  23. function onStepIn(cid, item, position, fromPosition) local level = 500 if not isMonster(cid) then if getPlayerLevel(cid) <= level then doTeleportThing(cid, fromPosition, true) doSendMagicEffect(getThingPos(cid), CONST_ME_MAGIC_RED) doPlayerSendCancel(cid,"Somente Vip Players level " .. level .. " ou mais podem passar aqui.") return true end end end

Informação Importante

Confirmação de Termo