Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*==============================================================================
- ** SA-MP (0.3.7) MexRadio Filterscript v1.0
- ** By: DragonZafiro/NeloAngelo
- ** Created: 04/03/16
- ** Last modified: 17/03/16
- ==============================================================================*/
- #include <a_samp>
- #include <zcmd>
- #include <YSI\y_colours>
- #define COLOR_ADVICE X11_RED
- #define COLOR_SUCCESS X11_LIMEGREEN
- #define PLAIN_TEXT "{FFFAFA}"
- #define M_TEXT "{808080}"
- #define M_TITLE "{45FF00}"
- #define DIALOG_MENU 50
- #define DIALOG_GEN 51
- #define MAX_SONGS 10 // Max Songs per category, must be the same on ALL CATEGORIES
- // Definition for isnull():
- #if !defined isnull
- #define isnull(%1) ((!(%1[0])) || (((%1[0]) == '\1') && (!(%1[1]))))
- #endif
- new selected[MAX_PLAYERS];
- new _mString[][][] =
- {
- { // BLUES
- "Megaton Cafe Radio", "http://us1.internet-radio.com:8390/",
- "Midnight Special Blues Radio", "http://uk2.internet-radio.com:8209/",
- "Non Stop Hits From All Eras", "http://uk3.internet-radio.com:8060/",
- "Duo.Click Radio", "http://us1.internet-radio.com:8352/",
- "RadioWahWah", "http://uk1.internet-radio.com:8144/",
- "Aardvark Blues FM", "http://74.208.45.146:8639/",
- "Blues Radio", "http://37.59.14.77:8352/",
- "SuperBluesRadio.Com", "http://109.169.54.86:8036/",
- "Bar Legend Radio", "http://50.7.98.106:8719/",
- "Joint Radio Blues", "http://72.9.152.111:9992/"
- },
- { // CLASSICAL
- "Venice Classic Radio Italia", "http://109.123.116.202:8022/",
- "Audiophile Baroque", "http://213.251.157.145:8016/",
- "Ancient FM","http://simplexstream.com:8058/",
- "CFMZ","http://199.27.180.216:8019/",
- "ABC Radio 89.2","http://192.235.87.105:14424/",
- "Classical WETA 90.9 FM","http://38.100.128.106:8000/",
- "Hi On Line Classic Radio","http://82.94.166.107:8088/",
- "Abacus Lute","http://91.121.166.38:7250/",
- "AddictedToRadio.com - Classical Channel","http://208.77.21.33:14510/",
- "OM Radio","http://178.168.28.148:8000/"
- },
- { // ROCK
- "SHE Radio","http://us1.internet-radio.com:8105/",
- "Box UK Radio","http://uk2.internet-radio.com:31076/",
- "STAR FM Maximum Rock ","http://87.230.53.43:8000/",
- "New Country 93","http://173.192.70.138:9170/",
- "4U Classic Rock ","http://217.114.200.100:80/",
- "Ghanansem FM","http://38.96.148.254:8878/",
- "Rockin' Planet Radio","http://us1.internet-radio.com:8396/",
- "Music Tripper","http://us1.internet-radio.com:8220/",
- "Radio RFM SENEGAL","http://192.235.87.113:11446/",
- "Arrow Classic Rock","http://91.221.151.237:8107/"
- },
- { // HEAVY METAL
- "The KILL.IM", "http://us1.internet-radio.com:8224/",
- "Alchemical Internet Radio", "http://uk3.internet-radio.com:11048/",
- "The VIRAL.IM","http://us1.internet-radio.com:8034/",
- "Metal Devastation Radio","http://188.40.32.140:8061/",
- "Braingell Radio","http://206.217.213.16:8010/",
- "STAR FM Maximum Rock","http://91.250.82.237:7000/",
- "Party at Dans","http://208.80.53.106:31560/",
- "Femmetal Online","http://173.236.59.83:8510/",
- "Tyrant Metal Radio","http://5.39.71.159:8440/",
- "ADMM Metal Music Radio","http://www.icastcenter.com/cast/tunein.php/wendigo/playlist.pls"
- }
- };
- #define mString[%0][%1][%2] _mString[%0][(2 * (%1)) + (%2)]
- CMD:music(playerid, params[])
- {
- return cmd_radio(playerid, params);
- }
- CMD:radio(playerid, params[])
- {
- ShowPlayerDialog(playerid, DIALOG_MENU, DIALOG_STYLE_LIST, ""M_TITLE"Select Category:", "Blues\nClassical\nRock\nHeavy Metal", "Select", "Cancel");
- return 1;
- }
- CMD:stopradio(playerid, params[])
- {
- StopAudioStreamForPlayer(playerid);
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- switch(dialogid)
- {
- case DIALOG_MENU:
- {
- new genString[1000];
- if(response)
- {
- genString = "";
- for(new i = 0; i < MAX_SONGS; i++)
- {
- if(!isnull(mString[listitem][i][0]))
- strcat(genString, "{FF0000}• {FAFAFA}");
- strcat(genString, mString[listitem][i][0]);
- strcat(genString, "\n");
- }
- selected[playerid] = listitem;
- ShowPlayerDialog(playerid, DIALOG_GEN, DIALOG_STYLE_LIST, ""M_TITLE"Select Radio:", genString, "Select", "Cancel");
- }
- }
- case DIALOG_GEN:
- {
- if(response)
- {
- new str[100];
- format(str, 100, "-> "PLAIN_TEXT"Now Playing: "M_TITLE"%s", mString[selected[playerid]][listitem][0]);
- SendClientMessage(playerid, COLOR_SUCCESS, str);
- PlayAudioStreamForPlayer(playerid, mString[selected[playerid]][listitem][1]);
- SendClientMessage(playerid, COLOR_ADVICE, "[!]: "PLAIN_TEXT"Use "M_TEXT"/StopRadio "PLAIN_TEXT"to stop the radio.");
- }
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement