[MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 08.06.2014
[MV]_*******
Intro:
Yes, i know. Another ******* streamer. However I wanted to make one on my own and I did it. It's a while ago I released something so here is something new ...
Info:
With this include you can simply stream ******* video's to your SA:MP server. Easy to set up and 1 video is playable with 1 line of code. You can play it for 1 person or for the whole server. Next to all this, when you play a song, the details of the song gets displayed on the screen of the player(s).
Functions
How does this shizzle work ?
Example code
Latest up-to-date always:
Github
Re: [MV]_******* | Simple but yet useful ******* streamer -
TonyNames - 08.06.2014
Hmm looks nice. Keep it up
Re: [MV]_******* | Simple but yet useful ******* streamer -
Basssiiie - 08.06.2014
Looks good! What is exactly wrong with those HTTP parameters? And isn't it possible to filter them out if they are used in the input anyway?
Re: [MV]_******* | Simple but yet useful ******* streamer -
iZN - 08.06.2014
Would be great if you used sscanf. Appreciate it though, I was looking for some perfect API, I haven't heard about this API.
Re: [MV]_******* | Simple but yet useful ******* streamer -
Hessan - 08.06.2014
well done!
Re: [MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 09.06.2014
Quote:
Originally Posted by Basssiiie
Looks good! What is exactly wrong with those HTTP parameters? And isn't it possible to filter them out if they are used in the input anyway? 
|
You're right. I updated it - The problem was, when you had more parameters in the URL, that the server could crash.
Respuesta: [MV]_******* | Simple but yet useful ******* streamer -
Swedky - 09.06.2014
Well done!
Why you don't add:
pawn Код:
forward OnAudioPlayerFinish(playerid);
Well, if it is possible

. +3.
Re: Respuesta: [MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 10.06.2014
Quote:
Originally Posted by EnzoMetlc
Well done!
Why you don't add:
pawn Код:
forward OnAudioPlayerFinish(playerid);
Well, if it is possible  . +3.
|
Good idea ! #Updated
Re: [MV]_******* | Simple but yet useful ******* streamer -
Jochemd - 10.06.2014
y u use explode y u no use sscanf
Respuesta: [MV]_******* | Simple but yet useful ******* streamer -
TR0J4N - 11.06.2014
Nice job!!!
Re: [MV]_******* | Simple but yet useful ******* streamer -
Niko_boy - 11.06.2014
Good job. I liked the use of seconds for Playback finish :P
Re: [MV]_******* | Simple but yet useful ******* streamer -
Admigo - 11.06.2014
Does all ******* links work like copyrighted music?
Re: [MV]_******* | Simple but yet useful ******* streamer -
iRaiDeN - 11.06.2014
Wow nice job, rather than explode could use sscanf faster and more convenient, the code nicely organized and programmed in a good way, very beautiful!
Respuesta: [MV]_******* | Simple but yet useful ******* streamer -
Reynolds - 02.07.2014
Quote:
Does all ******* links work like copyrighted music?
|
I would suppose music which is copyrighted in the country the server is hosted in would not play.
Re: [MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 04.07.2014
Quote:
Originally Posted by iZN
Would be great if you used sscanf. Appreciate it though, I was looking for some perfect API, I haven't heard about this API.
|
Quote:
Originally Posted by Jochemd
y u use explode y u no use sscanf
|
Quote:
Originally Posted by iRaiDeN
Wow nice job, rather than explode could use sscanf faster and more convenient, the code nicely organized and programmed in a good way, very beautiful!
|
I've searched and tested my ass off to implement sscanf. I can't find a way to let it work with sscanf. The explode function is the easiest and probably the only way.
Quote:
Originally Posted by Admigo
Does all ******* links work like copyrighted music?
|
It should i guess. Just test it with a copyrighted video.
Re: [MV]_******* | Simple but yet useful ******* streamer -
doreto - 04.07.2014
Good job Michael. Here are few of mine suggestions:
- Is*******VideoPlaying - self explain return true or false
- GetLengthOfVideo - return in seconds length of video
- GetVideoTitle - return the name of video
Re: [MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 07.07.2014
Quote:
Originally Posted by doreto
Good job Michael. Here are few of mine suggestions: - Is*******VideoPlaying - self explain return true or false
- GetLengthOfVideo - return in seconds length of video
- GetVideoTitle - return the name of video
|
Sweet ! Nice idea's. However, GetLengthOfVideo and GetVideoTitle, do you mean from the current song that's playing or not ?
Re: [MV]_******* | Simple but yet useful ******* streamer -
K9IsGodly - 08.07.2014
I am getting An Error has occurred: 6 for these commands when I use them in game. They compile fine and all so I don't see what this means. Was hoping you could help.
Код:
CMD:playsong(playerid, params[])
{
new ylink[50];
if(sscanf(params,"s[50]",ylink)) return SendClientMessage(playerid, -1, "/playsong [******* URL]");
if(strlen(ylink) > 50) return SendClientMessage(playerid, -1, "That link is too long!");
Play*******VideoForPlayer(playerid,ylink);
return 1;
}
CMD:adminsong(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 6)
{
new ylink[50];
if(sscanf(params,"s[50]",ylink)) return SendClientMessage(playerid, -1, "/adminsong [******* URL]");
if(strlen(ylink) > 50) return SendClientMessage(playerid, -1, "That link is too long!");
for(new i = 0; i != MAX_PLAYERS; ++i)
{
if(IsPlayerConnected(i))
{
Play*******VideoForPlayer(i,ylink);
}
return 1;
}
else
{
SendClientMessage(playerid, -1, "You are not a high enough level administrator to use this command!");
}
return 1;
}
Re: [MV]_******* | Simple but yet useful ******* streamer -
Michael@Belgium - 09.07.2014
Quote:
Originally Posted by doreto
Good job Michael. Here are few of mine suggestions: - Is*******VideoPlaying - self explain return true or false
- GetLengthOfVideo - return in seconds length of video
- GetVideoTitle - return the name of video
|
#updated2.0
Quote:
Originally Posted by K9IsGodly
I am getting An Error has occurred: 6 for these commands when I use them in game. They compile fine and all so I don't see what this means. Was hoping you could help.
|
It's not your code but it's something with the API. On certain songs it does a redirect but I don't know the reason why it does that. Maybe it does check if the video has copyright or not ...
Your solution is: find another video of that song. Maybe then it'll work.
Re: [MV]_******* | Simple but yet useful ******* streamer -
Battlezone - 09.07.2014
Quote:
Originally Posted by Admigo
Does all ******* links work like copyrighted music?
|
No, it certainly won't, because ******* is directly steraming data to you, it would work only if ******* transfers data to another server located in a location where the video is not blocked, and that server streams the song to you..