AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   player menu (https://forums.alliedmods.net/showthread.php?t=152833)

Tonda 03-14-2011 17:18

player menu
 
hi all i have menu with players ..

Code:

public player_menu(id)
{
        if((is_user_alive(id) && cs_get_user_team(id) == CS_TEAM_CT))
                menu_players(id, CS_TEAM_CT, 0, 1, "select1", "%L", LANG_SERVER, "SELECT_PLAYERS")

        return PLUGIN_CONTINUE
}

and

Code:

public selectl(id, menu, item)
{
        if(item == MENU_EXIT)
        {
                menu_destroy(menu)
                return PLUGIN_HANDLED
        }
       
        static dst[32], data[5], player, access, callback

        menu_item_getinfo(menu, item, access, data, charsmax(data), dst, charsmax(dst), callback)
        player = str_to_num(data)
        go_to_do(id, player)
        return PLUGIN_HANDLED
}

So, all works perfectly, i have menu with players. But this menu have some keys with player nickname and last key is 0 - Exit ... I realy need one custom key with Back. So, 1,2,3,4,5,6 keys with players, 7 key with Back button and 0 key Exit.

How can i do this please?

fysiks 03-14-2011 18:20

Re: player menu
 
It is all done automatically by the menu system.

Tonda 03-14-2011 19:40

Re: player menu
 
Quote:

Originally Posted by fysiks (Post 1433346)
It is all done automatically by the menu system.

No, you dont understand :) i need back in first page with players. And if you are push back, will be open new custom menu

fysiks 03-14-2011 20:08

Re: player menu
 
Quote:

Originally Posted by Tonda (Post 1433382)
No, you dont understand :) i need back in first page with players. And if you are push back, will be open new custom menu

If you want that then you will need to make your own menu system using the original menu method (like in the menus used in AMX Mod X).

Tonda 03-14-2011 20:21

Re: player menu
 
Quote:

Originally Posted by fysiks (Post 1433388)
If you want that then you will need to make your own menu system using the original menu method (like in the menus used in AMX Mod X).

i have another custom menu ... but how can add key 7 (back) for first page with players menu?

fysiks 03-14-2011 20:26

Re: player menu
 
Quote:

Originally Posted by Tonda (Post 1433391)
i have another custom menu ... but how can add key 7 (back) for first page with players menu?

What I'm saying is that you cannot use the "New Menu System."


All times are GMT -4. The time now is 14:35.

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