SA-MP Forums Archive
PlayAudioStreamForPlayer not playing - 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: PlayAudioStreamForPlayer not playing (/showthread.php?tid=319475)



PlayAudioStreamForPlayer not playing - HighFlyer - 19.02.2012

Hello there,

PlayAudioStreamForPlayer is a fairly new feature, and I am using it for the first time. It seems that however I'm having trouble with setting it up. The native client green message appears that the stream is playing, however I cannot hear it. As researched, some people had trouble with Audio apparently being totally quiet, however mine's set to full and I'm lost about where I could have gone wrong. I'd appreciate any help, cheers.

Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
	if(dialogid == RADIO)
	{
		if(response)
		{
			if(listitem == 0)// (BBC Radio 1)
			{
                        ShowPlayerDialog(playerid, RADIO_CONFIRM, DIALOG_STYLE_MSGBOX,"BBC Radio 1 (United Kingdom)","{3399FF}You are now tuned into BBC Radio 1\n{FFFFFF}The Best New Music And Entertainment\n(98.1FM San Andreas)", "OK", "");
                        PlayAudioStreamForPlayer(playerid, "http://www.bbc.co.uk/radio/listen/live/r1.pls");
			}
                        // rest of stations
                        // ..............
			if(listitem == 8) // (STOP RADIO)
			{
                        StopAudioStreamForPlayer(playerid);
   			}
   			return 1;
     }



Re: PlayAudioStreamForPlayer not playing - Mark™ - 19.02.2012

Quote:
Originally Posted by HighFlyer
Посмотреть сообщение
Hello there,

PlayAudioStreamForPlayer is a fairly new feature, and I am using it for the first time. It seems that however I'm having trouble with setting it up. The native client green message appears that the stream is playing, however I cannot hear it. As researched, some people had trouble with Audio apparently being totally quiet, however mine's set to full and I'm lost about where I could have gone wrong. I'd appreciate any help, cheers.

Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
	if(dialogid == RADIO)
	{
		if(response)
		{
			if(listitem == 0)// (BBC Radio 1)
			{
                        ShowPlayerDialog(playerid, RADIO_CONFIRM, DIALOG_STYLE_MSGBOX,"BBC Radio 1 (United Kingdom)","{3399FF}You are now tuned into BBC Radio 1\n{FFFFFF}The Best New Music And Entertainment\n(98.1FM San Andreas)", "OK", "");
                        PlayAudioStreamForPlayer(playerid, "http://www.bbc.co.uk/radio/listen/live/r1.pls");
			}
                        // rest of stations
                        // ..............
			if(listitem == 8) // (STOP RADIO)
			{
                        StopAudioStreamForPlayer(playerid);
   			}
   			return 1;
     }
are you sure the url you provided is working ?


Re: PlayAudioStreamForPlayer not playing - HighFlyer - 19.02.2012

Yup, all of them work, I have about 6-7 more.


Re: PlayAudioStreamForPlayer not playing - acade - 19.02.2012

Check your radio in your GTA settings, the volume I mean.


Re: PlayAudioStreamForPlayer not playing - seanny - 19.02.2012

As far as I heard, Audio stream was for Shoutcast\Icecast radios, not national radios.


Re: PlayAudioStreamForPlayer not playing - Mark™ - 19.02.2012

Quote:
Originally Posted by seanny
Посмотреть сообщение
As far as I heard, Audio stream was for Shoutcast\Icecast radios, not national radios.
yeah and BBC radio is available on shoutcast.


Re: PlayAudioStreamForPlayer not playing - HighFlyer - 19.02.2012

Quote:
Originally Posted by acade
Посмотреть сообщение
Check your radio in your GTA settings, the volume I mean.
As said already, it's on full...

Quote:
Originally Posted by seanny
As far as I heard, Audio stream was for Shoutcast\Icecast radios, not national radios
I heard that .pls streams generally work. All 7 radios I have are in .pls and all 6 apart from the one I provided in this topic, are non-national radios.


Re: PlayAudioStreamForPlayer not playing - Mark™ - 19.02.2012

Quote:
Originally Posted by HighFlyer
Посмотреть сообщение
As said already, it's on full...



I heard that .pls streams generally work. All 7 radios I have are in .pls and all 6 apart from the one I provided in this topic, are non-national radios.
pls have unique ids at the end like ==>> .pls?id = 269853


Re: PlayAudioStreamForPlayer not playing - HighFlyer - 19.02.2012

It should generally work without any ID's, as logically, any media player such as VLC captures them and plays them. Same with the Audio Plugin, it worked before with the Audio_PlayStreamed native. I thought it'd be easier if I could give people the 0.3d format.


Re: PlayAudioStreamForPlayer not playing - Mark™ - 19.02.2012

Quote:
Originally Posted by HighFlyer
Посмотреть сообщение
It should generally work without any ID's, as logically, any media player such as VLC captures them and plays them. Same with the Audio Plugin, it worked before with the Audio_PlayStreamed native. I thought it'd be easier if I could give people the 0.3d format.
Yeah it works in VLC, dont understand why its not working in your script.