Перейти к содержимому
View in the app

A better way to browse. Learn more.

Zloplay community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Опубликовано:

Hi guys!

 

I'm trying to write a script, that shows some text when the player opens the menu, and hides it when it's closed.

 

PlayerConnected += new Action((player) =>
{
player.Call("notifyOnPlayerCommand", "test", "togglemenu");
player.OnNotify("test", (entity) => {
	Call("clientprint", entity, "test");
});
});

 

This is the code i tried, because i found this in the key bindings:

"bind ESCAPE togglemenu"

 

The same method worked for the voting keys by using "vote yes" and "vote no" instead of togglemenu.

 

Is it possible to do what i want?

Hiding the text is not a problem, i already have the code that hides it when the player closes the menu, i got that by onnotify menuresponse, but there's no menuresponse when the menu is opened.

Featured Replies

Опубликовано:

That's what i thought for the first time too, but apparently it didn't work. I don't even know why isn't it working, that's why i'm asking for help.

If you know anything other than "menuresponse" and "togglemenu" that could be somehow related to opening the menu, i'd be happy to hear about it.

Опубликовано:

try OnClientCommand("togglemenu")

Опубликовано:

Sorry for the late response, i just tried that, but it's not working.

Any other ideas?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Гость
Ответить в тему...

Сейчас на странице 0

  • Нет пользователей, просматривающих эту страницу

Важная информация

Используя этот сайт, вы соглашаетесь Условия использования.

Account

Navigation

Поиск

Поиск

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.