data/spells/spells.xmland change whatever you want. <instant name="yourspellname" words="yourspellname" lvl="1" mana="1" prem="0" aggressive="0" exhaustion="1000" needlearn="0" direction="1" event="script" value="yourspellname.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>
data/spells/scripts and add this to itlocal combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false)
local condition =...
data/spells/spells.xmland change whatever you want. <instant name="yourspellname" words="yourspellname" lvl="1" mana="1" prem="0" aggressive="0" exhaustion="1000" needlearn="0" direction="1" event="script" value="yourspellname.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>
data/spells/scripts and add this to itlocal combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false)
local condition = createConditionObject(CONDITION_MANASHIELD)
setConditionParam(condition, CONDITION_PARAM_TICKS, 200000)
setCombatCondition(combat, condition)
local area = createCombatArea(AREA_BEAM3, AREADIAGONAL_BEAM3)
setCombatArea(combat, area)
function onCastSpell(cid, var)
return doCombat(cid, combat, var)
end
data/spells/lib/spells.luaAREADIAGONAL_BEAM3 = {
{0, 0, 1, 0, 0, 0},
{0, 0, 0, 1, 0, 0},
{0, 0, 0, 0, 1, 0},
{0, 0, 0, 0, 0, 3}
}
AREA_BEAM3 = {
{1},
{1},
{1},
{3}
}
Add this to yourdata/spells/spells.xmland change whatever you want.
create a Lua file inXML:<instant name="yourspellname" words="yourspellname" lvl="1" mana="1" prem="0" aggressive="0" exhaustion="1000" needlearn="0" direction="1" event="script" value="yourspellname.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>data/spells/scriptsand add this to it
then add this toLUA:local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false) local condition = createConditionObject(CONDITION_MANASHIELD) setConditionParam(condition, CONDITION_PARAM_TICKS, 200000) setCombatCondition(combat, condition) local area = createCombatArea(AREA_BEAM3, AREADIAGONAL_BEAM3) setCombatArea(combat, area) function onCastSpell(cid, var) return doCombat(cid, combat, var) enddata/spells/lib/spells.lua
LUA:AREADIAGONAL_BEAM3 = { {0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 1, 0}, {0, 0, 0, 0, 0, 3} } AREA_BEAM3 = { {1}, {1}, {1}, {3} }
spells.xml, You need to add this like I mentioned on my XML line then both problems will get solved.direction="1"
Add this to yourdata/spells/spells.xmland change whatever you want.
create a Lua file inXML:<instant name="yourspellname" words="yourspellname" lvl="1" mana="1" prem="0" aggressive="0" exhaustion="1000" needlearn="0" direction="1" event="script" value="yourspellname.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>data/spells/scriptsand add this to it
then add this toLUA:local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false) local condition = createConditionObject(CONDITION_MANASHIELD) setConditionParam(condition, CONDITION_PARAM_TICKS, 200000) setCombatCondition(combat, condition) local area = createCombatArea(AREA_BEAM3, AREADIAGONAL_BEAM3) setCombatArea(combat, area) function onCastSpell(cid, var) return doCombat(cid, combat, var) enddata/spells/lib/spells.lua
LUA:AREADIAGONAL_BEAM3 = { {0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 1, 0}, {0, 0, 0, 0, 0, 3} } AREA_BEAM3 = { {1}, {1}, {1}, {3} }
AREADIAGONAL_1SHOT3SQMFRONT = {
{0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 3}
}
AREA_1SHOT3SQMFRONT = {
{0},
{1},
{0},
{3}
}
I don't get it, How do you want the area to look like? I made both and still none of them is as correct as you want?
View attachment 53262
View attachment 53263

You didn't add it properly tospells.xml, You need to add this like I mentioned on my XML line then both problems will get solved.
XML:direction="1"