> For the complete documentation index, see [llms.txt](https://tooltips.gitbook.io/tooltips/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tooltips.gitbook.io/tooltips/configuration/preset/condition-list.md).

# Condition list

## Contents

Currently, the plugin natively supports the following conditions:

* [compare](#compare) \[ Compare two values ]
* [permission](#permission) \[ Whether a player has specified permissions ]
* [op](#op) \[ Whether a player is opped ]
* [gamemode](#gamemode) \[ Whether the players gamemode is among specified ones ]
* [location](#location) \[ Whether the players location matches the given location ]
* [incuboid](#incuboid) \[ Whether a player is in a cuboid ]
* [standingon](#standingon) \[ Which type of block the player is standing on ]
* [sneaking](#sneaking) \[ Whether the player is sneaking ]
* [world](#world) \[ Which world the player is in ]
* [day](#day) \[ Whether its day in the players world ]
* [night](#night) \[ Whether its night in the players world ]
* [time](#time) \[ What time is it in the players world ]
* [lookingatblock](#lookingatblock) \[ What type of block the player is looking at ]
* [lookingatfurniture](#lookingatfurniture) \[ If player is looking at plugin furniture ] <mark style="color:red;">**\*1**</mark>
* [lookingatentity](#lookingatentity) \[ If player is looking at an entity ]
* [entitynbtequals](#entitynbtequals) \[ Check nbt values of the entity that is being looked at ] <mark style="color:red;">**\*2**</mark>
* [tileentitynbtequals](#tileentitynbtequals) \[ Check nbt values of the tile entity that is being looked at ] <mark style="color:red;">**\*2**</mark>
* [blocknbtequals](#blocknbtequals) \[ Check nbt values of the block that is being looked at ] <mark style="color:red;">**\*2**</mark>
* [blockstateequals](#blockstateequals) \[ Check blockstate values of the block that is being looked at ]
* [lookingatcitizen](#lookingatcitizen) \[ Whether player is looking at a Citizens NPC ] <mark style="color:red;">**\*4**</mark>
* [lookingatmythicmob](#lookingatmythicmob) \[Whether player is looking at a MythicMob mob] <mark style="color:red;">**\*5**</mark>
* [equipped](#equipped) \[ If a player has the item equipped in hands or on body ]
* [itemnbtequals](#itemnbtequals) \[ If players equipped item has given nbt data ] <mark style="color:red;">**\*2**</mark>
* [region](#region) \[ If players region is among specified ones ] <mark style="color:red;">**\*3**</mark>

**Notes**:

1. Requires a supported [furniture plugin](/tooltips/extra/integrations.md#supported-furniture-plugins)
2. Requires [NBT API](https://www.spigotmc.org/resources/7939) plugin
3. Requires a [region plugin](/tooltips/extra/integrations.md#supported-region-plugins)
4. Requires [Citizens](https://www.spigotmc.org/resources/13811)
5. Requires [MythicMobs](https://mythiccraft.io/index.php?resources/mythicmobs.1/)

## Conditions

### compare

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>1, first</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> (supports placeholders)</td><td>%player_name%</td></tr><tr><td>2, second</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> (supports placeholders)</td><td>%player_health%</td></tr><tr><td>o, oper, operation <code>(optional)</code></td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Operation</a></td><td></td></tr></tbody></table>

| Context        | Description                           |
| -------------- | ------------------------------------- |
| compare.first  | Parsed value of the "first" argument  |
| compare.second | Parsed value of the "second" argument |

#### Description

> If only first is set and it's a boolean, will check if it's true
>
> If both first and second are set and they are strings, they will be compared if they are equal. If they are booleans (true / false) they will be also compared if they are equal.
>
> If operation is set and both first & second arguments are numbers, will use the operation to compare the variables.&#x20;

**Examples**

```yaml
conditions:
# Check if players health is more than or equal to 20.0
- compare { first = %player_health%; operation = >=; second= 20.0 }
# Check if both are equal (they aren't)
- compare { 1=true; 2=false }
# Check if players name is Septicuss
- compare { 1=%player_name%; 2=Septicuss }
```

### permission

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>p, perm, permission</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> array</td><td>tooltips.command.reload</td></tr></tbody></table>

#### Description

> Checks if player has any of the permissions in the string array

**Examples**

```yaml
conditions:
# Check if player has the permission to a command
- permission { p = tooltips.command.reload }
# Check if player has either of the two permissions
- permission { perm = first, second }
```

### op

#### Description

> Checks if player is opped

**Examples**

```yaml
conditions:
- op
```

### gamemode

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>gamemode, gm</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Type</a> of <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/GameMode.html">gamemode</a> array</td><td>creative, survival</td></tr></tbody></table>

#### Description

> Checks if player has any of the given gamemodes

**Examples**

```yaml
conditions:
# Check if players game mode is adventure
- gamemode { gm = adventure }
# Check if players game mode is either creative or survival
- gamemode { gamemode = creative, survival }
```

### location

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>location, loc, l</td><td>Array of <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Location</a></td><td>[ 22, 602, -234]<br>or<br>[22, 602, -234], [22, 603, -233]</td></tr></tbody></table>

#### Description

> Checks if player is at the given coordinates in their current world

**Examples**

```yaml
conditions:
# Check if the current location is x,y,z = 22, 602, -234
- location { l = [ 22, 602, -234 ]
# Check if the current location is either 22 602 -234 or 22 603 -233
- location { l = [ 22, 602, -234], [ 22, 603, -233] }
```

### incuboid

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>first, 1, firstpoint</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Location</a></td><td>[ 22, 602, -234]</td></tr><tr><td>second, 2, secondpoint</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Location</a></td><td>[49, 620, -251]</td></tr></tbody></table>

#### Description

> **This check is more resource-intensive than the "region" condition, due to being unable to cache which cuboid the player is currently in.**
>
> \
> Checks if player is within the two given locations.&#x20;

**Examples**

```yaml
conditions:
# Check if player is within location at 22, 602, -234 and 49, 620, -251
- incuboid { first = [ 22, 602, -234 ]; second = [49, 620, -251] }
```

### standingon

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>type, m, mat, material</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Type </a>of <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html">material</a> array</td><td>grass_block, obsidian</td></tr></tbody></table>

#### Description

> Checks if player is currently standing on any of the given materials. Can also be air to check if the block under the player is air.

**Examples**

```yaml
conditions:
# Check if player is standing on grass or dirt blocks
- standingon { type = grass_block, dirt }
# Check if player is standing on a block of obsidian
- standingon { m = obsidian }
```

### sneaking

#### Description

> Checks if player is currently sneaking

**Examples**

```yaml
conditions:
# Check if player is sneaking
- sneaking
```

### world

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>name</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> array</td><td>world, resource_world</td></tr></tbody></table>

| Context | Description            |
| ------- | ---------------------- |
| world   | Returns the world name |

#### Description

> Checks if players world is any of the ones defined in the name string array.

**Examples**

```yaml
conditions:
# Check if player is in the world called "world"
- world { name = world }
# Check if player is either in the nether or the end worlds
- world { name = world_nether, world_the_end }
```

### day

#### Description

> Checks if its day (time between 0 and 13000) in the players current world.

**Examples**

```yaml
conditions:
# Check if its day in the players current world
- day
```

### night

#### Description

> Checks if its night (time between 13000 and 24000) in the players current world.

**Examples**

```yaml
conditions:
# Check if its night in the players current world
- night
```

### time

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>time, t</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>1000, 13000</td></tr><tr><td>o, oper, operation (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Operation</a></td><td>>=</td></tr></tbody></table>

#### Description

> Checks if the current [time](https://minecraft.fandom.com/wiki/Daylight_cycle) in the players world is equal to the given time argument.&#x20;
>
> If operation is included, a comparison operation is conducted, with given time argument being the first comparable.

**Examples**

```yaml
conditions:
# Checks if the time in the players current world is greater than or equal to 1000
- time { time = 1000; oper = >= }
# Checks if the time in the players current world is between 0 and 5000 inclusive
- time {t=0; oper=>=} AND time {t=5000; oper=<=}
```

### lookingatblock

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>type, m, mat, material (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Type</a> of <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html">material</a> array</td><td>bedrock, grass_block</td></tr><tr><td>location, loc, l (optional)</td><td>Array of <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Location</a></td><td>[0, 64, 50]</td></tr><tr><td>distance, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> If no type or location is given, will return true if any type of block is being looked at.
>
> If type is defined, will check if the block that is being looked at is of specific material
>
> If location is defined, will check if the block that is being looked at is at specific coordinates in the players current world
>
> If distance is defined (3 by default), will increase or decrease the distance at which the block that is being looked at is detected

**Examples**

```yaml
conditions:
# Check if player is looking at bedrock
- lookingatblock{type=bedrock}
# Check if player is looking at an acacia sign at given coordinates
- lookingatblock{l=[440,65,803]; m=acacia_sign}
# Check if player is looking at blocks in given three coordinates
- lookingatblock{l=[440,65,803],[441,65,808],[442,65,803]}
# Check if player is looking at an acacia sign at given coordinates with increased distance
- lookingatblock{l=[440,65,803]; m=acacia_sign; d=6}
```

### lookingatfurniture

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>id (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> array</td><td>couch, chair</td></tr><tr><td>distance, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

| Context          | Description                                                  |
| ---------------- | ------------------------------------------------------------ |
| furniture.id     | ID of target furniture                                       |
| furniture.name   | Name of the furniture as defined in the config of the plugin |
| furniture.plugin | The plugin where this furniture came from                    |

#### Description

> <mark style="color:red;">Requires any supported furniture plugin to work.</mark>
>
> If no ids are given, checks if player is looking at any furniture within the distance (3 by default).
>
> If ids are given, checks if the furniture the player is looking at has any of the ids.
>
> Distance argument increases the distance at which furniture is checked.

**Examples**

```yaml
conditions:
# Checks if player is looking at any type of furniture
- lookingatfurniture
# Checks if player is looking at a furniture with id of couch or chair
- lookingatfurniture {id=couch, chair}
# Previous but with a distance of 6
- lookingatfurniture {id=lamp; distance=6}
```

### lookingatentity

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>entity, type, t (optional)</td><td>Type of <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/entity/EntityType.html">entity type</a> array</td><td>villager, sheep</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> If no types are given, checks if player is looking at any type of entity (armor stands etc. too)
>
> If types are given, checks if player is looking at any of the given entity types
>
> If distance is given, will increase the distance that entities are checked at (3 by default)

**Examples**

```yaml
conditions:
# Player is looking at a villager
- lookingatentity {t=villager}
# Player is looking at a cow or a pig
- lookingatentity {entity=cow,pig}
```

### entitynbtequals

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>key, k</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a></td><td>mynbtkey</td></tr><tr><td>nbtvalue, nbtval, value, val, v</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a>, <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> or <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Boolean</a></td><td>weird, 10, false</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires NBT API plugin to work.</mark>
>
> Checks if the targeted entity within distance (3 by default) has a key with given value
>
> Supports basic NBT paths as key. Example: `Item.tag.CustomModelData`

**Examples**

```yaml
conditions:
# Checks if integer at "mynbtkey" equals 10
- entitynbtequals {key=mynbtkey; value=10}
# Checks if boolean at "mynbtkey" equals false
- entitynbtequals {key=mynbtkey; value=false}
# .. same for string as the value
```

### tileentitynbtequals

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>key, k</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a></td><td>mynbtkey</td></tr><tr><td>nbtvalue, nbtval, value, val, v</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a>, <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> or <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Boolean</a></td><td>weird, 10, false</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires NBT API plugin to work.</mark>
>
> Checks if the targeted tile entity within distance (3 by default) has a key with given value
>
> Supports basic NBT paths as key. Example: `Item.tag.CustomModelData`

**Examples**

```yaml
conditions:
# Checks if a (block) player skull owner is Septicuss
- lookingatblock{type=player_head}
- tileentitynbtequals{key=SkullOwner.Name; value=Septicuss}
```

### blocknbtequals

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>key, k</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a></td><td>mynbtkey</td></tr><tr><td>nbtvalue, nbtval, value, val, v</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a>, <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> or <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Boolean</a></td><td>weird, 10, false</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires NBT API plugin to work.</mark>
>
> Checks if the targeted block within distance (3 by default) has a key with given value
>
> Supports basic NBT paths as key. Example: `Item.tag.CustomModelData`

**Examples**

```yaml
conditions:
# Checks if the target block has a key 'hello' with value true
- blocknbtequals{key=hello; value=true}
```

### blockstateequals

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>key, k, id</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a></td><td>note, powered</td></tr><tr><td>value, val, v</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a>, <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> or <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Boolean</a></td><td>weird, 10, false</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> Checks if the targeted blocks [block state](https://minecraft.fandom.com/wiki/Block_states) within distance (3 by default) has a key with given value

**Examples**

```yaml
conditions:
- lookingatblock{type=note_block} # Optional
# Check if the note blocks "powered" state is equal to "false"
- blockstateequals{key=powered; val=false}
# Check if the note blocks "note" is equal to 15
- blockstateequals{key=note; value=15}

```

### lookingatcitizen

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>id, name (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> array</td><td>0, 1, 5, 23</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires Citizens plugin to work.</mark>
>
> Checks if the targeted entity within distance (3 by default) is a Citizens NPC.
>
> If ids are present, checks if the targeted NPC has any of the given ids.<br>
>
> Citizen ids can be seen by first selecting an NPC using commands and typing /npc:![](/files/2kkI7kgnllfcNT9D6iyM)

**Examples**

```yaml
conditions:
# If player is looking at a Citizen with the id 0
- lookingatcitizen{id=0}
# If player is looking at a Citizen with either id 2 or 23
- lookingatcitizen{id=2,23}
# IF player is looking at a Citizen from 10 blocks away
- lookingatcitizen{dist=10}
```

### lookingatmythicmob

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>id, ids (optional)</td><td>String array</td><td>john, spider</td></tr><tr><td>distance, dist, d (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a></td><td>3, 5</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires MythicMobs plugin to work.</mark>
>
> Checks if the targeted entity within distance (3 by default) is a MythicMobs mob
>
> If ids are present, checks if the targeted mythic mob has any of the given ids.

**Examples**

```yaml
conditions:
# If player is looking at a MythicMob with the id 'my-boss'
- lookingatmythicmob{id=my-boss}
# If player is looking at a MythicMob with either id 'my-boss' or 'john'
- lookingatmythicmob{id=my-boss,john}
# If player is looking at any MythicMob from 10 blocks away
- lookingatmythicmob{dist=10}
```

### equipped

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>type, m, mat, material</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Type</a> of <a href="https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html">material</a> array</td><td>stone_axe, flint_and_steel</td></tr><tr><td>slot, s (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Slot</a></td><td>hand, helmet</td></tr></tbody></table>

#### Description

> Checks if item at the given slot (main hand by default) has the given type

**Examples**

```yaml
conditions:
# If player has a diamond sword in their main hand
- equipped { type=diamond_sword }
# If player has a compass in their off hand
- equipped { s = off_hand; type = compass }
# If player has a diamond or gold helmet equipped
- equipped {slot=helmet; type=diamond_helmet,gold_helmet}
```

### itemnbtequals

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>key, k</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a></td><td>mynbtkey</td></tr><tr><td>nbtvalue, nbtval, value, val, v</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a>, <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Integer</a> or <a href="/pages/uTa7COjjZMcu4ZGQsiY8">Boolean</a></td><td>weird, 10, false</td></tr><tr><td>slot, s (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">Slot</a></td><td>off_hand, legs</td></tr></tbody></table>

#### Description

> <mark style="color:red;">Requires NBT API plugin to work.</mark>
>
> Checks if item at the given slot (main hand by default) has an item with the given nbt key with given nbt value in it.\
> Supports basic NBT paths as keys. Example: `Item.tag.CustomModelData`

**Examples**

```yaml
conditions:
# Checks if the custom model data nbt tag of the held item is equal to 1
- itemnbtequals { key = CustomModelData; value=1}
```

### region

<table><thead><tr><th width="202.33333333333331">Argument</th><th width="265">Type</th><th>Example</th></tr></thead><tbody><tr><td>r, reg, region, name, id (optional)</td><td><a href="/pages/uTa7COjjZMcu4ZGQsiY8">String</a> array</td><td>shop, spawn</td></tr></tbody></table>

| Context | Description       |
| ------- | ----------------- |
| region  | Current region ID |

#### Description

> <mark style="color:red;">Requires any</mark> [<mark style="color:red;">region</mark>](/tooltips/extra/integrations.md#supported-region-plugins) <mark style="color:red;">plugin to work.</mark>
>
> Checks if player is in any of the given region ids
>
> If no regions are provided, returns true if player is inside of any region

**Examples**

```yaml
conditions:
# Check if player is in the shop region
- region { r = shop }
# Check if player is either inside the spawn region or the crates region
- region { r = spawn, crates }
```
