[AJUDA] Erro No Sistema de Mascara
#1

Код:
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(854) : error 076: syntax error in the expression, or invalid function call
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(855) : error 076: syntax error in the expression, or invalid function call
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1153) : error 076: syntax error in the expression, or invalid function call
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1153) : error 072: "sizeof" operator is invalid on "function" symbols
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1159) : error 076: syntax error in the expression, or invalid function call
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1160) : error 076: syntax error in the expression, or invalid function call
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1183) : warning 209: function "cmd_colocarmascara" should return a value
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(1184) : error 010: invalid function or declaration
C:\Users\Rafael\Documents\Brasil_StyleGames_RPG\Brasil StyleGames RPG\gamemodes\BSG.pwn(5508) : warning 219: local variable "str" shadows a variable at a preceding level
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


7 Errors.
Linhas:

Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
	for (new i = 0; i < SLOTS; i ++)
	{
	    if(IsPlayerConnected(i))
	    {
	       if(Mascarado[i] == 1)
	       {
	          GetPlayerName(playerid, Nome, sizeof(Nome));
		      format(str, sizeof(str), "%s[%i]", Nome, playerid);
		      SendClientMessage(playerid, -1, str);
          }
       }
	}
	return 1;
}
Reply
#2

pawn Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
    for (new i = 0; i < SLOTS; i ++)
    {
        if(Mascarado[i] == 1)
        {
            new str[50];
            GetPlayerName(playerid, Nome, sizeof(Nome));
            format(str, sizeof(str), "%s[%i]", Nome, playerid);
            SendClientMessage(playerid, -1, str);
        }
    }
    return 1;
}
Reply
#3

Quote:
Originally Posted by Los
Посмотреть сообщение
pawn Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
    for (new i = 0; i < SLOTS; i ++)
    {
        if(Mascarado[i] == 1)
        {
            new str[50];
            GetPlayerName(playerid, Nome, sizeof(Nome));
            format(str, sizeof(str), "%s[%i]", Nome, playerid);
            SendClientMessage(playerid, -1, str);
        }
    }
    return 1;
}
Errado. nгo й playerid e sim 'i'.
pawn Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
    new mystr[30];
    for (new i = 0; i < SLOTS; i ++)
    {
        if(IsPlayerConnected(i) && Mascarado[i] == 1)
        {
            GetPlayerName(i, Nome, sizeof(Nome));
            format(mystr, sizeof(mystr), "%s[%i]", Nome, i);
            SendClientMessage(playerid, -1, mystr);          
       }
    }
    return 1;
}
rep+?
Reply
#4

Quote:
Originally Posted by Ricop522
Посмотреть сообщение
Errado. nгo й playerid e sim 'i'.
pawn Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
    new mystr[30];
    for (new i = 0; i < SLOTS; i ++)
    {
        if(IsPlayerConnected(i) && Mascarado[i] == 1)
        {
            GetPlayerName(i, Nome, sizeof(Nome));
            format(mystr, sizeof(mystr), "%s[%i]", Nome, i);
            SendClientMessage(playerid, -1, mystr);          
       }
    }
    return 1;
}
rep+?
Thanks.
Reply
#5

Код:
CMD:colocarmascara(playerid, params[])
{
    if(Mascarado[playerid] == 0)
	{
        if(Mascara[playerid] == 1)
	    {
	       SendClientMessage(playerid, -1, "Vocк colocou sua mбscara.");
	       Mascarado[playerid] = 1;
        }
        else return SendClientMessage(playerid, -1, "Vocк nгo tem uma mбscara, compre uma!");
     }
     else if(Mascarado[playerid] == 1)
     {
        if(Mascara[playerid] == 1)
        {
	       SendClientMessage(playerid, -1, "Vocк retirou sua mбscara.");
		   Mascarado[playerid] = 0;
	    }
	    else return SendClientMessage(playerid, -1, "Vocк nгo tem uma mбscara, compre uma!");
	    }
	}
	return 1;
}
Deu mesmos 7 erros aqui
Reply
#6

pawn Код:
CMD:colocarmascara(playerid, params[])
{
    if(Mascarado[playerid] == 0)
    {
        if(Mascara[playerid] == 1)
        {
            SendClientMessage(playerid, -1, "Vocк colocou sua mбscara.");
            Mascarado[playerid] = 1;
        }
        else return SendClientMessage(playerid, -1, "Vocк nгo tem uma mбscara, compre uma!");
    }
    else if(Mascarado[playerid] == 1)
    {
        if(Mascara[playerid] == 1)
        {
            SendClientMessage(playerid, -1, "Vocк colocou sua mбscara.");
            Mascarado[playerid] = 0;
        }
        else return SendClientMessage(playerid, -1, "Vocк nгo tem uma mбscara, compre uma!");
     }
     return 1;
}
Reply
#7

pawn Код:
CMD:mascarados(playerid, params[])
{
    SendClientMessage(playerid, -1, "Mascarados Online:");
    new sstr[60];
    for(new i; i < SLOTS; ++i)
    {
        if(IsPlayerConnected(i))
        {
           if(Mascarado[i] == 1)
           {
              GetPlayerName(playerid, Nome, sizeof(Nome));
              format(sstr, sizeof(sstr), "%s[%i]", Nome, playerid);
              SendClientMessage(playerid, -1, sstr);
          }
       }
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)