function onUse(cid, item, frompos, item2, topos)
local lvl = getPlayerLevel(cid)
if lvl >= 10 and lvl <= 39 then
doPlayerAddExperience(cid, 300)
exps = 300
elseif lvl >= 41 and lvl <= 48 then
doPlayerAddExperience(cid, 100)
exps = 100
elseif lvl >= 51 and lvl <= 99 then
doPlayerAddExperience(cid, 50)
exps = 50
else
exps = 0
end
if exps >= 1 then
--doPlayerSay(cid,""..exps.." experiance Up",2)
doPlayerSendTextMessage(cid,22,"You Gained a " .. exps )
doSendMagicEffect(getPlayerPosition(cid), 14)
doRemoveItem(item.uid, 1)
else
doPlayerSendTextMessage(cid,22,"You Cannot Use This Object.")
--doPlayerSay(cid,"You Cannot Use This Object",2)
end
return true
end