I made this scripts but.. don't work =(
advances/level.lua
data/creaturescripts.xml
Help =(
advances/level.lua
Code:
--onAdvance system by 4220niller
--Script by Darkhaos
function onThink(cid, interval)
dofile("./data/creaturescripts/scripts/onAdvance.lua")
onAdvanceController(cid)
return TRUE
end
function onAdvance(cid, oldlevel, newlevel)
local phealth = 999999999
local pmana = 999999999
local pps = getPlayerPosition(cid)
if newlevel > oldlevel then
doCreatureAddHealth(cid,phealth)
doPlayerAddMana(cid,pmana)
doSendAnimatedText(ppos, "Level Up", TEXTCOLOR_LIGHTGREEN)
end
end
data/creaturescripts.xml
Code:
<event type="think" name="PlayerThink" script="think.lua"/>
Help =(