Jump to content

"EXP"


iRAGE

Recommended Posts

Example of how to use my resource exp system when killing a player:

  
  
function rewardOnWasted ( ammo, killer, killerweapon, bodypart ) 
if (killer) and (killer ~=source) then 
local exp = getElementData(killer,"exp") 
if exp then 
setElementData(killer,"exp",tonumber(getElementData(killer,"exp"))+5) 
outputChatBox("Experience gained +5! total ".. tonumber(exp)+5,killer,0,255,0) 
else 
setElementData(killer,"exp",0) 
end 
end 
end 
addEventHandler ( "onPlayerWasted", getRootElement(), rewardOnWasted ) 

this will give him +5 of experience every kill.

Link to comment

Awsome... TY. You should make a public thread for it. It would help allot of people with their servers.

And Benxamix, yea you do have a cool EXP system on your server. Thats the same idea I have but without the zombs lol.

So if you DM or TDM you gain exp and levels.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...