Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local combat = createCombatObject()
- setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HEALING)
- setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE)
- setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false)
- setCombatParam(combat, COMBAT_PARAM_TARGETPLAYERSORSUMMONS, true)
- setCombatParam(combat, COMBAT_PARAM_DISPEL, CONDITION_PARALYZE)
- setHealingFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 7, 7, 14, 17)
- local area = createCombatArea(AREA_CIRCLE3X3)
- setCombatArea(combat, area)
- if hasCondition(cid, CONDITION_EXHAUST) then
- doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
- return TRUE
- end
- function onCastSpell(cid, var)
- local mags = {}
- local pos = getCreaturePosition(cid)
- local pos5 = getSpectators(pos, 1, 1)
- pos.x = pos.x - 2
- local pos1 = getSpectators(pos, 1, 1)
- pos.x = pos.x + 4
- local pos2 = getSpectators(pos, 1, 1)
- pos.x = pos.x - 2
- pos.y = pos.y - 2
- local pos3 = getSpectators(pos, 1, 1)
- pos.y = pos.y + 4
- local pos4 = getSpectators(pos, 1, 1)
- pos.y = pos.y - 3
- pos.x = pos.x - 1
- local pos6 = getSpectators(pos, 1, 1)
- pos.x = pos.x + 2
- local pos7 = getSpectators(pos, 1, 1)
- pos.y = pos.y + 2
- local pos8 = getSpectators(pos, 1, 1)
- pos.x = pos.x - 2
- local pos9 = getSpectators(pos, 1, 1)
- if pos1 ~= nil then
- for r=1, #pos1 do
- table.insert(mags, pos1[r])
- end
- end
- if pos2 ~= nil then
- for r=1, #pos2 do
- table.insert(mags, pos2[r])
- end
- end
- if pos3 ~= nil then
- for r=1, #pos3 do
- table.insert(mags, pos3[r])
- end
- end
- if pos4 ~= nil then
- for r=1, #pos4 do
- table.insert(mags, pos4[r])
- end
- end
- if pos5 ~= nil then
- for r=1, #pos5 do
- table.insert(mags, pos5[r])
- end
- end
- if pos6 ~= nil then
- for r=1, #pos6 do
- table.insert(mags, pos6[r])
- end
- end
- if pos7 ~= nil then
- for r=1, #pos7 do
- table.insert(mags, pos7[r])
- end
- end
- if pos8 ~= nil then
- for r=1, #pos8 do
- table.insert(mags, pos8[r])
- end
- end
- if pos9 ~= nil then
- for r=1, #pos9 do
- table.insert(mags, pos9[r])
- end
- end
- for t=1, #mags do
- if mags[t] ~= cid then
- doSendAnimatedText((getCreaturePosition(mags[t])), "Healing!", TEXTCOLOR_LIGHTBLUE)
- end
- end
- return doCombat(cid, combat, var)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement