#1

it's not playing the music.
Don't get it.
Код:
[17:35:29] sscanf warning: Strings without a length are deprecated, please add a destination size.
[17:35:29] sscanf warning: String buffer overflow.
Код:
COMMAND:audio(playerid,params[])
{
	new URL[250];
	if (APlayerData[playerid][PlayerLevel] >= 7)
        if(sscanf(params,"s",URL)) return SendClientMessage(playerid,0xFF0000AA,"USAGE:/audio [URL]");
	for(new i=0;i<MAX_PLAYERS;i++)
	{
	    if(!IsPlayerConnected(i)) continue;
	    PlayAudioStreamForPlayer(i,URL);
	}
	SendClientMessage(playerid,0xFF0000AA,"You have played a song for all players!");
	format(cmdstr, sizeof(cmdstr), "Admin %s has started the Global Playback of{FFFFFF} %s",        FormatName(playerid), URL);
	SendClientMessageToAll(0xFF0000AA, cmdstr);
	return 1;
}
Plz edit code
Reply
#2

pawn Код:
COMMAND:audio(playerid,params[])
{
    new URL[250];
    if (APlayerData[playerid][PlayerLevel] >= 7)
        if(sscanf(params,"s[250]",URL)) return SendClientMessage(playerid,0xFF0000AA,"USAGE:/audio [URL]");
    for(new i=0;i<MAX_PLAYERS;i++)
    {
        if(IsPlayerConnected(i)) PlayAudioStreamForPlayer(i,URL);
    }
    SendClientMessage(playerid,0xFF0000AA,"You have played a song for all players!");
    format(cmdstr, sizeof(cmdstr), "Admin %s has started the Global Playback of{FFFFFF} %s",        FormatName(playerid), URL);
    SendClientMessageToAll(0xFF0000AA, cmdstr);
    return 1;
}
Reply
#3

Thank you so much.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)