🇮🇹
zMenu
Italian
Italian
  • Inizio
  • Plugin Supportati
  • Configurations
    • Informazioni
    • Comandi e Permessi
    • PlaceHolder
    • Come creare un menu passo passo
    • Menu
    • Bottoni/Tasti
      • Requisiti
      • Azioni
    • Oggetti
    • Schemi
    • Comandi
    • Dati dei giocatori
    • Config.json
  • API
    • Informazioni
    • Crea bottone/tasto
    • Crea Loader del Materiale
    • Crea ButtonOption
    • Carica Inventario/Menu
    • Eventi Veloci
  • Lista Files
  • Esempi Menus
Powered by GitBook
On this page
  1. Configurations
  2. Bottoni/Tasti

Azioni

Actions that can be performed after a requirement

With a requirement you can define actions on success or failure. Here are the actions that can be performed.

Example

You will have to put an action list like this:

success_actions:
  - type: player_command
    commands:
      - "firstcommand"
      - "seconds commands %player%"
  - type: console_command
    commands:
      - "firstcommand"
      - "seconds commands %player%"      
  - type: message
    messages:
      - "firstcommand"
      - "seconds commands %player%"   

You can add a delay, in tick, for each item if below. Do like this:

success_actions:
  - type: player_command
    delay: 10 # 10 ticks
    commands:
      - "firstcommand"
      - "seconds commands %player%"
Action
Description

Execute commands as the player. You can send the command in the player tchat.

Execute commands as the console.

Send a message to the player. You can use placeholders and color/format codes here. Mini message format is enable by default if your server support it.

Send a message to the online players. You can use placeholders and color/format codes here. Mini message format is enable by default if your server support it.

Sends messages instead of the player.

Closes the player’s inventory.

Opens an inventory of zMenu.

Allows sending the player to another server, only works with BungeeCord and Velocity.

Refresh current button. Work only in click requirement

Return to previous inventory.

Open a book

PreviousRequisitiNextOggetti

Last updated 1 year ago

Send a sound to a player, you must use for sound.

Send a sound to the online players, you must use for sound.

Update .

Open a trading inventory

- type: player_command
  commands:
    - "firstcommand"
    - "seconds commands %player%"
  commandInChat: false # false by default
- type: console_command
  commands:
    - "firstcommand"
    - "seconds commands %player%"
- type: message
  messages:
    - "my message"
    - "my second messages"
  minimessage: true # true by default
- type: broadcast
  messages:
    - "my message"
    - "my second message to %player%"
  minimessage: true # true by default
- type: chat
  messages:
    - "my message"
- type: close
- type: inventory
  inventory: <inventory name>
  plugin: <plugin name>
  page: <page>
  arguments: <argument list>
- type: connect
  server: <server name>
- type: sound
  sound: <xsound>
  pitch: <sound pitch> # 1.0f by default
  volume: <sound volume> # 1.0f by default
- type: broadcast_sound
  sound: <xsound>
  pitch: <sound pitch> # 1.0f by default
  volume: <sound volume> # 1.0f by default
- type: data
  action: <SET/REMOVE/ADD/SUBTRACT>
  key: <data key>
  value: <data value>
  seconds: <expire seconds> # 0 by default
- type: refresh  
- type: back
- type: shopkeeper
  name: <shopkeeper name>
- type: book
  author: "Maxlego08" # Book author
  title: "&cTest" # Book title
  lines: # Book pages
    1: # First page
      - '     #34ebe8zMenu'
      - ''
      - ''
      - '<hover:show_text:"#34eba8Open an url !"><click:open_url:"https://minecraft-inventory-builder.com/">#f0af24Open URL<reset>'
XSound
XSound
player data
Shopkeeper