/viplist - is there any thing wrong?
#6

PHP код:
#if defined Loop
    #undef Loop(%1)
#endif
#define Loop(%1) for(new %1 = GetPlayerPoolSize(); %1 != -1; %1 --) if(IsPlayerConnected(%1))
CMD:viplist(playerid)
{
    new 
count;
    
Loop(i)
    {
        if(
PlayerInfo[i][pVIP])
        {
            
format(stringsizeof string"- {ffff00}%s{00ff00}| {0066ff}(ID:%s) {00ff00}| %x %s\n"GetName(i), iGetVipColor(i), GetVipLevel(i));
            
strcat(stringstringsizeof string);
            
count += 1;
        }
    }
    if(!
count) return ShowPlayerDialog(playerid18DIALOG_STYLE_MSGBOX"{00ff00}Online VIPs:","There isn't any online V.I.P""Ok""");
    else return 
ShowPlayerDialog(playerid18DIALOG_STYLE_MSGBOX"{00ff00}Online VIPs:",string"Okay""");
}
GetVipLevel(playerid)
{
    new 
str[10];
    switch(
PlayerInfo[playerid][pVIP])
    {
        case 
0str "None";
        case 
1str "Bronze";
        case 
2str "Silver";
        case 
3str "Gold";
    }
    return 
str;
}
GetVipColor(playerid)
{
    new 
str[10];
    switch(
PlayerInfo[playerid][pVIP])
    {
        case 
1str "{996600}";
        case 
2str "{adad85}";
        case 
3str "{e68a00}";
    }
    return 
str;

Reply


Messages In This Thread
/viplist - is there any thing wrong? - by RyderX - 06.02.2017, 10:47
Re: /viplist - is there any thing wrong? - by AndreiWow - 06.02.2017, 10:55
Re: /viplist - is there any thing wrong? - by RyderX - 06.02.2017, 10:56
Re: /viplist - is there any thing wrong? - by SyS - 06.02.2017, 10:59
Re: /viplist - is there any thing wrong? - by iLearner - 06.02.2017, 11:00
Re: /viplist - is there any thing wrong? - by Logic_ - 06.02.2017, 11:23
Re: /viplist - is there any thing wrong? - by RyderX - 06.02.2017, 11:37

Forum Jump:


Users browsing this thread: 1 Guest(s)