Issue with my /r
#11

Quote:
Originally Posted by Azzeto
Посмотреть сообщение
@Jack Leslie, I did that, edited everything to my ranks and all, now it says Deputy Sheriff When Im rank six?

PHP код:
stock SDRank(playerid)
{
    new 
string[126];
    switch(
PlayerInfo[playerid][Member]) // change to your rank variable
    
{
        case 
5string "Sheriff";
        case 
4string "Under Sheriff";
        case 
3string "Lieutenant";
        case 
2string "Sergeant";
        case 
1string "Deputy Sheriff Bonus";
        default: 
string "Deputy Sheriff";
    }
    return 
string;

Because there's no case 6, so it uses default.


pawn Код:
stock SDRank(playerid)
{
    new string[126];
    switch(PlayerInfo[playerid][Member]) // change to your rank variable
    {
        case 6: string = "Sheriff";
        case 5: string = "Deputy Sheriff";
        case 4: string = "Under Sheriff";
        case 3: string = "Lieutenant";
        case 2: string = "Sergeant";
        case 1: string = "Deputy Sheriff Bonus";
        default: string = // If there is no case for the rank, or the rank is 0, it will use this;
    }
    return string;
}
Reply


Messages In This Thread
Issue with my /r - by Azzeto - 16.12.2011, 10:33
Re : Issue with my /r - by BigBaws - 16.12.2011, 10:37
Re: Issue with my /r - by kizla - 16.12.2011, 10:37
Re: Issue with my /r - by Azzeto - 16.12.2011, 10:41
Re: Issue with my /r - by kizla - 16.12.2011, 10:47
Re: Issue with my /r - by PrawkC - 16.12.2011, 10:48
Re: Issue with my /r - by Jack_Leslie - 16.12.2011, 10:51
Re : Re: Issue with my /r - by BigBaws - 16.12.2011, 10:58
Re: Issue with my /r - by Azzeto - 16.12.2011, 11:00
Re: Issue with my /r - by PrawkC - 16.12.2011, 11:02
Re: Issue with my /r - by Jack_Leslie - 16.12.2011, 11:04
Re: Issue with my /r - by Azzeto - 16.12.2011, 11:10

Forum Jump:


Users browsing this thread: 1 Guest(s)