Dude, you really need to do it on yourself, you can't always rely on other people, specially when you are developing a server
Why do you need to go to every single topic like this, and tell people this? No offense.
That's a hobby of some MTA forum members.
OT:
levels = {
{exp=100},
{exp=250},
{exp=500},
{exp=600}
}
maxlvl = 4
function givePlayerXP ( source, valve )
local finalXP = valve
local currXP = getElementData ( source, "xp" ) or 0
local level = getElementData ( source, "level" ) or 1
local nextXP = levels[level].exp
if currXP+finalXP >= nextXP and maxlvl > level then
setElementData ( source, "xp", 0 )
setElementData ( source, "level", level + 1 )
outputChatBox ("Rank up"..tostring(level+1), source, 255, 25, 0, true))
else
setElementData ( source, "xp", currXP + finalXP )
end
end
I used tables then I edited #Thug's function.
Change maxlvl, and don't forget to add levels into the table like what I did.