Skip to content

Writing Quests

ErikEdits edited this page Nov 1, 2026 · 1 revision

Writing Quests

You can put quests in two places. Both use the same format.

Where Good for How it updates
<world>/justquests/custom-quests.json Quests for one world or server Reloads by itself when you save the file
A datapack: data/<namespace>/justquests/quests/<id>.json Modpacks and sharing Run /reload

On the plugin, the file is plugins/JustQuests/custom-quests.json, and plugins/JustQuests/quests/ takes one file per quest. See Server Plugin.

custom-quests.json is created on the first start, with explained examples inside. Their keys start with _, so they don't show up as quests. To use one, copy it and remove the _.

A custom quest replaces a datapack quest with the same id.

A first quest

{
  "title": { "en_us": "Sharp Start", "de_de": "Scharfer Start" },
  "description": "Mine some iron, then enchant a sword.",
  "category": "combat",
  "objectives": [
    { "type": "justquests:mine_block", "block": "minecraft:iron_ore", "count": 8 },
    { "type": "justquests:enchant_item", "item": "#minecraft:swords", "count": 1 }
  ],
  "rewards": [
    { "type": "justquests:give_item", "item": "minecraft:diamond", "count": 2 },
    { "type": "justquests:title", "title": "Well done!", "subtitle": "Sharp Start complete" }
  ]
}

In a datapack this is one file. In custom-quests.json it goes under a key, which becomes the quest's id:

{
  "sharp_start": {
    "title": "Sharp Start",
    "objectives": [
      { "type": "justquests:mine_block", "block": "minecraft:iron_ore", "count": 8 }
    ],
    "rewards": []
  }
}

A key without a namespace gets justquests:, so this quest is justquests:sharp_start.

Quest fields

Field Default Meaning
title required The name, as text or a per-language map
objectives required The goals, see Objectives
rewards required The rewards, see Rewards. Can be an empty list.
description empty Text in the quest book, as text or a per-language map
category datapack The group in the quest book. See folders below.
sort 0 The order within the category: lower numbers come first
mode all all: every goal is needed. any: one goal finishes the quest.
requires none Quests that must be done first
requires_min all of them Only this many of requires must be done, for example any 12 of 16
repeatable false The quest can be done again
cooldown_hours none How long a repeatable quest waits before it can be taken again
icon from the first goal An item id for the quest book
permission none Only players with this node see and take the quest, see Permissions
team false A quest for a whole team, see Team Quests
reset_on_death false The progress goes back to zero when the player dies

Languages

title, description, label and message can be plain text or a map per language:

"title": { "en_us": "Sharp Start", "de_de": "Scharfer Start", "fr_fr": "Bon départ" }

Players see their own language, with English as the fallback. Item, block and mob names are translated by the game.

Folders are categories

A quest in data/<namespace>/justquests/quests/mining/iron.json has the id <namespace>:mining/iron. If it names no category, the first folder is its category, so this one is in mining and the book shows "Mining". Deeper folders only sort the files.

The same works for keys like "mining/iron" in custom-quests.json, and for sub-folders of the plugin's quests/ folder.

A resource pack can translate a category with the key justquests.category.mining.

Chains

requires locks a quest until other quests are done:

{
  "title": "Iron Age",
  "requires": ["justquests:stone_age", "justquests:copper_age"],
  "objectives": [
    { "type": "justquests:smelt_item", "item": "minecraft:iron_ingot", "count": 16 }
  ],
  "rewards": [ { "type": "justquests:xp", "amount": 100 } ]
}

With "requires_min": 1, one of the two is enough. The book then says "Needs 1 of 2 quests".

Once a quest unlocks, it starts by itself for the player, unless they turned that off with /quest autoaccept off. Server owners set the default with autoAccept in Settings.

Repeatable quests

{
  "title": "Daily Wheat",
  "repeatable": true,
  "cooldown_hours": 24,
  "objectives": [
    { "type": "justquests:collect_item", "item": "minecraft:wheat", "count": 32 }
  ],
  "rewards": [ { "type": "justquests:xp", "amount": 50 } ]
}

Example datapack

The example datapack has one quest for every objective and reward type, plus tags, filters, chains, repeatable and multi-language quests. Copy it into your world's datapacks folder, run /reload, then /quest list examples.

Clone this wiki locally