• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Summon explode

beliar34

Member
Joined
Feb 28, 2012
Messages
307
Solutions
7
Reaction score
11
I am looking for script summon who explode when stand near target
 
Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Stark wolf" nameDescription="a Stark Wolf" race="blood" speed="2240" manacost="500">
    <health now="53000" max="53000"/>
    <look type="26" corpse="5527"/>
    <targetchange interval="5000" chance="8"/>
    <strategy attack="100" defense="0"/>
    <flags>
        <flag summonable="1"/>
        <flag attackable="1"/>
        <flag hostile="1"/>
        <flag illusionable="1"/>
        <flag convinceable="1"/>
        <flag pushable="1"/>
        <flag canpushitems="1"/>
        <flag canpushcreatures="1"/>
        <flag targetdistance="1"/>
        <flag staticattack="90"/>
        <flag runonhealth="0"/>
    </flags>
    <attacks>
        <attack name="los" interval="1000" chance="100" range="5" radius="4" target="1" min="-2300" max="-3200">
        </attack>
    </attacks>
    <defenses armor="0" defense="1"/>
    <voices interval="5000" chance="10">
        <voice sentence="Kaboom!"/>
    </voices>
</monster>

Code:
function onCastSpell(cid, var)
     if #getCreatureSummons(cid) < 5 then
         for x = 1, 5 do
             m = doSummonCreature("stark wolf", getThingPos(cid))
             doConvinceCreature(cid, m)
             doConvinceCreature(cid, m)
             doConvinceCreature(cid, m)
             doConvinceCreature(cid, m)
             doConvinceCreature(cid, m)
         end
         doSendMagicEffect(getThingPos(cid), CONST_ME_MAGIC_BLUE)
     else
         doPlayerSendCancel(cid, "You already summoned monsters.")
         doSendMagicEffect(getThingPos(cid), CONST_ME_POFF)
         return false
     end
     return true
end
Code:
--Created with SuperVego--
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE)
setCombatParam(combat, COMBAT_PARAM_EFFECT,CONST_ME_YELLOWENERGY)
setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, 21)
setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -8.0, 0, -8.1, 0)

arr = {
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0},
{0, 0, 0, 1, 1, 3, 1, 1, 0, 0, 0},
{0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
}

local area = createCombatArea(arr)
setCombatArea(combat, area)

function onCastSpell(cid, var)
    doCreatureAddHealth(cid, -(getCreatureMaxHealth(cid) / 100) * 100)
    return doCombat(cid, combat, var)
end
 
Back
Top