Skip to content

Objectives

ErikEdits edited this page Nov 9, 2026 · 2 revisions

Objectives

An objective is one goal of a quest. A quest lists them under objectives.

All types

Type Fields Counts when the player...
justquests:collect_item item, count picks the item up (mining, harvest, mob drops)
justquests:have_item item, count has that many in the inventory at once, wherever they came from
justquests:craft_item item, count crafts it (crafting table, inventory or stonecutter)
justquests:smelt_item item, count takes it out of a furnace
justquests:consume_item item, count eats or drinks it
justquests:enchant_item item (optional), count enchants an item at an enchanting table
justquests:use_item item, count uses it and it does something (throw, place, apply, mine...)
justquests:mine_block block, count breaks the block
justquests:place_block block, count places the block
justquests:kill_mob entity, count kills the mob
justquests:tame_animal entity, count tames the animal
justquests:breed_animal entity, count breeds the animal
justquests:reach_level level reaches the XP level
justquests:reach_location x, y, z, radius (default 4), dimension (optional) stands at the spot
justquests:visit_dimension dimension enters the dimension (vanilla or modded). A modded dimension shows a name made from its id, "stellaris:moon" becomes "Moon"; a resource pack can set justquests.dimension.stellaris.moon
justquests:gain_advancement advancement earns the advancement

The Create Addon adds 14 more types for Create's machines.

Items, blocks and mobs

item can be an id or a tag:

{ "type": "justquests:collect_item", "item": "minecraft:oak_log", "count": 16 }
{ "type": "justquests:collect_item", "item": "#minecraft:logs", "count": 16 }

block and entity take an id or a tag as well, such as #minecraft:logs or #minecraft:skeletons.

Filters

item can also be an object with filters. The same JSON works on every version.

"item": { "id": "minecraft:potion", "potion": "minecraft:swiftness" }
"item": { "id": "#minecraft:swords", "enchantments": { "minecraft:sharpness": 2 }, "name": "Excalibur" }
  • enchantments are minimum levels.
  • name is a name given in an anvil.
  • Filters are most useful for consume_item, enchant_item and craft_item, because they are checked on the item the event is about.
  • use_item counts per item type and ignores filters.

Items from machines: have_item

collect_item only counts items picked up from the ground. Machines of other mods work without a player, so their items never count for it.

have_item looks into the inventory instead, so it doesn't matter whether the items came from a machine, a chest or a trade.

  • The most the player has held at once counts, so moving items in and out doesn't add up.
  • The progress doesn't go back when the items are used.
  • Items already in the inventory count too.

If a quest should check that a Create machine really made the item, use the Create Addon.

Your own goal text: label

Any objective can set label, as text or a per-language map. The quest book, the tracker and the chat show it instead of the generated goal line:

{ "type": "justquests:have_item", "item": "create:iron_sheet", "count": 16,
  "label": { "en_us": "Press Iron Sheets", "de_de": "Eisenbleche pressen" } }

This or that: group

Objectives with the same group are alternatives, and one of them is enough. Objectives without a group are all still needed, so you can mix them. This quest needs a backpack, crafted or found, and 10 leather:

"objectives": [
  { "type": "justquests:craft_item", "item": "travelersbackpack:standard", "count": 1, "group": "backpack" },
  { "type": "justquests:collect_item", "item": "#travelersbackpack:backpacks", "count": 1, "group": "backpack" },
  { "type": "justquests:collect_item", "item": "minecraft:leather", "count": 10 }
]

The quest book, the tracker and /quest progress show "- or -" between the alternatives.

"mode": "any" on the quest is different: there, any one objective finishes the whole quest.

Every kind once: distinct

With "distinct": true, an objective with item, block or entity counts each kind only once. This one needs 10 different foods, and the goal reads "(all different)":

{ "type": "justquests:consume_item", "item": "#c:foods", "count": 10, "distinct": true }

Clone this wiki locally