>.> srry i was in a rush.
pawn Код:
#define FILTERSCRIPT
#include <a_samp>
new Menu:radiomenu;
new Menu:HMmenu;
new Menu:ARmenu;
new Menu:Cmenu;
new Menu:Pmenu;
new Menu:RBmenu;
new Menu:DMmenu;
new Menu:CLmenu;
new Menu:Jmenu;
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
radiomenu = CreateMenu("Select A Genre", 2, 200.0, 100.0, 150.0, 150.0);
HMmenu = CreateMenu("Heavy Metal", 2, 200.0, 100.0, 150.0, 150.0);
ARmenu = CreateMenu("Alternative Rock", 2, 200.0, 100.0, 150.0, 150.0);
Cmenu = CreateMenu("Country", 2, 200.0, 100.0, 150.0, 150.0);
Pmenu = CreateMenu("Pop", 2, 200.0, 100.0, 150.0, 150.0);
RBmenu = CreateMenu("R&B", 2, 200.0, 100.0, 150.0, 150.0);
DMmenu = CreateMenu("Death Metal", 2, 200.0, 100.0, 150.0, 150.0);
CLmenu = CreateMenu("Classic", 2, 200.0, 100.0, 150.0, 150.0);
Jmenu = CreateMenu("Jazz", 2, 200.0, 100.0, 150.0, 150.0);
AddMenuItem(radiomenu, 0, "Heavy Metal");
AddMenuItem(radiomenu, 0, "Alternative Rock");
AddMenuItem(radiomenu, 0, "Country");
AddMenuItem(radiomenu, 0, "Pop");
AddMenuItem(radiomenu, 0, "R&B");
AddMenuItem(radiomenu, 0, "Death Metal");
AddMenuItem(radiomenu, 0, "Classical");
AddMenuItem(radiomenu, 0, "Jazz");
AddMenuItem(HMmenu, 0, "Mr. Crowley");
AddMenuItem(HMmenu, 1, "Ozzy Osbourne");
AddMenuItem(ARmenu, 0, "Viva La Gloria");
AddMenuItem(ARmenu, 1, "Green Day");
print("\n--------------------------------------");
print(" Radio Menu Filterscript by [DH]StarFox Loaded like a baws!");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
#endif
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmdtext, "/radio", true) == 0)
{
ShowMenuForPlayer(radiomenu,playerid);
return 1;
}
return 0;
}
public OnPlayerSelectedMenuRow(playerid, row)
{
new Menu:CurrentMenu = GetPlayerMenu(playerid);
if (CurrentMenu == radiomenu)
{
switch(row)
{
case 0: //Heavy Metal
{
ShowMenuForPlayer(HMmenu,playerid);
}
case 1: //Alternative Rock
{
ShowMenuForPlayer(ARmenu,playerid);
}
case 2: //Country
{
ShowMenuForPlayer(Cmenu,playerid);
}
case 3: //Pop
{
ShowMenuForPlayer(Pmenu,playerid);
}
case 4: //R&B
{
ShowMenuForPlayer(RBmenu,playerid);
}
case 5: //Death Metal
{
ShowMenuForPlayer(DMmenu,playerid);
}
case 6: //Classical
{
ShowMenuForPlayer(CLmenu,playerid);
}
case 7: //Jazz
{
ShowMenuForPlayer(Jmenu,playerid);
}
}
if (CurrentMenu == HMmenu)
{
switch(row)
{
case 0: //Ozzy Osbourne - Mr. Crowley
{
PlayAudioStreamForPlayer(playerid, "http://www.palaceofwisdom.net/MUSIC/Ozzy%20Osbourne%20-%20Mr.%20Crowley.mp3");
}
}
if (CurrentMenu == ARmenu)
{
switch(row)
{
case 0: //Green Day - Viva La Gloria
{
PlayAudioStreamForPlayer(playerid, "http://foldedspace.org/files/Greenday%20-%20When%20I%20Come%20Around.mp3");
}
}
}
} }
return 1;
}