> For the complete documentation index, see [llms.txt](https://lethium.gitbook.io/lethium-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://lethium.gitbook.io/lethium-docs/gameplay/chat-games.md).

# Chat games

Automatic chat mini-games: trivia, typing, fill in the blank and math, with rewards.

File: `plugins/ClickEmCore/modules/chat-games.yml`. Module id: `chat-games`. Commands: `/chatgames`, `/cg`.

A random mini-game starts in global chat on its own to keep players busy between grinding. The **first correct chat message** wins the round's reward.

### Timing

```yaml
enabled: true
interval-seconds:
  min: 300
  max: 900
min-players-online: 2
answer-window-seconds: 30
```

| Key                           | Meaning                                                    |
| ----------------------------- | ---------------------------------------------------------- |
| `interval-seconds.min`, `max` | A random gap between rounds.                               |
| `min-players-online`          | Below this the round is skipped and rescheduled.           |
| `answer-window-seconds`       | How long a round stays open before the answer is revealed. |

The numbers are starting values that have not been balanced against real play time.

### Game types

```yaml
games:
  trivia-general:
    enabled: true
    reward-coins: 250
    reward-essence: 0
  math:
    enabled: true
    reward-coins: 150
    reward-essence: 0
    min-operand: 2
    max-operand: 50
    operations: ["+", "-", "*"]
```

| Game              | What                                                                                           |
| ----------------- | ---------------------------------------------------------------------------------------------- |
| `trivia-general`  | General knowledge questions.                                                                   |
| `trivia-gamemode` | Questions about ClickEm itself (Fury, Fusion, pets and so on), which teaches players the game. |
| `fastest-type`    | First to type a phrase exactly.                                                                |
| `fill-in-blank`   | Complete the proverb.                                                                          |
| `math`            | A sum. Subtraction never gives a negative answer.                                              |

`reward-coins` are **units scaled by progress**. `reward-essence` pays Artifact Essence, `0` = none. Turn a game off with `enabled: false`.

### Question lists

The file has a list per game, for example:

```yaml
trivia-general:
  - question: "What is the capital of Japan?"
    answers: ["tokyo"]
```

`answers` accepts **any** listed answer, ignoring capital letters and extra spaces. List common spellings. Add a question by adding an entry.

The other lists use their own shape:

```yaml
fastest-type:
  - "the grind never stops"
fill-in-blank:
  - prompt: "Practice makes ___."
    answer: "perfect"
```

### Commands and stats

| Command                                 | Use                    |
| --------------------------------------- | ---------------------- |
| `/chatgames`                            | Your wins.             |
| `/ceadmin chatgames start`              | Start a round now.     |
| `/ceadmin chatgames stop`               | End the current round. |
| `/ceadmin chatgames resetwins <player>` | Reset a player's wins. |

Wins feed the `CHAT_GAME_WINS` leaderboard (see [Leaderboards](/lethium-docs/gameplay/leaderboards.md)).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://lethium.gitbook.io/lethium-docs/gameplay/chat-games.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
