Uma spell bem simples, + pra quem n sabe como fazer oque fiz abaixo, ja fica como um tutorial.
Spells/Script crie 1 arquivo LUA chamado Elementsforce e adicione isso dentro:
local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HEALING) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_HOLYDAMAGE) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, FALSE) setCombatParam(combat, COMBAT_PARAM_DISPEL, CONDITION_PARALYZE) setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 8.335, 0, 8.58, 0) local Holyarea = createCombatArea{ {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, 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, 2, 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, 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}, } local effect1 = createCombatArea{ {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, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 2, 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, 0}, {0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0}, } local effect2 = createCombatArea{ {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, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 2, 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, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, } local effect3 = createCombatArea{ {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, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 2, 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, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, } local effect4 = createCombatArea{ {0, 0, 0, 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, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 2, 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, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, } function onCastSpell(cid, var) local function elements1(params) doSendDistanceShoot({x=getThingPos(cid).x+3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, {x=getThingPos(cid).x+3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, CONST_ANI_ICE) doAreaCombatHealth(getThingPos(cid), COMBAT_ICEDAMAGE, getThingPos(cid), effect1, -(0), -(0), CONST_ME_ICEATTACK) mayNotMove(cid, 1) end local function elements2(params) doSendAnimatedText({x=getThingPos(cid).x+3, y=getThingPos(cid).y-3, z=getThingPos(cid).z},"ICE",TEXTCOLOR_BLUE) doSendDistanceShoot({x=getThingPos(cid).x+3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, {x=getThingPos(cid).x-3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, CONST_ANI_ENERGYBALL) doAreaCombatHealth(getThingPos(cid), COMBAT_ENERGYDAMAGE, getThingPos(cid), effect2, -(0), -(0), CONST_ME_ENERGYHIT) end local function elements3(params) doSendAnimatedText({x=getThingPos(cid).x-3, y=getThingPos(cid).y-3, z=getThingPos(cid).z},"ENERGY",TEXTCOLOR_PURPLE) doSendDistanceShoot({x=getThingPos(cid).x-3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, {x=getThingPos(cid).x-3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, CONST_ANI_FIRE) doAreaCombatHealth(getThingPos(cid), COMBAT_FIREDAMAGE, getThingPos(cid), effect3, -(0), -(0), CONST_ME_FIREATTACK) end local function elements4(params) doSendAnimatedText({x=getThingPos(cid).x-3, y=getThingPos(cid).y+3, z=getThingPos(cid).z},"FIRE",TEXTCOLOR_RED) doSendDistanceShoot({x=getThingPos(cid).x-3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, {x=getThingPos(cid).x+3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, CONST_ANI_EARTH) doAreaCombatHealth(getThingPos(cid), COMBAT_EARTHDAMAGE, getThingPos(cid), effect4, -(0), -(0), CONST_ME_SMALLPLANTS) end local function elements5(params) doSendDistanceShoot({x=getThingPos(cid).x+3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, getThingPos(cid), CONST_ANI_EARTH) doSendDistanceShoot({x=getThingPos(cid).x+3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, getThingPos(cid), CONST_ANI_ICE) doSendDistanceShoot({x=getThingPos(cid).x-3, y=getThingPos(cid).y+3, z=getThingPos(cid).z}, getThingPos(cid), CONST_ANI_FIRE) doSendDistanceShoot({x=getThingPos(cid).x-3, y=getThingPos(cid).y-3, z=getThingPos(cid).z}, getThingPos(cid), CONST_ANI_ENERGYBALL) end local function elements6(params) doAreaCombatHealth(getThingPos(cid), holy, getThingPos(cid), Holyarea, -(0), -(0), CONST_ME_HOLYAREA) doSendDistanceShoot(getThingPos(cid), {x=getThingPos(cid).x+5, y=getThingPos(cid).y, z=getThingPos(cid).z}, CONST_ANI_ICE) doSendDistanceShoot(getThingPos(cid), {x=getThingPos(cid).x-5, y=getThingPos(cid).y, z=getThingPos(cid).z}, CONST_ANI_ENERGYBALL) doSendDistanceShoot(getThingPos(cid), {x=getThingPos(cid).x, y=getThingPos(cid).y+5, z=getThingPos(cid).z}, CONST_ANI_FIRE) doSendDistanceShoot(getThingPos(cid), {x=getThingPos(cid).x, y=getThingPos(cid).y-5, z=getThingPos(cid).z}, CONST_ANI_EARTH) mayNotMove(cid, 0) end local function elements7(params) doSendAnimatedText({x=getThingPos(cid).x+3, y=getThingPos(cid).y+3, z=getThingPos(cid).z},"EARTH",TEXTCOLOR_GREEN) end addEvent(doCombat, 1600, cid, combat, var) addEvent(elements1, 000, parameters) addEvent(elements2, 300, parameters) addEvent(elements3, 600, parameters) addEvent(elements4, 900, parameters) addEvent(elements5, 1300, parameters) addEvent(elements6, 1600, parameters) addEvent(elements7, 1200, parameters) end
Agora em Spells.xml adicione :
<instant name="Elements Force" words="utito confuri" lvl="300" mana="120" exhaustion="2500" needlearn="0" script="Elementsforce.lua"> <vocation name="Sorcerer"/> <vocation name="Master Sorcerer"/> <vocation name="Druid"/> <vocation name="Elder Druid"/> </instant>
Tambem serve de exemplo para fazer spells com o DistanceShoots saindo de outros lugares.
Com uma pouco de criatividade da pra fazer umas spells bem legais e fora do comum.