#2

PHP код:
CMD:vips(playeridparams[])
{
    new 
string[128], acount 0Name[MAX_PLAYER_NAME];
    foreach(
Playeri) {
        if(
IsPlayerVipMember(i)) {
            
acount++;
        }
    }
    if(
acount 0) {
        
SendClientMessage(playeridCOLOR_GREEN"----------Online VIP's----------");
        foreach(
Playeri) {
            if(
IsPlayerVipMember(i)) {
                
GetPlayerName(iNamesizeof(Name));
                
format(stringsizeof string"VIP: %s"Name);
                
SendClientMessage(playeridCOLOR_GREENstring);
            }
        }
        
format(stringsizeof string"Total VIP's online: %d."acount);
        
SendClientMessage(playerid, -1string);
    }
    else if(
acount 1SendClientMessage(playerid0xD8D8D8FF"There are no VIP's online!");
    return 
1;

You were checking if the player who typed /vips is a vip, you checked this GetPlayerPoolSize() (x) amount of times.
Reply


Messages In This Thread
Help - by SeifGeny - 04.07.2017, 18:54
Re: Help - by Meller - 04.07.2017, 19:19
Re: Help - by SpaceX - 04.07.2017, 20:03
Re: Help - by SeifGeny - 04.07.2017, 20:20

Forum Jump:


Users browsing this thread: 2 Guest(s)