exp sistem
#8

Try this code, I did it fast ..

Code:
new Exp[MAX_PLAYERS]; //experience
new Lv[MAX_PLAYERS]; //level
forward LevelUp(playerid);
Ongamemodeinit :

Code:
SetTimer("LevelUp", 1000, false);
out of any callback :

Code:
public LevelUp(playerid)
{
if(LevelNext(playerid) >= Exp[playerid]) {
Exp[playerid] = 0;
Lv[playerid] ++;
SetPlayerScore(playerid, GetPlayerScore(playerid) + 1);      
}
}
Code:
stock LevelNext(playerid){
return (Lv[playerid] * 5);
}
Only to increase the experience: Exp[playerid] ++;

Do not promise anything eh

Otherwise, use one of these:

https://sampforum.blast.hk/showthread.php?tid=353225
https://sampforum.blast.hk/showthread.php?tid=274680
Reply


Messages In This Thread
exp sistem - by srcka< - 24.07.2012, 19:57
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 21:00
Re: exp sistem - by srcka< - 24.07.2012, 21:24
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 21:27
Re: exp sistem - by srcka< - 24.07.2012, 21:37
Re: exp sistem - by gabriellino18 - 24.07.2012, 21:52
Re: exp sistem - by Rudy_ - 24.07.2012, 21:54
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 21:56
Re: exp sistem - by gabriellino18 - 24.07.2012, 21:56
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 21:59
Re: exp sistem - by gabriellino18 - 24.07.2012, 22:05
Re: exp sistem help me please - by gabriellino18 - 24.07.2012, 22:07
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 22:09
Re: exp sistem - by gabriellino18 - 24.07.2012, 22:10
Re: exp sistem - by srcka< - 24.07.2012, 22:29
Re: exp sistem - by [IKS]Niko_Hs™ - 24.07.2012, 22:35
Re: exp sistem - by srcka< - 24.07.2012, 22:40
Re: exp sistem - by srcka< - 24.07.2012, 22:44
Re: exp sistem - by srcka< - 24.07.2012, 22:48
Re: exp sistem - by [IKS]Niko_Hs™ - 25.07.2012, 12:27

Forum Jump:


Users browsing this thread: 1 Guest(s)