• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

When up level take mp/hp full.

GuHB

Member
Joined
Dec 14, 2009
Messages
630
Reaction score
9
Location
Brazil
My request is simple.

When player up-level, your Mana Points and Health Points be full.


Thanks.
 
LUA:
function onAdvance(cid, skill, oldLevel, newLevel)
if newLevel > oldLevel then
   doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
   doPlayerAddMana(cid, getPlayerMaxMana(cid))
end
return true
end
 
Last edited:
Creaturescipt:

Code:
function onAdvance(cid, skill, oldlevel, newlevel)
    if (skill == SKILL_LEVEL) then
		doCreatureAddHealth(cid, (getCreatureMaxHealth(cid) - getPlayerHealth(cid)))
		doCreatureAddMana(cid, getCreatureMaxMana(cid) - getCreatureMana(cid))
	end
	return true
end
 
Back
Top