Ir para conteúdo

Featured Replies

Postado

Opaaa eaew....
tem como adaptar essa spell para seguinte função....

Não puxar os mobs....
Não dar outfit....
Causar dano no local onde os misseis são disperçados....
 

Spoiler

elseif spell == "Air Vortex" then

    local config = {
        outfit = 1406,              --Outfit.
        time = {10, 500},           --{Duração da spell, intervalo entre cada "tick" de dano (em milésimos de segundos)},
        storage = 93828,
        effects = {
            pullEffects = {
                distance = 9,     --Distance effect do efeito de puxar pokémons.
                effect = 41,       --Efeito de tornado.
            },
            damageEffect = 41,     --Efeito do redemoinho que aplica dano.
        },
    }
    elseif spell == "Overheat" then

    local config = {
        time = {10, 500},           --{Duração da spell, intervalo entre cada "tick" de dano (em milésimos de segundos)},
        storage = 93828,
        effects = {
            pullEffects = {
                distance = 118,     --Distance effect do efeito de puxar pokémons.
                effect = 514,       --Efeito de tornado.
            },
            damageEffect = 515,     --Efeito do redemoinho que aplica dano.
        },
    }
    local time = os.time() + config.time[1]
    function Pull(cid, ret)
        local pos = getPosfromArea(cid, pullArea)
        if pos and #pos > 0 then
            for i = 1, #pos do
                local c = getTopCreature(pos).uid
                if c > 0 then
                    if ehMonstro(c) then
                        doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                    elseif isSummon(c) then
                        local master = getCreatureMaster(c)
                        if isSummon(cid) then
                            if getPlayerStorageValue(master, 52480) >= 1 and getPlayerStorageValue(master, 52481) >= 0 then
                                local masterCid = getCreatureMaster(cid)
                                if isDuelingAgainst(masterCid, master) then
                                    doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                                end
                            end
                        else
                            doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                        end
                    end
                end
            end
        end
    end
    function doSendTornado(cid, pos)
        if not isCreature(cid) then return true end
        if isWithFear(cid) and getPlayerStorageValue(cid, 3644587) >= 1 then return true end
        if isSleeping(cid) and getPlayerStorageValue(cid, 3644587) >= 1 then return true end
        doSendDistanceShoot(getThingPos(cid), pos, config.effects.pullEffects.distance)
        doSendMagicEffect(pos, config.effects.pullEffects.effect)
    end
    function vortexDamage(cid)
        if not isCreature(cid) then
            return true
        elseif time - os.time() < 0 then
            return true
        end
        doDanoWithProtect(cid, FIREDAMAGE, getThingPos(cid), damageArea, min, max, config.effects.damageEffect)
        addEvent(vortexDamage, config.time[2], cid)
    end
        local ret = {}
        ret.id = 0
        ret.cd = 10
        ret.check = 0
        ret.eff = 41
        ret.first = true
        ret.spell = spell
        ret.cond = "Stun"
    for b = 1, 5 do
        for a = 1, 50 do
            local pos = {x = getThingPos(cid).x + math.random(-8, 8), y = getThingPos(cid).y + math.random(-5, 5), z = getThingPos(cid).z}
            addEvent(doSendTornado, a * 50, cid, pos)
        end
    end
    Pull(cid, ret)
    vortexDamage(cid)
    setPlayerStorageValue(cid, config.storage, time)
    addEvent(function()
        if isCreature(cid) then
            doCreatureSetNoMove(cid, false)
            doRegainSpeed(cid)
        end
    end, config.time[1] * 1000)

 

 no print da pra ver certinho.... eu quero que o dano va pro quadro onde cai o 2° efeito a "bolinha" são os misseis e o "foguinho" caindo no chão e onde vai dar o dano

Nesse print eu estou tentando adaptar mas a spell não está causando dano nenhum


Config que estão fuçando

Spoiler

    elseif spell == "Overheat" then

    local config = {
        time = {10, 500},           --{Duração da spell, intervalo entre cada "tick" de dano (em milésimos de segundos)},
        storage = 93828,
        effects = {
            pullEffects = {
                distance = 118,     --Distance effect do efeito de puxar pokémons.
                effect = 514,       --Efeito de tornado.
            },
            damageEffect = 515,     --Efeito do redemoinho que aplica dano.
        },
    }
    local time = os.time() + config.time[1]
    function Pull(cid, ret)
        local pos = getPosfromArea(cid, pullArea)
        if pos and #pos > 0 then
            for i = 1, #pos do
                local c = getTopCreature(pos).uid
                if c > 0 then
                    if ehMonstro(c) then
                        doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                    elseif isSummon(c) then
                        local master = getCreatureMaster(c)
                        if isSummon(cid) then
                            if getPlayerStorageValue(master, 52480) >= 1 and getPlayerStorageValue(master, 52481) >= 0 then
                                local masterCid = getCreatureMaster(cid)
                                if isDuelingAgainst(masterCid, master) then
                                    doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                                end
                            end
                        else
                            doMoveDano2(cid, c, FIREDAMAGE, 0, 0, ret, spell)
                        end
                    end
                end
            end
        end
    end
    function doSendTornado(cid, pos)
        if not isCreature(cid) then return true end
        if isWithFear(cid) and getPlayerStorageValue(cid, 3644587) >= 1 then return true end
        if isSleeping(cid) and getPlayerStorageValue(cid, 3644587) >= 1 then return true end
        doSendDistanceShoot(getThingPos(cid), pos, config.effects.pullEffects.distance)
        doSendMagicEffect(pos, config.effects.pullEffects.effect)
    end
    function vortexDamage(cid)
        if not isCreature(cid) then
            return true
        elseif time - os.time() < 0 then
            return true
        end
        doDanoWithProtect(cid, FIREDAMAGE, getThingPos(cid), damageArea, min, max, config.effects.damageEffect)
        addEvent(vortexDamage, config.time[2], cid)
    end
        local ret = {}
        ret.id = 0
        ret.cd = 10
        ret.check = 0
        ret.eff = 41
        ret.first = true
        ret.spell = spell
        ret.cond = "Stun"
    for b = 1, 5 do
        for a = 1, 50 do
            local pos = {x = getThingPos(cid).x + math.random(-8, 8), y = getThingPos(cid).y + math.random(-5, 5), z = getThingPos(cid).z}
            addEvent(doSendTornado, a * 50, cid, pos)
        end
    end
    Pull(cid, ret)
    vortexDamage(cid)
    setPlayerStorageValue(cid, config.storage, time)
    addEvent(function()
        if isCreature(cid) then
            doCreatureSetNoMove(cid, false)
            doRegainSpeed(cid)
        end
    end, config.time[1] * 1000)

 

Print.png

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Conteúdo Similar

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.6k

Informação Importante

Confirmação de Termo