Help - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help (
/showthread.php?tid=482338)
Help -
Gill - 20.12.2013
Why it doesn't work? I need explanation, Thank you.
pawn Код:
CMD:streamaudio(playerid, params[])
{
new string[128];
if(sscanf(params, "s[256]", params)) return SendClientMessage(playerid, -1,"{FF8000}ERROR{FFFFFF}: /stream [url]");
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "{AA3333}You are not an RCON Admin.");
format(string, sizeof(string), "An admin has started global song.[ /stopmusic to stop listening ]");
SendClientMessageToAll( 0xFFFF00AA, string);
foreach(Player, i)
{
PlayAudioStreamForPlayer(i, params);
}
return 1;
}
It's not abour URL isn't working.. when I type '/streamaudio .' it never displays any green text saying. 'Streaming:.' I don' know why!
Re: elp. -
Zamora - 20.12.2013
Maybe your song's URL is not streamed..?
Re: elp. -
Gill - 20.12.2013
Quote:
Originally Posted by Zamora
Maybe your song's URL is not streamed..?
|
It's not abour URL isn't working.. when I type '/streamaudio .' it never displays any green text saying. 'Streaming:.' I don' know why!
Re: Help -
SilentSoul - 20.12.2013
Let's check the error by debugging
pawn Код:
CMD:streamaudio(playerid, params[])
{
new string[128];
if(sscanf(params, "s[256]", params)) return SendClientMessage(playerid, -1,"{FF8000}ERROR{FFFFFF}: /stream [url]");
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "{AA3333}You are not an RCON Admin.");
format(string, sizeof(string), "An admin has started global song.[ /stopmusic to stop listening ]");
SendClientMessageToAll( 0xFFFF00AA, string);
foreach(Player, i)
{
PlayAudioStreamForPlayer(i, params);
}
printf("-Audio debug: %s",params);//this will show or help us to find the error
return 1;
}
And show me the server console logs after using this command
EDIT : I think test it for you now , and working fine for me , make sure that your url are working fine.