Forum

> > CS2D > Scripts > Close menu
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch Close menu

3 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Close menu

JonyFrosta
User Off Offline

Zitieren
How to close menu opened with Lua function menu(id, str)?

alt Re: Close menu

Mami Tomoe
User Off Offline

Zitieren
You can't close it.

Possible workarounds:
• You can show an invisible menu using the @i suffix, good in theory, bad in practice, nobody knows this feature exists and it doesn't actually close the menu, just replaces it with an empty invisible menu.
• Create an empty menu to replace the old menu, doesn't close it, only prevents seeing the old content.
• Create your own GUI for menus where you can show your own menu (cs2d lua cmd image) and then free the image (cs2d lua cmd freeimage) when you want to close the menu.

There could be other approaches you can take, but realistically it is not currently possible to close the menu, you can only hide it in various ways (whilst retaining a menu open) or create your own menu system.

alt Re: Close menu

JonyFrosta
User Off Offline

Zitieren
I need to close the menu, not hide, not create a custom.
I use the @i menu to hide the interface of items (at the top of the screen) when scrolling the mouse wheel. And in order to restore the normal process, I need to close the menu with the @i parameter.

alt Re: Close menu

Mami Tomoe
User Off Offline

Zitieren
As I said, CS2D does not have a function permitting closing a menu as a server to the client.
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht