AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Blank line in menu. (https://forums.alliedmods.net/showthread.php?t=25125)

Obbin 03-08-2006 09:48

Blank line in menu.
 
How to make a blank line in a menu (new style)?

thx

SSJ2GOKU 03-08-2006 09:54

i would say, add a new item with nothing as name

with nothing i mean this "" or " " (a space)

wouter 03-08-2006 09:56

i thought it was with the"^n" then it has no number or any posible action.

Obbin 03-08-2006 09:57

Oh thnks!
Is there any way of getting color in this menus as well?
Im pretty new to menus:P

wouter 03-08-2006 10:00

think it was somethink like this: "\w" for white text; "\r" for red text; "\y" for yellow text.
but in amxx studio you have a tab "genatartors" there it is just to easy to be true

SSJ2GOKU 03-08-2006 10:02

it aint so easy yet wouter, i hoped it would be more easy then now

wouter 03-08-2006 10:05

oh yea your right it is the old style wish is to easy :) sry bout that :P

Obbin 03-08-2006 10:20

Okay i just realized that i don't know how to show the menu to a player!


I want to show this menu:
Code:
#include <amxmodx> #include <amxmisc> #define PLUGIN "New Plugin" #define VERSION "1.0" #define AUTHOR "Author" new mBuyMenu // Menu new mcbBuyMenu // Menu Callback public plugin_init() {         mBuyMenu = menu_create("New style menu", "mh_BuyMenu")     mcbBuyMenu = menu_makecallback("mcb_BuyMenu")     menu_additem(mBuyMenu, "1. option 1", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "2. option 2", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "3. option 3", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "4. option 4", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "5. option 5", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "6. option 6", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "7. option 7", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "8. option 8", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "9. option 9", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     menu_additem(mBuyMenu, "0. exit", "ma_BuyMenu", ADMIN_USER, mcbBuyMenu)     register_plugin(PLUGIN, VERSION, AUTHOR) } public mh_BuyMenu(id, menu, item) {     switch(item)     {         case 1:         {             lol(id)         }             case 2:         {             lol(id)         }             case 3:         {             lol(id)         }             case 4:         {             lol(id)         }             case 5:         {             lol(id)         }             case 6:         {             lol(id)         }             case 7:         {             lol(id)         }             case 8:         {             lol(id)         }             case 9:         {             lol(id)         }             case 10:         {             lol(id)         }         }         return 0; } public lol(id) {     client_print(id, print_chat, "WORKS!") } public ma_BuyMenu(id) {     /* This event is called when an item was selected */ } public mcb_BuyMenu(id, menu, item) {     return ITEM_ENABLED }

wouter 03-08-2006 10:28

you must put in plugin_init
Code:
register_menucmd(register_menuid("Which Action?"), keys, "mh_BuyMenu")
or something

[ --<-@ ] Black Rose 03-08-2006 11:25

I think the old style menu is much easier to use...


All times are GMT -4. The time now is 20:26.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.