Codex
  • Codex Wiki
  • How to Start
  • Discoveries/Categories Tutorial
  • Items Tutorial
  • Config.yml Tutorial
  • Inventory.yml Tutorial
  • Actions
  • Commands and Permissions
  • PlaceholderAPI variables
  • API
  • Customized Discoveries Tutorial
  • Default Files
    • messages.yml
    • inventory.yml
  • messages.yml Translations
    • Spanish (by PiolaMC Network)
Powered by GitBook
On this page
  • Inventory Items
  • 1. Category
  • 2. Discovery Unlocked
  • 3. Discovery Blocked
  • Rewards
  • Per Discovery
  • All Discoveries
  • Discoveries
  • Name
  • Description
  • Discovered On
  • Click Actions
  • Click Actions Cooldown
  • Custom Inventory Items
  • Custom Rewards

Was this helpful?

Discoveries/Categories Tutorial

PreviousHow to StartNextItems Tutorial

Last updated 1 month ago

Was this helpful?

In this page you will find all properties of discoveries/categories configuration files. Everytime you modify something in these files you must reload the plugin using /codex reload.

Inventory Items

The format of each item is the following:

inventory_items:
  <type>:
    <item>

Remember that the item to be displayed has the properties listed .

You can use PlaceholderAPI variables on the name and lore of all these items.

1. Category

Each category will be represented by its own item in the main inventory. You can tell the players on this item the amount of discoveries the category has and information of the category.

category:
  id: MAP
  name: "&7Category: #6bcbfe&lWorld Regions"
  lore:
  - "#eeeeeeDifferent regions you've explored will"
  - "#eeeeeebe displayed here."
  - ""
  - "&7Unlocked: %unlocked% &8[%progress_bar%&8] &8(&7%percentage%&8)"

Variables:

  • %unlocked% (Will be replaced with the following messages.yml messages depending of the status of discoveries found: currentUnlockedDiscoveriesColorNone, currentUnlockedDiscoveriesColorAll, currentUnlockedDiscoveriesColorIncomplete)

  • %progress_bar% (A progress bar showing the progress of the discoveries unlocked from this category)

  • %percentage% (Percertage of the discoveries unlocked from this category)

2. Discovery Unlocked

The item displayed on the category inventory when the discovery has been unlocked.

discovery_unlocked:
  id: PAPER
  name: "%name%"
  lore:
  - "%description%"
  - ""
  - "&8Discovered on %date%"

Variables:

  • %name% (Name of the discovery)

  • %description% (Description of the discovery)

  • %date% (Date the discovery was unlocked)

3. Discovery Blocked

The item displayed on the category inventory when the discovery has not been found.

discovery_blocked:
  id: GRAY_DYE
  name: "&c??"
  lore:
  - "&7You haven't unlocked this discovery yet."

Rewards

Per Discovery

Default actions to be executed when the player finds a discovery from this category.

rewards:
    per_discovery:
      - "centered_message: #6bcbfe&m00                                                 00"
      - "centered_message: "
      - "centered_message: #eeeeee&lCODEX UPDATED"
      - "centered_message: &7World Regions: %name%"
      - "centered_message: "
      - "centered_message: &7Check it now by using #eeeeee/codex"
      - "centered_message: "
      - "centered_message: &7Rewards: &a+50XP"
      - "centered_message: "
      - "centered_message: #6bcbfe&m00                                                 00"
      - "title: 20;60;20;#eeeeee&lCODEX UPDATED;&7Region: %name%"
      - "playsound: BLOCK_GILDED_BLACKSTONE_STEP;10;0.1"
      - "console_command: xp give %player% 50"

Variables:

  • %name% (Name of the discovery)

  • %player% (Name of the player)

All Discoveries

Default actions to be executed when the player finds all discoveries from this category.

rewards:
    all_discoveries:
      - "centered_message: #6bcbfe&m00                                                 00"
      - "centered_message: "
      - "centered_message: #eeeeee&lCODEX CATEGORY COMPLETED"
      - "centered_message: &7World Regions"
      - "centered_message: "
      - "centered_message: &7Congratulations!"
      - "centered_message: "
      - "centered_message: &7Rewards: &a+5000XP"
      - "centered_message: "
      - "centered_message: #6bcbfe&m00                                                 00"
      - "title: 20;60;20;#eeeeee&lCODEX CATEGORY COMPLETED;&7World Regions"
      - "playsound: BLOCK_GILDED_BLACKSTONE_STEP;10;0.1"
      - "console_command: xp give %player% 5000"

