[FilterScript] Radio Stations v1.1 - With Menus
#1

Well i originally released the first version here and as i'm am going through my old releases and updating them.

I updated this so it will be easier to use while in the vehicle.

When you are in your vehicle and want a radio station to listen to then just press the key 'N' and a menu will appear, then use the arrow keys to navigate the menu, once you have decided your choice then click the 'W' key and it will select it and you can continue on with what you was doing.

Notice: If you like my work +rep, comment and share.

Features
  • 11 Radio Stations
  • Radio turns off when exiting the vehicle
  • Passenger can hear the radio
  • Menus (not Dialogs)
Radio Stations
  • Dubstep FM
  • Capital FM
  • Pulse Radio
  • Radio Klass Romania
  • Its a Trap Radio
  • Russian Hits Radio
  • Madein Hits Radio
  • Absolute Hits Radio (France)
  • DnB Pirate Radio
  • I Love To Dance Radio
  • Electronic Playground Radio
Screenshot


Its quite a simple script and should be easy to edit the stations

Download:


How To:
Edit Radios:
Find
Код:
        AddMenuItem(Radio, 0, "Dubstep FM");
	AddMenuItem(Radio, 0, "Capital FM");
	AddMenuItem(Radio, 0, "Pulse Radio");
	AddMenuItem(Radio, 0, "Radio Klass Romania");
	AddMenuItem(Radio, 0, "Its a Trap Radio");
	AddMenuItem(Radio, 0, "Russian Hits Radio");
	AddMenuItem(Radio, 0, "Madein Hits Radio");
	AddMenuItem(Radio, 0, "Absolute Hits Radio");
	AddMenuItem(Radio, 0, "DnB Pirate Radio");
	AddMenuItem(Radio, 0, "I Love To Dance Radio");
	AddMenuItem(Radio, 0, "Electronic Playground Radio");
	AddMenuItem(Radio, 0, "Turn Off");
Replace
Код:
        AddMenuItem(Radio, 0, "REPLACE ME"); // case 0
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 1
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 2
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 3
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 4
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 5
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 6
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 7
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 8
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 9
	AddMenuItem(Radio, 0, "REPLACE ME"); // case 10
	AddMenuItem(Radio, 0, "Turn Off"); // case 11
Now find under OnPlayerSelectedMenuRow
pawn Код:
case 0:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://yp.shoutcast.com/sbin/tunein-station.pls?id=40568");
        SendClientMessage(playerid, -1, "You are tuned into Dubstep FM");
    }
}
case 1:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://media-ice.musicradio.com/CapitalMP3.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Capital FM");
    }
}
case 2:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://icy3.abacast.com/pulse87-pulse87mp3-64");
        SendClientMessage(playerid, -1, "You are tuned into Pulse 87");
    }
}
case 3:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://yp.shoutcast.com/sbin/tunein-station.pls?id=7581");
        SendClientMessage(playerid, -1, "You are tuned into Radio Klass Romania");
    }
}
case 4:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3146548/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Its a Trap Radio");
    }
}
case 5:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/1891409/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Russian Hits Radio");
    }
}
case 6:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3064006/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Madein Hits Radio");
    }
}
case 7:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3367058/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Absolute Hits Radio");
    }
}
case 8:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3728175/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into DnB Pirate Radio");
    }
}
case 9:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3710153/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into I Love To Dance Radio");
    }
}
case 10:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "http://dir.xiph.org/listen/3813588/listen.m3u");
        SendClientMessage(playerid, -1, "You are tuned into Electronic Playground Radio");
    }
}
case 11:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = false;
        StopAudioStreamForPlayer(playerid);
        SendClientMessage(playerid, -1,"Music off");
    }
}
EXAMPLE
pawn Код:
case 0:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into Dubstep FM");
    }
}
case 1:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 2:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 3:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 4:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 5:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 6:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 7:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 8:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 9:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 10:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = true;
        PlayAudioStreamForPlayer(playerid, "MUSIC URL");
        SendClientMessage(playerid, -1, "You are tuned into RADIO NAME");
    }
}
case 11:
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER && PLAYER_STATE_PASSENGER)
    {
        IsRadioOn[playerid] = false;
        StopAudioStreamForPlayer(playerid);
        SendClientMessage(playerid, -1,"Music off");
    }
}
Comment and share if i helped you with what you was looking for.
Suggest if you think other things need adding.
Reply


Messages In This Thread
Radio Stations v1.1 - With Menus - by Jakwob - 18.04.2015, 18:02
Re: Radio Stations v1.1 - With Menus - by SpikY_ - 18.04.2015, 18:22
Re: Radio Stations v1.1 - With Menus - by LazyB0y - 18.04.2015, 18:36
Re: Radio Stations v1.1 - With Menus - by Victory - 18.04.2015, 18:52
Re: Radio Stations v1.1 - With Menus - by SkyFlare - 18.04.2015, 19:55
Re: Radio Stations v1.1 - With Menus - by Azula - 18.04.2015, 21:33
Re: Radio Stations v1.1 - With Menus - by tantri - 19.04.2015, 01:43
Re: Radio Stations v1.1 - With Menus - by Jakwob - 19.04.2015, 14:20
Re: Radio Stations v1.1 - With Menus - by LeXuZ - 19.04.2015, 14:44
Re : Radio Stations v1.1 - With Menus - by Smocky - 20.04.2015, 17:03
Re: Radio Stations v1.1 - With Menus - by Devon007 - 28.04.2015, 07:25
Re: Radio Stations v1.1 - With Menus - by Jakwob - 26.05.2015, 13:51
Re: Radio Stations v1.1 - With Menus - by FplayerGR - 26.05.2015, 14:05
Re: Radio Stations v1.1 - With Menus - by X337 - 26.05.2015, 15:26
Re: Radio Stations v1.1 - With Menus - by Jakwob - 03.07.2015, 07:45
Re: Radio Stations v1.1 - With Menus - by GodLight - 31.01.2016, 21:33
Re: Radio Stations v1.1 - With Menus - by Jakwob - 10.03.2016, 19:43
Re: Radio Stations v1.1 - With Menus - by UltraScripter - 10.03.2016, 20:18
Re: Radio Stations v1.1 - With Menus - by NaS - 11.03.2016, 11:54
Re: Radio Stations v1.1 - With Menus - by Jakwob - 12.03.2016, 07:01
Re: Radio Stations v1.1 - With Menus - by Jochemd - 12.03.2016, 07:44
Re: Radio Stations v1.1 - With Menus - by markparker12 - 12.03.2016, 17:45
Re: Radio Stations v1.1 - With Menus - by Jakwob - 19.03.2016, 08:01
Re: Radio Stations v1.1 - With Menus - by alexkeward - 21.03.2016, 06:04

Forum Jump:


Users browsing this thread: 1 Guest(s)