SA-MP Forums Archive
How do I find the stream URL? - 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: How do I find the stream URL? (/showthread.php?tid=303649)



How do I find the stream URL? - Scarred - 14.12.2011

I'm trying to use PlayStreamForPlayer, but uhhh, how do I find the stream URL from a page like-

http://player.rogersradio.ca/ckby/recently_played
(y101.fm)
?


Re: How do I find the stream URL? - Rob_Maate - 14.12.2011

You'll need to look up an online-streaming directory.
I'm australian so I only know our directory, I would have no idea what canada's is


Re: How do I find the stream URL? - Scarred - 14.12.2011

Quote:
Originally Posted by Rob_Maate
Посмотреть сообщение
You'll need to look up an online-streaming directory.
I'm australian so I only know our directory, I would have no idea what canada's is
Right, so something like:

http://www.thestreamcenter.com/canad....asp?name=Y101, which tells me the streaming URL is:

http://50.16.245.200/flv2ckby_live.mp3?


Re: How do I find the stream URL? - Rob_Maate - 14.12.2011

Precisely

You'll also need to verify it's in MP3/OGG format (i THINK that's the accepted formats)

of course it's always easier to just go IG and test it


Re: How do I find the stream URL? - Scarred - 14.12.2011

Quote:
Originally Posted by Rob_Maate
Посмотреть сообщение
Precisely

You'll also need to verify it's in MP3/OGG format (i THINK that's the accepted formats)

of course it's always easier to just go IG and test it
Well thank you! The only problem is the following code isn't working for some odd reason:

pawn Код:
PlayAudioStreamForPlayer(playerid, "http://50.16.245.200/flv2ckby_live.mp3", 0, 0, 0, 50, 0);
Oh, and +rep'd for helping me find that.


Re: How do I find the stream URL? - Rob_Maate - 15.12.2011

Well... Try this:

pawn Код:
CMD:play(playerid, params[])
{
    if(IsPlayerAdmin(playerid))
    {
        for(new i=0; i<MAX_PLAYERS; i++)
        {
            PlayAudioStreamForPlayer(i, params, 0.0, 0.0, 0.0, 0.0, 0);
        }
    }
    return 1;
}
That will play the entered audio stream for ALL players online.

Go IG, type /play http://50.16.245.200/flv2ckby_live.mp3

Wait a minute to allow it to load

You SHOULD get a readout in green @ your chatfeed of the URL, and soon after you should hear the content.

If that works, it's probably just a bugged bit of scripting