PlayAudioStreamForPlayer not playing
#1

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;
     }
Reply
#2

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 ?
Reply
#3

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

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

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

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.
Reply
#7

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.
Reply
#8

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
Reply
#9

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.
Reply
#10

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.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)