Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //////////////////////
- ////New Menu Styles///
- //////Created by://///
- //////°Fallout°///////
- //////////////////////
- #include <a_samp>
- #include <F_Menu>
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- new Example1;
- new Example2;
- new Example3;
- new Example4;
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- public OnFilterScriptInit()
- {
- Example1 = F_CreateMenu("Example1", 20.0, 120.0, 200.0);
- F_AddMenuItem(Example1, "Item1");
- F_AddMenuItem(Example1, "Item2");
- F_AddMenuItem(Example1, "Item3");
- Example2 = F_CreateMenu("Example2", 20.0, 120.0, 200.0);
- F_AddMenuItem(Example2, "Item1");
- F_AddMenuItem(Example2, "Item2");
- F_AddMenuItem(Example2, "Item3");
- F_AddMenuItem(Example2, "Item4");
- F_SetMenuTitleBoxColor(Example2, 0xCC000099);
- F_SetMenuSelectedItemBoxColor(Example2, 0xFF000099);
- Example3 = F_CreateMenu("Example3", 100.0, 130.0, 400.0);
- F_AddMenuItem(Example3, "Item1");
- F_AddMenuItem(Example3, "Item2");
- F_AddMenuItem(Example3, "Item3");
- F_AddMenuItem(Example3, "Item4");
- F_AddMenuItem(Example3, "Item5");
- F_SetMenuTitleBgColor(Example3, 0x33FF0099);
- F_SetMenuSelectedItemBgColor(Example3, 0x00CC0099);
- Example4 = F_CreateMenu("Example4", 50.0, 120.0, 300.0);
- F_AddMenuItem(Example4, "Item1");
- F_AddMenuItem(Example4, "Item2");
- F_AddMenuItem(Example4, "Item3");
- F_AddMenuItem(Example4, "Item4");
- F_AddMenuItem(Example4, "Item5");
- F_AddMenuItem(Example4, "Item6");
- F_SetMenuTitleBoxColor(Example4, 0x00009999);
- F_SetMenuItemBoxColor(Example4, 0x0000CC99);
- F_SetMenuSelectedItemBoxColor(Example4, 0x0000FF99);
- F_SetMenuTitleBgColor(Example4, 0xFFFFFF99);
- F_SetMenuItemBgColor(Example4, 0xFFFFFF99);
- F_SetMenuSelectedItemBgColor(Example4, 0xFFFFFF99);
- F_SetMenuTitleTextColor(Example4, 0x00000099);
- F_SetMenuItemTextColor(Example4, 0x00000099);
- F_SetMenuSelectedItemTextColor(Example4, 0x00000099);
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- public F_OnPlayerSelectedMenuRow(playerid, menuid, row)
- {
- if(menuid == Example1)
- {
- switch(row)
- {
- case 0:
- {
- F_ShowMenuForPlayer(Example2, playerid);
- TogglePlayerControllable(playerid, true);
- }
- case 1:
- {
- F_ShowMenuForPlayer(Example3, playerid);
- TogglePlayerControllable(playerid, true);
- }
- case 2:
- {
- F_ShowMenuForPlayer(Example4, playerid);
- TogglePlayerControllable(playerid, true);
- }
- }
- }
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
- {
- F_OnPlayerKeyStateChange(playerid, newkeys);
- return 1;
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- public F_OnPlayerExitedMenu(playerid, menuid)
- {
- TogglePlayerControllable(playerid, true);
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- if(!strcmp(cmdtext,"/Example1", true))
- {
- F_ShowMenuForPlayer(Example1, playerid);
- TogglePlayerControllable(playerid, false);
- return 1;
- }
- if(!strcmp(cmdtext,"/Example2", true))
- {
- F_ShowMenuForPlayer(Example2, playerid);
- TogglePlayerControllable(playerid, false);
- return 1;
- }
- if(!strcmp(cmdtext,"/Example3", true))
- {
- F_ShowMenuForPlayer(Example3, playerid);
- TogglePlayerControllable(playerid, false);
- return 1;
- }
- if(!strcmp(cmdtext,"/Example4", true))
- {
- F_ShowMenuForPlayer(Example4, playerid);
- TogglePlayerControllable(playerid, false);
- return 1;
- }
- return 0;
- }
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement