Creating Quests
A quest is one YAML file. To add a quest you write the file, drop it in, and reload. No code, no restart.
Add a quest in three steps
Section titled “Add a quest in three steps”-
Write the file
Section titled “Write the file”Copy the template below into a new
.ymlfile. Give it a uniqueid. -
Put it in the quests folder
Section titled “Put it in the quests folder”In
GLOBALmode it goes flat inplugins/zDailyQuests/quests/. InRARITYmode it goes in theeasy/,normal/, orhard/subfolder. See Selection Modes. -
Reload
Section titled “Reload”Run
/dq reload. The pool is re-read and the console tells you how many quests are loaded.
The full template
Section titled “The full template”# Unique id for this quest, must not repeat across filesid: kill_zombies_25
# Name shown in the menu. Used when use-single-display is truedisplay-name: "&aZombie Slayer"
# Text under the quest name. %progress% and %target% are filled in for youdescription: - "&7Kill zombies to complete this quest" - "&7Progress: %progress%/%target%"
# Item shown as the quest in the menu. Used when use-single-display is true.# Can be a material, or a player head: head-<name> or basehead-<base64>icon: ZOMBIE_HEAD
# A quest goes through stages: not started, in progress, ready to claim, done.# true = show the same name, text and icon in every stage (the three keys above)# false = show a different name, text and icon per stage (set in phase-display below)use-single-display: true
# What this quest tracks, see the Objective Types page for the full listobjective: KILL
# Optional. Only some objectives need a type. Put one value or a list.# Leave it out to mean "any" (any mob, any block, and so on)target-type: ZOMBIE
# How many you need to finish the quest oncetarget-amount: 25
# How many times a player can do this quest in the same day.# 1 = do it only once. Higher = it can be done again, up to this many timesmax-completions: 1
# Difficulty label. Only shown in GLOBAL mode. In RARITY mode the folder sets itdifficulty: EASY
# Reward for finishing this one questreward: commands: - "eco give %player% 250" items: - material: EMERALD amount: 3Head icons
Section titled “Head icons”The icon (and any per-phase icon) can be a player head instead of a material:
| Spec | Result |
|---|---|
head-<playername> | that player’s skin, e.g. icon: head-Notch |
basehead-<base64> | a custom textured head, the base64 is the value you copy from a heads site |
icon: "head-Notch"A bad or missing texture falls back to a plain head rather than breaking the menu. The same specs work for menu decoration items, see The Menu.
Per-phase display
Section titled “Per-phase display”Set use-single-display: false to give a quest a distinct look in each phase, for example a “click to claim” chest icon when it is ready:
use-single-display: falsephase-display: not-started: icon: ZOMBIE_HEAD name: "&7Zombie Slayer" lore: - "&7Not started yet" in-progress: icon: ZOMBIE_HEAD name: "&aZombie Slayer" lore: - "&7Progress: %progress%/%target%" completed-unclaimed: icon: CHEST name: "&eZombie Slayer (click to claim!)" lore: - "&eYou did it, click to grab your reward" completed: icon: LIME_STAINED_GLASS_PANE name: "&aZombie Slayer (done)" lore: - "&7Completed"The completed-unclaimed phase only ever shows in manual claim mode.
Advanced examples
Section titled “Advanced examples”id: explore_spawn_ruinsdisplay-name: "&aExplorer"description: - "&7Go check out the ruins near spawn"icon: MAPobjective: LOCATIONlocation: world: world x: -4 y: 103 z: 7 radius: 3max-completions: 1difficulty: NORMALreward: commands: - "eco give %player% 150"Checked when the player opens the menu while inside the radius.
id: farmer_cookiesdisplay-name: "&aCookie Run"description: - "&7Buy 32 cookies from a level 3 farmer villager"icon: COOKIEobjective: VILLAGER_TRADEtarget-type: COOKIEvillager-profession: FARMERvillager-level: 3target-amount: 32max-completions: 1difficulty: NORMALreward: commands: - "eco give %player% 300"Both villager-profession and villager-level are optional and independent. Level means “at least this level”.
id: shear_white_sheep_10display-name: "&aWool Gatherer"description: - "&7Shear white sheep"icon: WHITE_WOOLobjective: SHEARtarget-type: SHEEPsheep-color: WHITEtarget-amount: 10max-completions: 1difficulty: EASYreward: items: - material: SHEARS amount: 1The six starter quests
Section titled “The six starter quests”The plugin ships with a small pool so you have working examples to copy:
Directoryquests/
- kill_zombies_25.yml KILL
- break_stone_64.yml BREAK
- place_planks_32.yml PLACE
- craft_bread_16.yml CRAFT
- catch_fish_10.yml FISH
- deal_damage_200.yml DEAL_DAMAGE