Please fix my vip system.
#1

PHP код:
C:\Users\Umer\Downloads\NG.pwn(562) : error 017undefined symbol "pInfo"
C:\Users\Umer\Downloads\NG.pwn(31522) : error 001expected token")"but found "["
C:\Users\Umer\Downloads\NG.pwn(31522) : error 029invalid expressionassumed zero
C
:\Users\Umer\Downloads\NG.pwn(31522) : warning 215expression has no effect
C
:\Users\Umer\Downloads\NG.pwn(31522) : error 001expected token";"but found "]"
C:\Users\Umer\Downloads\NG.pwn(31522) : fatal error 107too many error messages on one line
Compilation aborted
.Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
5 Errors

I am getting this error while compiling my script please fix it. Here is the script>

PHP код:
CMD:vips(playeridparams[])
{
        new 
vipstring[2000],count=0;
        if(
IsPlayerConnected(playerid))
        {
            for (new 
0MAX_PLAYERSi++)
            {
                if(
IsPlayerConnected(i))
                {
                    if(
pInfo[i][pVipLevel] > 0)
                    {
                        
format(vipstringsizeof(vipstring),"{ffffff}%s%s (ID:%d)\n"vipstringPlayerName(i), playerid);
                        
count++;
                    }
                }
            }
            
ShowPlayerDialog(playerid,DIALOG_VIPS,DIALOG_STYLE_MSGBOX,"{B266FF}Online VIPs:",vipstring,"Close","");
        }
         if(
count == 0) return SendClientMessage(playerid,-1,""chat" There are no VIP's online.");
           return 
1;

ANd if you want to see my /setvip command too then here you go>

PHP код:
CMD:setvip(playeridparams[])
{
    new 
giveplayeridmoneys1giveplayer[25], playername[25], string[256], mon;
    if (
adlvl[playerid] < 6) return 0;
    if (
sscanf(params"udd"giveplayeridmoneys1mon)) return SendClientMessage2(playeridCOLOR_ORANGE"Usage: /setvip [playerid] [level 1-3] [month]");
    if (!
IsPlayerConnected2(giveplayerid)) return SendClientMessage2(playeridCOLOR_RED"Error: Inactive player id!");
    if (
moneys1 || moneys1 3) return SendClientMessage2(playeridCOLOR_RED"Error: Invalid Vip level.");
    if(
mon || mon 24) return SendClientMessage(playeridCOLOR_RED"Error: Invalid month (0 for lifetime, 24 = 2 years).");
    if (
Logged[giveplayerid] == 0) return SendClientMessage2(playeridCOLOR_WHITE"Error: Player isn't logged in.");
    
GetPlayerName(giveplayeridgiveplayerMAX_PLAYER_NAME);
    if (
adlvl[giveplayerid] >= adlvl[playerid] && adlvl[playerid] != 6) return SendPlayerFormattedText(playeridCOLOR_RED"Error: You cannot make %s as a vip member"giveplayer"");
    
GetPlayerName(giveplayeridgiveplayerMAX_PLAYER_NAME);
    if (
moneys1 == vipmember[giveplayerid])
    {
        
format(string64"%s is already V.I.P L%d."giveplayermoneys1);
        
SendClientMessage2(playeridCOLOR_WHITEstring);
        return 
1;
    }
    
GetPlayerName(playeridplayernameMAX_PLAYER_NAME);
    if (
moneys1 != 0)
    {
        
dini_IntSet(AddDirFile(dir_userfilesgiveplayer), "vip"moneys1);
        
dini_IntSet(AddDirFile(dir_datafilesFILE_VIPLIST), giveplayermoneys1);
        
dini_IntSet(AddDirFile(dir_userfilesgiveplayer), "pskin", -1);
    }
    else
    {
        
dini_Unset(AddDirFile(dir_userfilesgiveplayer), "vip");
        
dini_Unset(AddDirFile(dir_userfilesgiveplayer), "pskin");
        
dini_Unset(AddDirFile(dir_datafilesFILE_VIPLIST), giveplayer);
        
dini_Set(AddDirFile(dir_userfilesgiveplayer), "ChatColor""FFFFFF");
        if (
giveplayerid != playerid)
        {
            
SendClientMessage2(giveplayeridCOLOR_WHITE"Your VIP status has been removed.");
            
SendPlayerFormattedText(playeridCOLOR_YELLOW"You have removed %s's VIP status."giveplayer"");
        }
        else 
SendClientMessage2(playeridCOLOR_WHITE"You have removed your VIP status.");
    }
    if(
mon != 0)
    {
        new 
days;
        
days 30 mon;
        
SetVip(giveplayeriddays);
    }
    else {
        
SetVip(giveplayerid0);
    }
    
vipmember[giveplayerid] = moneys1;
    if(
mon != 0) {
        
format(string64"You have been set as V.I.P L%d for %d monthes."moneys1mon);
        
SendClientMessage2(giveplayeridCOLOR_YELLOWstring);
        
format(string64"You have set %s as V.I.P L%d for %d monthes."giveplayermoneys1mon);
        
SendClientMessage2(playeridCOLOR_YELLOWstring);
    }
    else {
        
format(string64"You have been set as V.I.P L%d for lifetime"moneys1);
        
SendClientMessage2(giveplayeridCOLOR_YELLOWstring);
        
format(string64"You have set %s as V.I.P L%d for lifetime."giveplayermoneys1);
        
SendClientMessage2(playeridCOLOR_YELLOWstring);
    }
    if (
moneys1 == 1)
    {
        
GivePlayerMoney(giveplayeridGetPlayerMoney(giveplayerid)+2500000);
        if (
giveplayerid != playerid)
        {
            
SendClientMessage2(giveplayeridCOLOR_YELLOW"You have been set as a VIP member Level 1.");
            
SendPlayerFormattedText(playeridCOLOR_YELLOW"You have set %s as a VIP member Level 1."giveplayer"");
        }
        else 
SendClientMessage2(playeridCOLOR_YELLOW"You have set yourself as a VIP member Level 1.");
        return 
1;
    }
    if (
moneys1 == 2)
    {
           
GivePlayerMoney(giveplayeridGetPlayerMoney(giveplayerid)+5000000);
        if (
giveplayerid != playerid)
        {
            
SendClientMessage2(giveplayeridCOLOR_YELLOW"You have been set as a VIP member Level 2.");                SendPlayerFormattedText(playeridCOLOR_YELLOW"You have set %s as a VIP member Level 2."giveplayer"");
        }
        else 
SendClientMessage2(playeridCOLOR_YELLOW"You have set yourself as a VIP member Level 2.");
        return 
1;
    }
    if (
moneys1 == 3)
    {
           
GivePlayerMoney(giveplayeridGetPlayerMoney(giveplayerid)+20000000);
        if (
giveplayerid != playerid)
        {
            
SendClientMessage2(giveplayeridCOLOR_YELLOW"You have been set as a VIP DELUXE.");                SendPlayerFormattedText(playeridCOLOR_YELLOW"You have set %s as a VIP Deluxe."giveplayer"");
        }
        else 
SendClientMessage2(playeridCOLOR_YELLOW"You have set yourself as a VIP Deluxe.");
        return 
1;
        }
    return 
1;





Please fix my /vips cmd.
Reply


Messages In This Thread
Please fix my vip system. - by Isteven - 25.05.2018, 15:13
Re: Please fix my vip system. - by CaptainBoi - 25.05.2018, 15:35
Re: Please fix my vip system. - by Vizi10 - 25.05.2018, 20:44

Forum Jump:


Users browsing this thread: 2 Guest(s)