# Staff Mode

Staff mode is one of the biggest features in Staff+ & Staff++. It allows a staff member to enter a mode in which he gets extra privileges so that he/she can go patrolling around.

### Configuration

Staff mode has it's own configuration section in the `config.yml` file.&#x20;

#### Basic configuration

The part below contains the basic settings for the staff mode. These properties determine what staff can and cannot do in staff mode.

```yaml
staff-mode:
  # Whether or not a player is allowed to break/place blocks while in staff mode.
  block-manipulation: false

  # Whether or not a player is allowed to interact with their inventory while in staff mode.
  inventory-interaction: true

  # Whether or not a player is allowed to interact with chest/hoppers/dispensers,... while in staff mode.
  silent-chest-interaction: false

  # Whether or not a player is allowed to pickup items while in staff mode.
  item-pickup: false

  # Whether or not a player is allowed to drop items while in staff mode.
  item-drop: false
  
  # The type of vanish that will be applied when a player goes into staff mode.
  # Valid vanish types are: TOTAL, LIST, and NONE.
  vanish-type: TOTAL

  # Whether or not a player will be invincible while in staff mode.
  invincible: true

  # Whether or not a player in staff mode can attack other players.
  damage: false

  # Whether or not a player will lose hunger while in staff mode.
  hunger-loss: false

  # Whether or not a player can fly while in staff mode.
  flight: true

  # Whether or not a player will be put into creative while in staff mode.
  creative: false

  # Whether or not to a player to the location they were in before they toggled staff mode.
  original-location: false

  # Whether or not staff mode will be enabled for staff when they login.
  enable-on-login: false

  # Commands to execute when staff mode is enabled. Leave [] to disable.
  # Each command is separated with a comma.
  enable-commands:
    - command: op %player%
      filters: "permission=rank.admin"
    - command: example2 %player%
  # Commands to execute when staff mode is disable. Leave [] to disable.
  disable-commands: 
    - command: deop %player%
      filters: "permission=rank.admin"
    - command: example2 %player%

  # Should Staff mode disable on world change
  disable-on-world-change: false

  # Should other staff be able to see staff that are in mode while they are not in mode.
  staff-see-staff-in-mode: false
```

### Enable/Disable commands

You can specify commands to run whenever a staff member enters/exits staff mode.

```yaml
staff-mode:  
  # Commands to execute when staff mode is enabled. Leave [] to disable.
  # Each command is separated with a comma.
  enable-commands:
    - command: op %player%
      filters: "permission=rank.admin"
    - command: example2 %player%
  # Commands to execute when staff mode is disable. Leave [] to disable.
  disable-commands: 
    - command: deop %player%
      filters: "permission=rank.admin"
    - command: example2 %player%
```

* **command**: specifies the command string to run, use %player% as placeholder for the player name.
* **filters:** Optionally define a permission filter, the command will only run if the player has that permission.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://wiki.staffplusplus.org/master/features/staff-mode.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
