Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*==============================================================================
- | Music System By RandomDude. |
- | Keep My Credits |
- | Enjoy! |
- | LOL |
- ==============================================================================*/
- #include <a_samp>
- #include <zcmd>
- #define ORANGE 0xFF9933AA
- #define RED 0xAA3333AA
- #if defined FILTERSCRIPT
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print("Music System By RandomDude.");
- print("--------------------------------------\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- #else
- #endif
- public OnPlayerSpawn(playerid)
- {
- SendClientMessage(playerid,ORANGE,"[UPDATION]/musiccmds for music commands!");
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- SendClientMessage(playerid,ORANGE,"Don't Worry The Music is still playing.");
- return 1;
- }
- public OnPlayerText(playerid, text[])
- {
- return 1;
- }
- CMD:musiccmds(playerid,params[])
- {
- SendClientMessage(playerid,ORANGE,"Songs By Wiz Khalifa! Let It Go-/letigo. Black And Yellow-/blackyellow. Roll Up-/rollup Work Hard Play Hard-/Work");
- SendClientMessage(playerid,ORANGE,"Wild and Free-/wild. On My Level-/onmylevel.");
- return 1;
- }
- CMD:stopmusic(playerid,params[])
- {
- YoutubeStopStreamForPlayer(playerid);
- return 1;
- }
- //=======================================MUSIC COMMANDS FOR IN GAME FOR WIZ KHALIFA========================================
- CMD:letitgo(playerid,params[])
- {
- StreamA(playerid);
- SendClientMessage(playerid,ORANGE,"Let It Go By Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- CMD:blackyellow(playerid,params[])
- {
- StreamB(playerid);
- SendClientMessage(playerid,ORANGE,"Black and Yellow by Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- CMD:rollup(playerid,params[])
- {
- StreamC(playerid);
- SendClientMessage(playerid,ORANGE,"Roll Up by Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- CMD:work(playerid,params[])
- {
- StreamD(playerid);
- SendClientMessage(playerid,ORANGE,"Work Hard Play Hard by Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- CMD:wild(playerid,params[])
- {
- StreamE(playerid);
- SendClientMessage(playerid,ORANGE,"Wild and Free by Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- CMD:onmylevel(playerid,params[])
- {
- StreamF(playerid);
- SendClientMessage(playerid,ORANGE,"On My Level by Wiz Khalifa will start in a few seconds.");
- SendClientMessage(playerid,RED,"If you are going to leave the server and have music playing you will crash /stopmusic before you leave");
- return 1;
- }
- //=============================================================Streams For Wiz Khalifa================================================================================================================
- StreamA(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=IJn-EHd7VeU");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- StreamB(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=UePtoxDhJSw");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- StreamC(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=UhQz-0QVmQ0");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- StreamD(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=TWHNr0BrNgo");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- StreamE(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=Wa5B22KAkEk");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- StreamF(playerid){
- YoutubeStreamForPlayer(playerid,"http://www.youtube.com/watch?v=hmP7TYtDVUU");
- SendClientMessage(playerid,0x55ffaaff,"Please wait a couple of seconds and the song will start also do not leave without typing /stopmusic because it pauses you on the esc menu if you don't.");
- return 1;
- }
- //===============================================Stocks For Streamer To Work===============================================
- stock YoutubeStreamForPlayer(playerid, vlink[])
- {
- new videoid[128], mp3link[128];
- strmid(videoid,vlink,strfind(vlink,"v=")+2,strfind(vlink,"v=")+15);
- format(mp3link, 128, "http://mwrserver.com/youtube.php?videoid=%s", videoid);
- PlayAudioStreamForPlayer(playerid,mp3link);
- return 1;
- }
- stock YoutubeStreamForAll(vlink[])
- {
- new videoid[128], mp3link[128];
- strmid(videoid,vlink,strfind(vlink,"v=")+2,strfind(vlink,"v=")+15);
- format(mp3link, 128, "http://mwrserver.com/youtube.php?videoid=%s", videoid);
- for(new i=0;i<MAX_PLAYERS;i++) PlayAudioStreamForPlayer(i,mp3link);
- return 1;
- }
- stock YoutubeStopStreamForAll()
- {
- for(new i=0;i<MAX_PLAYERS;i++)
- {
- StopAudioStreamForPlayer(i);
- }
- return 1;
- }
- stock YoutubeStopStreamForPlayer(playerid)
- {
- StopAudioStreamForPlayer(playerid);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement