Rank system
#10

Quote:
Originally Posted by JesterlJoker
Посмотреть сообщение
and it only meant you didn't read the code
PHP код:
public OnPlayerDeath(playeridkilleridreason

       
CheckPlayerKills(killerid); //but you'll still need codes inside this to make it work. No way around it 
       
return 1

I specified the killerid not the playerid which means I indicated whoever the killer is.

Now if that is called correctly and I am assuming that you have set you players enums to a kills
ie.
PHP код:
enum pInfo
{
    
ID,
    
Name[MAX_PLAYER_NAME],
    
Kills,
    
Deaths,
}
new 
PlayerData[MAX_PLAYERS][pInfo
now you do this on checkplayerkills
PHP код:
CheckPlayerKills(playerid)
{
    
PlayerData[playerid][Kills]+=1;
    if(
PlayerData[playerid][Kills] == 50)
    {
        
SCM(playeridCOLOR_RED"Oho shit. Holla there n*gg*. You did some tight shit and got fifty heads.");
        
SCM(playeridCOLOR_RED"You oughta have some kind of reward. Here foo take this.")
        
SCM(playeridCOLOR_RED"You have ranked up.");
                
//add some theatrics and some shit and your good.
        
PlayerData[playerid][rank] += 1// or rank++
    
}
    return 
1;

I read it but i ignored cause
You said this
Код:
if(PlayerData[playerid][Kills] == 50)
And i need every 50 kills it rank up
Reply


Messages In This Thread
Rank system - by Loinal - 16.02.2017, 13:10
Re: Rank system - by Hansrutger - 16.02.2017, 13:13
Re: Rank system - by Loinal - 16.02.2017, 13:44
Re: Rank system - by JesterlJoker - 16.02.2017, 13:52
Re: Rank system - by Loinal - 16.02.2017, 13:55
Re: Rank system - by X337 - 16.02.2017, 13:57
Re: Rank system - by JesterlJoker - 16.02.2017, 14:23
Re: Rank system - by Loinal - 16.02.2017, 15:47
Re: Rank system - by JesterlJoker - 16.02.2017, 15:57
Re: Rank system - by Loinal - 16.02.2017, 17:08

Forum Jump:


Users browsing this thread: 1 Guest(s)