• TibiaFace

    Tibiaface | Una comunidad Open Tibia donde encontras : mapas, scripts, Otserver, npc y amigos etc ...

    .
    demo menumenu

    Afiliados



    Votar:

    [Spells] Distance Missiles que se dispersan

    Compartir:

    Ver el tema anterior Ver el tema siguiente Ir abajo  Mensaje (Página 1 de 1.)

    1default [Spells] Distance Missiles que se dispersan el Vie Oct 23, 2020 6:52 pm

    SoyFabi

    SoyFabi
    Miembro
    Miembro
    Descripcion escribió:Buenas, estoy buscando este spells desde hace mucho tiempo, y lo encontre un Otserver pero no tengo ni idea de como se crea.

    Basicamente el spells usa los distance(Missiles) en area se dispersan en diferentes posiciones.

    Aqui les dejo un Gif de Ejemplo:

    [Spells] Distance Missiles que se dispersan Gif_1012
    Imagen Explicativa escribió:Imagen Explicativa: [Spells] Distance Missiles que se dispersan Tibiaf10
    Version del Scripts: OTx Old Version(0.3.7)

    [Admin] God Maya

    [Admin] God Maya
    Administrador
    Administrador
    Quieres algo como esto
    [code]


    First go to Data/spells/spells.xml put this
    Code:
    <instant name="Default" words="default" lvl="1" maglv="1" mana="25" exhaustion="1000" prem="0" needlearn="0" blockwalls="0" aggressive="1" event="script" value="Default.lua">
    <vocation id="1"/>
    <vocation id="2"/>
    <vocation id="3"/>
    <vocation id="4"/>
    <vocation id="5"/>
    <vocation id="6"/>
    <vocation id="7"/>
    <vocation id="8"/>
    </instant>





    Second go to Data/Spells/Scripts and make Default.lua and put this script
    Code:
    local combat0_Brush = createCombatObject()
    setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_ICEATTACK)
    setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
    setCombatArea(combat0_Brush,createCombatArea({{0, 0, 1, 0, 1, 0, 0},
    {1, 0, 1, 0, 1, 0, 1},
    {1, 0, 1, 3, 1, 0, 1},
    {1, 0, 1, 0, 1, 0, 1},
    {0, 1, 1, 0, 1, 1, 0},
    {0, 0, 0, 1, 0, 0, 0}}))
    function getDmg_Brush(cid, level, maglevel)
    return (500)*-1,(200)*-1
    end
    setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush")
    local dfcombat0_Brush = {CONST_ANI_ICE,-3,1,0,3,2,2,1,2,-1,2,-2,2,-1,1,1,1,1,0,0,0,-1,0,3,-1,3,0,-1,-1,1,-1,-3,-1,1,-2,-1,-2,3,1,-3,0}local combat0_Brush_2 = createCombatObject()
    setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_EXPLOSIONHIT)
    setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
    setCombatArea(combat0_Brush_2,createCombatArea({{0, 0, 1, 0, 1, 0, 0},
    {1, 1, 0, 1, 0, 1, 1},
    {0, 0, 0, 0, 0, 0, 0},
    {0, 0, 0, 2, 0, 0, 0},
    {0, 1, 0, 0, 0, 1, 0},
    {1, 0, 0, 1, 0, 0, 1},
    {0, 0, 1, 0, 1, 0, 0}}))
    function getDmg_Brush_2(cid, level, maglevel)
    return (400)*-1,(200)*-1
    end
    setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2")
    local dfcombat0_Brush_2 = {CONST_ANI_FIRE,-1,3,1,3,0,2,-3,2,3,-2,-2,1,2,1,-3,-2,2,-2,0,-2,-2,-2,3,2,-1,-3,1,-3}local combat0_Brush_3 = createCombatObject()
    setCombatParam(combat0_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_MORTAREA)
    setCombatParam(combat0_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
    setCombatArea(combat0_Brush_3,createCombatArea({{0, 0, 1, 0, 0},
    {0, 0, 0, 0, 0},
    {1, 0, 1, 0, 1},
    {1, 0, 2, 0, 1},
    {0, 0, 1, 0, 0}}))
    function getDmg_Brush_3(cid, level, maglevel)
    return (10)*-1,(20)*-1
    end
    setCombatCallback(combat0_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3")
    local dfcombat0_Brush_3 = {CONST_ANI_SUDDENDEATH,0,1,2,0,-2,0,-2,-1,0,-1,2,-1,0,-3}

    -- Areas/Combat for 100ms
    local combat1_Brush_4 = createCombatObject()
    setCombatParam(combat1_Brush_4, COMBAT_PARAM_EFFECT, CONST_ME_WATERSPLASH)
    setCombatParam(combat1_Brush_4, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
    setCombatArea(combat1_Brush_4,createCombatArea({{1, 1, 1, 1, 1, 1, 1},
    {1, 1, 1, 1, 1, 1, 1},
    {1, 1, 1, 3, 1, 1, 1},
    {1, 1, 1, 1, 1, 1, 1},
    {1, 1, 1, 1, 1, 1, 1}}))
    function getDmg_Brush_4(cid, level, maglevel)
    return (10)*-1,(20)*-1
    end
    setCombatCallback(combat1_Brush_4, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_4")
    local dfcombat1_Brush_4 = {CONST_ANI_ENERGYBALL,-3,-2,-2,-2,-1,-2,0,-2,1,-2,2,-2,3,-2,3,-1,2,-1,1,-1,0,-1,-1,-1,-2,-1,-3,-1,-3,0,-2,0,-1,0,0,0,1,0,2,0,3,0,3,1,2,1,1,1,0,1,-1,1,-2,1,-3,1,-3,2,-2,2,-1,2,0,2,1,2,2,2,3,2}

    -- =============== CORE FUNCTIONS ===============
    local function RunPart(c,cid,var,dirList,dirEmitPos) -- Part
    if (isCreature(cid)) then
    doCombat(cid, c, var)
    if (dirList ~= nil) then -- Emit distance effects
    local i = 2;
    while (i < #dirList) do
    doSendDistanceShoot(dirEmitPos,{x=dirEmitPos.x-dirList[i],y=dirEmitPos.y-dirList[i+1],z=dirEmitPos.z},dirList[1])
    i = i + 2
    end
    end
    end
    end

    function onCastSpell(cid, var)
    local startPos = getCreaturePosition(cid)
    RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos)
    RunPart(combat0_Brush_2,cid,var,dfcombat0_Brush_2,startPos)
    RunPart(combat0_Brush_3,cid,var,dfcombat0_Brush_3,startPos)
    addEvent(RunPart,100,combat1_Brush_4,cid,var,dfcombat1_Brush_4,startPos)
    return true
    end
    [code]



    [Spells] Distance Missiles que se dispersan YNU5B25
    https://www.tibiaface.com

    SoyFabi

    SoyFabi
    Miembro
    Miembro
    Exacto, gracias! What a Face

    [Admin] God Maya

    [Admin] God Maya
    Administrador
    Administrador
    Tema solucionado



    [Spells] Distance Missiles que se dispersan YNU5B25
    https://www.tibiaface.com

    Contenido patrocinado


    Ver el tema anterior Ver el tema siguiente Volver arriba  Mensaje (Página 1 de 1.)

    Permisos de este foro:
    No puedes responder a temas en este foro.

     

    BienvenidosTibiaFace es una comunidad de Open Tibia. Para participar debes estar registrado (click para Regístrate).