Hello there otlander!
So here's my problem I just finished my first spell script witch I ofcurse wanna use in my server but there's a tiny problem the spell gives too much mlvl exp or w/e its called.
So how do I change it so when you use the spell it gives less exp
Heres the script:
[/PHP]
Kind regards vTune
So here's my problem I just finished my first spell script witch I ofcurse wanna use in my server but there's a tiny problem the spell gives too much mlvl exp or w/e its called.
So how do I change it so when you use the spell it gives less exp
Heres the script:
PHP:
[PHP]-- SpellCreator generated.
-- =============== COMBAT VARS ===============
-- Areas/Combat for 0ms
local combat0_exevo_meg_mas_san = createCombatObject()
setCombatParam(combat0_exevo_meg_mas_san, COMBAT_PARAM_EFFECT, CONST_ME_YELLOWENERGY)
setCombatParam(combat0_exevo_meg_mas_san, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_SMALLHOLY)
setCombatParam(combat0_exevo_meg_mas_san, COMBAT_PARAM_TYPE, COMBAT_HOLYDAMAGE)
setCombatArea(combat0_exevo_meg_mas_san,createCombatArea({{0, 0, 0, 1, 0, 0, 0},
{0, 0, 1, 0, 1, 0, 0},
{0, 1, 0, 1, 0, 1, 0},
{1, 0, 1, 2, 1, 0, 1},
{0, 1, 0, 1, 0, 1, 0},
{0, 0, 1, 0, 1, 0, 0},
{0, 0, 0, 1, 0, 0, 0}}))
function getDmg_exevo_meg_mas_san(cid, level, maglevel)
return (300)*-1,(800)*-1
end
setCombatCallback(combat0_exevo_meg_mas_san, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_exevo_meg_mas_san")
local dfcombat0_exevo_meg_mas_san = {CONST_ANI_HOLY,0,1,1,0,0,-1,-1,0,-1,2,-2,1,-2,-1,-1,-2,1,-2,1,2,2,1,2,-1,0,-3,0,3,3,0,-3,0}
-- Areas/Combat for 900ms
local combat9_exevo_meg_mas_san = createCombatObject()
setCombatParam(combat9_exevo_meg_mas_san, COMBAT_PARAM_EFFECT, CONST_ME_YELLOWENERGY)
setCombatParam(combat9_exevo_meg_mas_san, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_SMALLHOLY)
setCombatParam(combat9_exevo_meg_mas_san, COMBAT_PARAM_TYPE, COMBAT_HOLYDAMAGE)
setCombatArea(combat9_exevo_meg_mas_san,createCombatArea({{0, 0, 1, 0, 0},
{0, 1, 0, 1, 0},
{1, 0, 2, 0, 1},
{0, 1, 0, 1, 0},
{0, 0, 1, 0, 0}}))
function getDmg_exevo_meg_mas_san(cid, level, maglevel)
return (300)*-1,(800)*-1
end
setCombatCallback(combat9_exevo_meg_mas_san, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_exevo_meg_mas_san")
local dfcombat9_exevo_meg_mas_san = {CONST_ANI_HOLY,2,0,1,1,0,2,-1,1,-1,-1,1,-1,0,-2,-2,0}
-- =============== 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_exevo_meg_mas_san,cid,var,dfcombat0_exevo_meg_mas_san,startPos)
addEvent(RunPart,900,combat9_exevo_meg_mas_san,cid,var,dfcombat9_exevo_meg_mas_san,startPos)
return true
end
Kind regards vTune