> For the complete documentation index, see [llms.txt](https://realisticnode.gitbook.io/rnsetups/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://realisticnode.gitbook.io/rnsetups/rnkoth/guides/rules.md).

# Rules inside the area

Who counts inside the area, and the rules for flight, elytra, ender pearls, commands and blocks.

The rules of a KOTH only apply **while it runs**, and only in the area where it is now. They are in the `rules:` section of the KOTH file and in `/koth editor <name>` → **Rules**.

```yaml
rules:
  deny-flight: true
  deny-elytra: true
  deny-ender-pearls: false
  invisible-players-count: false
  afk-seconds: 60
  counted-gamemodes: [SURVIVAL, ADVENTURE]
  blocked-commands: []
  protect-blocks: false
```

## Who counts

A player standing in the area only helps their side when they **count**. When they do not, their action bar says why:

| Reason    | Action bar                                   | How to change it                                                                                                                  |
| --------- | -------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| AFK       | `You are not counting: move to count (AFK)`  | `afk-seconds`: seconds without moving or turning the head before a player stops counting (default `60`, `0` = off).               |
| Game mode | `You are not counting in this game mode`     | `counted-gamemodes`: the game modes that count (default `SURVIVAL` and `ADVENTURE`). Add `CREATIVE` or `SPECTATOR` to count them. |
| Vanished  | `You are not counting in this game mode`     | Players hidden by a vanish plugin never count.                                                                                    |
| Invisible | `Invisible players don't count here`         | `invisible-players-count: true` lets players with the invisibility effect count.                                                  |
| Just died | `You just died: you count again in a moment` | `events.death-cooldown` in `config.yml`: seconds a player who died inside must wait (default `5`, `0` = off).                     |

Dead players never count. Players who do not count are not on any side: they do not contest the KOTH and do not gain.

<figure><img src="https://348500357-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSlVHklG0EMAOmvfqcizu%2Fuploads%2FQa61EVqQWMXGILP7aGP6%2Frnkoth-en-afk.png?alt=media" alt="An AFK player inside the area does not count"><figcaption><p>An AFK player inside the area does not count</p></figcaption></figure>

{% hint style="info" %}
Moving the mouse to look around counts as moving for the AFK rule. Players standing still but fighting are not AFK.
{% endhint %}

## Flight and elytra

| Option        | Default | What it does                                                                                   |
| ------------- | ------- | ---------------------------------------------------------------------------------------------- |
| `deny-flight` | `true`  | Players inside cannot fly (`/fly`). Players who are flying when they enter fall out of flight. |
| `deny-elytra` | `true`  | Players inside cannot glide. Gliding stops when they enter the area.                           |

Both only affect players in a game mode of `counted-gamemodes`, so builders in creative and spectators can still fly over the KOTH (unless you count creative players).

## Ender pearls

`deny-ender-pearls: true` cancels every ender pearl that would land inside the area, whoever threw it.

## Blocked commands

```yaml
blocked-commands: ['home', 'spawn', 'tpa', 'warp pvp']
```

Commands players cannot use while they are inside the area. Write them without `/`.

* `home` blocks `/home`, `/home base`, and also `/essentials:home`.
* `warp pvp` only blocks `/warp pvp` and leaves other warps free.
* Capital letters do not matter.

In the editor (Rules → **Blocked commands**): click to add one by typing it in chat (with or without `/`), Shift + click to clear the list.

## Protect blocks

`protect-blocks: true`: nobody can break or place blocks inside the area, **and in the floor layer right under it**, while the KOTH runs. Useful when players dig holes or build walls to hold the hill.

## Bypass

Players with `rnkoth.bypass.rules` are not affected by flight, elytra, pearl, command and block rules. Nobody has this permission by default, not even operators. Give it to staff who need to move freely during events.

{% hint style="warning" %}
`rnkoth.bypass.rules` does not make a player count or not count. A staff member in survival, standing in the area, still counts for the capture. Use spectator or vanish to watch an event without taking part.
{% endhint %}
