Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- SA:MP Audio Radio Stream Filterscript
- ************** ÖSIRADIO **************
- by
- petmax113
- ULLLIIK (Errorfixxing und mein Scriptinglehrer^^)
- #Credits dürfen nicht gelöscht werden!!!
- */
- #include <a_samp>
- #include <UC>
- #pragma tabsize 0
- #define FILTERSCRIPT
- #define ERROR_COLOR 0xFF4A26FF
- #define RIGHT_COLOR 0xD7FF00FF
- #define DIALOG_RADIO_OFF 2252
- #define DIALOG_RADIO_ON 2253
- #define MAX_DISTANCE 2600.80
- #define ShowDialogOn(%0); ShowPlayerDialog(%0, DIALOG_RADIO_ON, DIALOG_STYLE_LIST, "Österreichischer Radio","Hitradio Ö3\nKronehit\nFM4\nÖ1\nCampus Radio\nHIT FM\nRadio Arabella Party\nBigvibez Radio(Reggae)","Play","Quit");
- #define ShowDialogOff(%0); ShowPlayerDialog(%0, DIALOG_RADIO_OFF, DIALOG_STYLE_LIST, "{FF1E00}Österreichischer Radio","{FF1E00}Radio ausschalten\nHitradio Ö3\nKronehit\nFM4\nÖ1\nCampus Radio\nHIT FM\nRadio Arabella Party\nBigvibez Radio(Reggae)","Play","Quit");
- #define Message(%0); new string[180];\
- format(string, sizeof string, "Du hast gerade folgenden Sender eingeschalten: %s",#%0);\
- SendClientMessage(playerid,RIGHT_COLOR,string);
- new bool:RSTAT[MAX_PLAYERS];
- UC-carradio(playerid,params[])
- {
- if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,ERROR_COLOR,"Du befindest dich nicht in einem Auto!");
- PlayerPlaySound(playerid,1150,0,0,1);
- if(RSTAT[playerid] == true)
- {
- ShowDialogOff(playerid);
- }
- else
- {
- ShowDialogOn(playerid);
- }
- r1
- }
- public OnDialogResponse(playerid,dialogid,response,listitem,inputtext[])
- {
- if(dialogid==DIALOG_RADIO_ON)
- {
- if(!response) return 1;
- if(!IsPlayerInRangeOfPoint(playerid,MAX_DISTANCE,1594.1421,-1223.3630,17.4535)) return SendClientMessage(playerid,ERROR_COLOR,"Du bist außerhalb der Sendefrequenz!.");
- RSTAT[playerid]=true;
- switch(listitem)
- {
- case 0://Hitradio
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream7.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Hitradio Ö3);
- r1
- }
- case 1://Kronehit
- {
- PlayAudioStreamForPlayer(playerid,"http://onair.krone.at/kronehit-hd.mp3.m3u",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Kronehit);
- r1
- }
- case 2://FM4
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream1.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(FM4);
- r1
- }
- case 3://Ö1
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream3.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Ö1);
- r1
- }
- case 4://Campus Radio
- {
- PlayAudioStreamForPlayer(playerid,"http://streamer.campusradio.at/campusradio.m3u",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Campus Radio);
- r1
- }
- case 5://Hit FM
- {
- PlayAudioStreamForPlayer(playerid,"http://hitfm.biosnet.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Hit FM);
- r1
- }
- case 6://Radio Arabella Party
- {
- PlayAudioStreamForPlayer(playerid,"http://stream06.arabella.vss.kapper.net:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Radio Arabella Party);
- r1
- }
- case 7://Beatvibez Radio(Reggae)
- {
- PlayAudioStreamForPlayer(playerid,"http://streams.bigvibez.com:7000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Beatvibez Radio[Reggae]);
- r1
- }
- }
- }
- if(dialogid==DIALOG_RADIO_OFF)
- {
- if(!response) return 1;
- if(!IsPlayerInRangeOfPoint(playerid,MAX_DISTANCE,1594.1421,-1223.3630,17.4535)) return SendClientMessage(playerid,ERROR_COLOR,"Du bist außerhalb der Sendefrequenz!.");
- RSTAT[playerid]=true;
- switch(listitem)
- {
- case 0://Stopradio
- {
- StopAudioStreamForPlayer(playerid);
- RSTAT[playerid]=false;
- r1
- }
- case 1://Hitradio
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream7.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Hitradio Ö3);
- r1
- }
- case 2://Kronehit
- {
- PlayAudioStreamForPlayer(playerid,"http://onair.krone.at/kronehit-hd.mp3.m3u",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Kronehi4t);
- r1
- }
- case 3://FM4
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream1.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(FM4);
- r1
- }
- case 4://Ö1
- {
- PlayAudioStreamForPlayer(playerid,"http://mp3stream3.apasf.apa.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Ö1);
- r1
- }
- case 5://Campus Radio
- {
- PlayAudioStreamForPlayer(playerid,"http://streamer.campusradio.at/campusradio.m3u",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Campus Radio);
- r1
- }
- case 6://Hit FM
- {
- PlayAudioStreamForPlayer(playerid,"http://hitfm.biosnet.at:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Hit FM);
- r1
- }
- case 7://Radio Arabella Party
- {
- PlayAudioStreamForPlayer(playerid,"http://stream06.arabella.vss.kapper.net:8000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Radio Arabella Party);
- r1
- }
- case 8://Beatvibez Radio(Reggae)
- {
- PlayAudioStreamForPlayer(playerid,"http://streams.bigvibez.com:7000/listen.pls",1594.1421,-1223.3630,17.4535,MAX_DISTANCE,1);
- Message(Beatvibez Radio[Reggae]);
- r1
- }
- }
- }
- r1
- }
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print(" Österreichische Radiosender Filterscript by petmax113 & ULLLIIK loaded.");
- print("--------------------------------------\n");
- return 1;
- }
- public OnPlayerExitVehicle(playerid, vehicleid)
- {
- StopAudioStreamForPlayer(playerid);
- RSTAT[playerid] = false;
- return 1;
- }
- public OnVehicleDeath(vehicleid, killerid)
- {
- for(new i = 0; i < 500; i++)
- {
- StopAudioStreamForPlayer(i);
- RSTAT[i] = false;
- }
- r1
- }
- public OnPlayerDisconnect(playerid,reason)
- {
- StopAudioStreamForPlayer(playerid);
- RSTAT[playerid]=false;
- r1
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement