FTP in audio stream?
#1

Hi there & thx for reading this,

I was just wondering if it is possible to use the FTP protocol in PlayAudioStreamForPlayer.
Like this:
pawn Код:
PlayAudioStreamForPlayer(playerid, "ftp://user:pass@name/files/music/example.mp3");
It would be great if someone could tell me.

Thanks and have a nice day!
Reply
#2

I guess it works?
Would be pretty cool at least. Try it out
Reply
#3

Quote:
Originally Posted by CookieJar
Посмотреть сообщение
I guess it works?
Would be pretty cool at least. Try it out
Ty

The problem is, when I got to try it out I got to setup an FTP server. In order to use FTP I need to forward port 21. When I forward it, I have to restart my router which will cause all the local IP's in my network to change. Because I'm also hosting the MP3 files for THIS script, I can't permit to do that because it takes some time to restore everything

(Btw: I can't configure DHCP in my network so I can't assign static IP's to my computers )
Reply
#4

Buying a FTP server is the best choise.
Reply
#5

Quote:
Originally Posted by ricardo178
Посмотреть сообщение
Buying a FTP server is the best choise.
True
I'll try to setup a free webhost with FTP to test it btw.
Reply
#6

Have you considered uploading your files on a storage site? DropBox for example. Also, if you don't have DHCP then all your computers must have a static ip, because DHCP is Dynamic Host Configuration Protocol
Reply
#7

Quote:
Originally Posted by Vince
Посмотреть сообщение
Have you considered uploading your files on a storage site? DropBox for example. Also, if you don't have DHCP then all your computers must have a static ip, because DHCP is Dynamic Host Configuration Protocol
Thanks for the tip about DropBox!
And, I think I gotta learn some more about DHCP lol

Thank you,

J.
Reply
#8

SA-MP uses the bass audio library and I am assuming BASS_StreamCreateURL in order to play the audio stream.
Quote:

url URL of the file to stream. Should begin with "http://" or "https://" or "ftp://", or another add-on supported protocol.

So I would say it's worth giving a try, just be warned that the client will see whatever username/password you use to FTP.
Reply
#9

Quote:
Originally Posted by h02
Посмотреть сообщение
SA-MP uses the bass audio library and I am assuming BASS_StreamCreateURL in order to play the audio stream.


So I would say it's worth giving a try, just be warned that the client will see whatever username/password you use to FTP.
That's true about the username & pass.

Thank you!!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)