07.07.2017, 21:24
42877) : error 029: invalid expression, assumed zero
42877) : error 017: undefined symbol "URL"
42877) : warning 215: expression has no effect
42877) : error 001: expected token: ";", but found "]"
42877) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
4 Errors.
line is:
42877) : error 017: undefined symbol "URL"
42877) : warning 215: expression has no effect
42877) : error 001: expected token: ";", but found "]"
42877) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
4 Errors.
PHP код:
CMD:play(playerid,params[]){
// if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid,COLOR_RED,"This command is only for RCON admins!");
if((PlayerInfo[playerid][Level] >= 9)
{
new URL[250];
if(sscanf(params,"s[250]",URL)) return SendClientMessage(playerid,-1,"{39AACC}USAGE: play [URL]");
for(new i=0;i<MAX_PLAYERS;i++)
{
if(!IsPlayerConnected(i)) continue;
PlayAudioStreamForPlayer(i,URL);
}
SendClientMessage(playerid,COLOR_RED,"You have played a song for all players!");
format(cmdstr, sizeof(cmdstr), "Administrator %s (ID:%d) has started the Global Playback of{FFFFFF} %s", FormatName(playerid), playerid, URL);
SendClientMessageToAll(COLOR_ORANGE, cmdstr);
SendClientMessageToAll(COLOR_YELLOW, "/stop to stop..");
}
else return SendClientMessage(playerid, yellow, "Sorry");
return 1;
}
Код:
new URL[250];