Variables:

  • %player% (Name of the player)

Discoveries

Discoveries must be added below the discoveries section using the following format.

discoveries:
  <discovery_id>:
    name: <name>
    description:
    - <description lines>

Name

Name of the discovery. Used to be displayed on inventories and messages.

name: "#6bcbfe&lShadow Swamp"

Description

Description of the discovery. Used to be displayed on inventories and messages.

description:
      - "#eeeeeeAn abomination found on the Shadow Swamp. It's"
      - "#eeeeeevery difficult to beat."
      - ""
      - "&7Drops:"
      - "&8❱ #eeeeeeShadow Elixir &8(25%)"
      - "&8❱ #eeeeeeIron Ingot &8(90%)"

Discovered On

Determines how can this discovery be unlocked.

WorldGuard Region

Set the type option to WORLDGUARD_REGION.

value.region_name: Name of the region.

discovered_on:
  type: WORLDGUARD_REGION
  value:
    region_name: shadow_swamp

Mob Kill

The discovery is unlocked when killing a vanilla entity.

Set the type option to MOB_KILL.

value.mob_name: Optional. Custom name of the mob/entity. Don't use color codes.

discovered_on:
  type: MOB_KILL
  value:
    mob_type: ZOMBIE
    mob_name: Shadow Warrior

Mythic Mob Kill

Set the type option to MYTHIC_MOB_KILL.

value.mob_type:Id of the MythicMobs mob. You can use ";" to include multiple ids.

discovered_on:
  type: MYTHIC_MOB_KILL
  value:
    mob_type: forest_corrupter
discovered_on:
  type: MYTHIC_MOB_KILL
  value:
    mob_type: crab;super_crab;mega_crab

Elite Mob Kill

Set the type option to ELITE_MOB_KILL.

value.mob_type:Id of the EliteMobs mob (name of the file without .yml). You can use ";" to include multiple ids.

discovered_on:
  type: ELITE_MOB_KILL
  value:
    mob_type: ember

Click Actions

click_actions:
- "console_command: warp shadow_swamp %player%"

Click Actions Cooldown

Adds a cooldown (in seconds) to execute the defined actions when clicking on the discovery item.

click_actions_cooldown: 60

Custom Inventory Items

Discovery Unlocked

inventory_items:
  discovery_unlocked:
    id: PAPER
    name: "%name%"
    lore:
    - "%description%"
    - ""
    - "&8Discovered on %date%"
    - ""
    - "&a&lCLICK &ato teleport."

Discovery Blocked

inventory_items:
  discovery_blocked:
    id: GRAY_DYE
    name: "&c??"
    lore:
    - "&7You haven't unlocked this discovery yet."
    - ""
    - "&7Hint: A very important city."

Custom Rewards

rewards:
- "centered_message: #6bcbfe&m00                                                 00"
- "centered_message: "
- "centered_message: #eeeeee&lCODEX UPDATED"
- "centered_message: &7World Regions: %name%"
- "centered_message: "
- "centered_message: &7Check it now by using #eeeeee/codex"
- "centered_message: "
- "centered_message: &7Rewards: &a+300XP&7, &a$5.000"
- "centered_message: "
- "centered_message: #6bcbfe&m00                                                 00"
- "title: 20;60;20;#eeeeee&lCODEX UPDATED;&7Region: %name%"
- "playsound: BLOCK_GILDED_BLACKSTONE_STEP;10;0.1"
- "console_command: xp give %player% 300"
- "console_command: eco give %player% 5000"
      

Rewards are given through actions. All Actions can be found .

The discovery is unlocked when entering a WorldGuard () region.

value.mob_type:Type of the mob/entity. All entity types here:

The discovery is unlocked when killing a MythicMobs () mob.

The discovery is unlocked when killing a EliteMobs () mob.

Actions to be executed when the player clicks on the inventory item associated with this discovery, when the discovery has been found. All actions . Optional.

You can replace the with custom ones used only for this discovery.

The item displayed on the when THIS discovery has been unlocked. All variables from applies.

The item displayed on the when THIS discovery has not been found. All variables from applies.

You can replace the with custom ones only for this discovery.

HERE
HERE
https://dev.bukkit.org/projects/worldguard
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/entity/EntityType.html
https://www.spigotmc.org/resources/5702/
https://www.spigotmc.org/resources/elitemobs.40090/
HERE
Category Inventory Items
category inventory
HERE
category inventory
HERE
Per Discovery Rewards