local cfg = {
level = 1,
amount = 10
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if getPlayerLevel(cid, cfg.level) then
doPlayerAddLevel(cid, cfg.amount)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You used an exp scroll and received 10 levels.")
doSendAnimatedText(getCreaturePosition(cid), "Exp Doll", TEXTCOLOR_RED)
doSendMagicEffect(getCreaturePosition(cid), 33)
end
doPlayerSendCancel(cid, "You do not have enought level for this scroll, you need level 1 to use it.")
return true
end