if(fexist(UserPath(playerid)))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_WHITE"Type your password below to login.","Login","Quit");//720
}
else
{
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,""COL_WHITE"Registering...",""COL_WHITE"Type your password below to register a new account.","Register","Quit");
}
pwn(720) : error 001: expected token: "-string end-", but found "-identifier-" pwn(720) : error 017: undefined symbol "COL_WHITE" pwn(720) : warning 215: expression has no effect pwn(720) : error 001: expected token: "-string end-", but found "-identifier-" pwn(720) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
if(fexist(UserPath(playerid)))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,"{FFFFFF}Login","{FFFFFF}Type your password below to login.","Login","Quit");//720
}
else
{
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,"{FFFFFF}Registering...","{FFFFFF}Type your password below to register a new account.","Register","Quit");
}
E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 017: undefined symbol "gTeam" E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : warning 215: expression has no effect E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 001: expected token: ";", but found "]" E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 029: invalid expression, assumed zero E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
CMD:tazer(playerid, params[])
{
if(gTeam[playerid] == LSPD) // For cops //981
{
if(IsPlayerInAnyVehicle(playerid)) // Checks if the player is in a vehicle.
{
SendClientMessage(playerid, 0xFF0000FF, "You can't use this command while in a car!");
return 1;
}
if(pTazer[playerid] == 0) // If the player has no tazer withdrawn.
{
GivePlayerWeapon(playerid, 23, 9999); // Gives a SD.
pTazer[playerid] = 1; // Sets the var to true.
return 1;
}
else if(pTazer[playerid == 1) // If the player has the tazer withdrawn to holster it.
{
GivePlayerWeapon(playerid, 24, 250); // Gives a deagle.
pTazer[playerid] = 0; // Sets the var to false.
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "You are not a cop!");
}
return 1;
}
|
@X337 tried your solution and it worked. But now i have another error with gTeam which is only in 1 command the other cmds which use gTeam don't have those errors.
Код:
E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 017: undefined symbol "gTeam" E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : warning 215: expression has no effect E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 001: expected token: ";", but found "]" E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : error 029: invalid expression, assumed zero E:\backup\SFCRRPG\gamemodes\Sandhu.pwn(981) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors. Код:
CMD:tazer(playerid, params[])
{
if(gTeam[playerid] == LSPD) // For cops //981
{
if(IsPlayerInAnyVehicle(playerid)) // Checks if the player is in a vehicle.
{
SendClientMessage(playerid, 0xFF0000FF, "You can't use this command while in a car!");
return 1;
}
if(pTazer[playerid] == 0) // If the player has no tazer withdrawn.
{
GivePlayerWeapon(playerid, 23, 9999); // Gives a SD.
pTazer[playerid] = 1; // Sets the var to true.
return 1;
}
else if(pTazer[playerid == 1) // If the player has the tazer withdrawn to holster it.
{
GivePlayerWeapon(playerid, 24, 250); // Gives a deagle.
pTazer[playerid] = 0; // Sets the var to false.
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "You are not a cop!");
}
return 1;
}
|
else if(pTazer[playerid] == 1) // If the player has the tazer withdrawn to holster it.
public OnPlayerRequestClass(playerid, classid)
{
SetSpawnInfo();
SpawnPlayer();
return 1;
}