Skip to content
gottsch edited this page Oct 24, 2022 · 50 revisions

This wiki is currenlty under construction. It will probably be perpetually under construction :)

Treasure2

Explore and discover buried treasure containing coins, gems, jewelry, magical charms and other items!

The objective to Treasure2 is simple - find hidden treasure chests and get the loot! Treasure chests may be secured by a various assortment of locks and can only be unlocked by finding the corresponding keys. Finding the correct keys is an adventure unto itself.

Config

Beginning with v1.7.0 all config files have been merged into one main config (treasure2-cX.X.cfg). The config filename is appended with a version so that any developmental updates to the config that may cause conflicts will not interfere with previous versions. See the config page for more detatils.

Rarities

There are seven (7) levels of rarity that apply to chests, keys, locks, loot tables, adornments, charms and runes. These levels give a general indication of the probability that an item will be generated. Corresponding items generally have the same or similar rarity. Ex. a Common chest can be locked with Common and/or Uncommon locks. This chest would use a Common loot table.

  • Common (All)
  • Uncommon (All)
  • Scarce (All)
  • Rare (All)
  • Epic (All)
  • Legendary (Loot tables, adornments, charms, runes)
  • Mythical (Loot tables, adornments, charms, runes)

Chests

Chests of various shapes and sizes can be discovered. Each chest having a different rarity which determines the likelihood of it being generated and the quality of its treasure. Each chest can have a varying number of locks that will require the appropriate key(s) to open.

chests > list

  • Wooden Chest (Common)
  • Moldy Crate (Common)
  • Crate (Uncommon)
  • Ironbound Chest (Uncommon)
  • Pirate Chest (Scarce)
  • Iron Strongbox (Scarce)
  • Wither Chest (Scarce)
  • Skull Chest (Scarce)
  • Gold Strongbox (Rare)
  • Safe (Rare)
  • Gold Skull Chest (Rare)
  • Dread Pirate Chest (Epic)
  • Compressor Chest (Epic)
  • Cauldron Chest (Epic)
  • Spider Chest (Rare)
  • Viking Chest (Uncommon)
  • Cardboard Box (Common)
  • Milk Crate (Common)
  • Crystal Skull (Epic)

Chests can be discovered in Graveyards, below the graveyard in treasure Pits (think Oak Island), in Sunken Ships or in surface/underwater Ruins

Keys

Keys are used to unlock Locks. Most keys have a corresponding Lock that it is able to unlock. However, there are some special keys that have additional unlocking abilities. Ex. unlocking all METAL locks. To use a key, you must sneak + use it. You can view the key's attributes by hovering over the item in your inventory.

keys > attributes

  • "name" - the name of the key.
  • "category" - the category that the key belongs to. Can be one of: BASIC, METALS, GEMS, MAGIC, POTION, MOB, CRYPTID, MYTHICAL, WITHER, UNIQUE. (Currently only basic, metals, gems, mob and wither are used).
  • "rarity" - the rarity of the key. Indicates the likelihood of finding the key in treasure loot.
  • "breakable" - indicates whether the key can break. Keys will break if the success probability is not met or if used in the incorrect lock(s).
  • "craftable" - indicates whether the key can be crafted.
  • "max. uses" - the number of times a key can be used successfully or unsuccessfully.

Note: Keys are non-stackable. However, keys are mergeable. By placing 2 keys in an anvil you can merge them, which will combine their max. uses in the resultant key, up to a max of 1000 uses.

keys > standard list

  • wood_key Wood Key (Common | Elemental)
  • stone_key Stone Key (Common | Elemental)
  • ember_key Ember Key (Scarce | Elemental)
  • leaf_key Leaf Key (Uncommon | Elemental)
  • iron_key Iron Key (Uncommon | Metals)
  • gold_key Gold Key (Scarce | Metals)
  • diamond_key Diamond (Rare | Gems)
  • emerald_key Emerald (Rare | Gems)
  • ruby_key Ruby (Epic | Gems)
  • sapphire_key Sapphire (Epic | Gems)
  • spider_key Spider (Scarce | Mob)
  • wither_key Wither (Scarce | Wither)

keys > specials list

  • pilferers_lock_pick Pilferer's Lock Pick
    • Unlocks common and uncommon locks
    • Rarity = common
    • Breakable = true
    • Craftable = true
    • Success Probability: common = 24%, uncommon = 12%
  • thiefs_lock_pick Thief's Lock Pick
    • Unlocks common, uncommon and scarce locks
    • Rarity = uncommon
    • Breakable = true
    • Craftable = true
    • Success Probability: common = 32%, uncommon = 24%, scarce = 16%
  • Lightning Key
    • Unlocks all elemental locks (wood, stone, leaf, ember)
    • Rarity = scarce
    • Breakable = false
    • Craftable = false
    • Success Probability = 95%
  • skeleton_key Skeleton Key
    • Unlocks common, uncommon, scarce, and rare (excluding wither) locks
    • Rarity = rare
    • Breakable = false
    • Craftable = false
    • Success Probability = 95%
  • metallurgists_key Metallurgist's Key
    • Unlocks all metal locks (iron and gold)
    • Rarity = rare
    • Breakable = false
    • Craftable = false
    • Success Probability = 95%
  • jewelled_key Jewelled Key
    • Unlocks all gem locks (diamond, emerald, ruby, sapphire)
    • Rarity = epic
    • Breakable = false
    • Craftable = false
    • Success Probability = 95%

Key Ring

A key ring key_ring is a special container that only holds keys. You can save valuable inventory space by placing your keys in a key ring. You can use a key ring to unlock chests just as you would use a key. A key ring will check all keys it contains to determine if the key is able to unlock a lock, and then attempt to unlock it.

Locks

Locks are used to lock treasure chests. All locks have a corresponding Key that it is used to unlock it. However, certain locks can be unlocked by special keys and lock picks. You can view the lock's attributes by hovering over the item in your inventory. You can re-use locks to protect your own loot that is stored in treasure chests.

locks > list

  • wood_lock Wood Lock (Common)
  • stone_lock2 Stone Lock (Common)
  • iron_lock Iron Lock (Uncommon)
  • gold_lock Gold Lock (Scarce)
  • diamond_lock Diamond Lock (Rare)
  • emerald_lock Emerald Lock (Rare)
  • ruby_lock2 Ruby Lock (Epic)
  • sapphire_lock2 Sapphire Lock (Epic )
  • spider_lock Spider Lock (Scarce)
  • wither_lock Wither Lock (Scarce)

locks > attributes

  • "name" - the name of the lock.
  • "category" - the category that the lock belongs to. Can be one of: BASIC, METALS, GEMS, MAGIC, POTION, MOB, CRYPTID, MYTHICAL, WITHER, UNIQUE. (Currently only basic, metals, gems, mob and wither are used).
  • "rarity" - the rarity of the lock. Determines which locks are used when generating chests. ie a chest with a rare loot table will use rare locks.
  • "craftable" - indicates whether the key can be crafted.

Coins, Gemstones and Wishing Wells

Coins (Copper copper_coin, Silver silver_coin and Gold gold_coin) and Gemstones can be found as loot in treasure chests. They can be thrown into Wishing Wells to generate a random loot item. Each type has a different loot table to generate from, depending on their rarity. The quality of loot increases with the rarity of the item.

Charms

See Adornments, Gemstones, Charms and Runes page

Pouches

Pouches were introduced in version 1.12.0 and revised in 2.0.0. Pouches can hold Coins, Gems, Pearls, Adornments and Charms, saving valuable main inventory space. There is only one kind of pouch item: Pouch image.

Pouch Inventory
image

Graveyards

Graveyards are one of the surface markers that indicate a treasure is in the area. Most of the time the chests are buried, but lower tier chests can sometimes be found on the surface. Gravestones emit white mist/fog. Graveyards can also spawn Bound Souls. A Bound Soul can regenerate its health as long as it is within a specific radius of the gravestone that it is bound to.

Pits

Pits are found under surface markers such as graveyards and crypts. A pit consists of layers of logs, sand, and gravel. This is based off the treasure of Oak Island in Nova Scotia, Canada. Pits can range in depth, with the higher tier, rarer chests found deeper. Excavating pits can be dangerous as they can be trapped. Pits can also have structures (rooms) at the bottom. You can configure the likelihood of structures generating by editing the config.

Ruins

Ruins can be both above ground and underground. By default, ruins are subject to the decay rulesets so that they will have a range in their state of decay. Treasure chests are found within the ruins.

Ships

Ships can be found sunken in the ocean and sometimes found on beaches. Decay rulesets can also be applied to ships, by enabling the option in the ship's nbt file.

Wither Trees

Wither trees (or groves) are like a mini-biome. They consist of a main wither tree and surrounded by regular wither trees. Regular wither tree spawn poison mist and the main wither tree spawns wither mist. Buried below the wither trees is the treasure chest. Wither branches and roots can be used to create a Wither Key. Wither Locks can only be unlocked by Wither Keys.

Mist

Mists generate in certain areas, such as graveyards and wither groves. They can be dispersed by using a series of torches around their source. (All mists render on the client only).

  • Mist or fog encompasses graveyards. This mist is white in color and is benign - it is for effect only.
  • Poison Mist can be found surrounding wither trees. It is green in color and will inflict poison on you if you pass through it.
  • Wither Mist can be found surrounding the main wither tree. It is black in color and will inflict wither on you if you pass through it.

Collectibles

(TODO)

Mobs

  • Wooden Chest Mimic
  • Pirate Chest Mimic
  • Bound Soul

Loot Tables

All chest and wishing well loot tables have been exposed for customization. They can be found at [Minecraft install folder]/config/treasure2/loot_tables/[modid]/[rarity]/. Under each rarity subfolder there are 1 or more loot table .json files. These can be edited or new files added. A random file (by rarity) will be selected when populating a chest.

NOTE: Loot tables are not related strictly to chests by rarity. Ex. a Common chest could use a Common or Uncommon loot table. A Rare chest could use a Rare or Scarce loot table.

Meta Files

A meta file filename must match it's owning structure's filename, like blockstate, model and item files must match filenames. (TODO)

Ex. tower1.json

{
  "name": "tower1",
  "description": "",
  "author": "gottsch",
  "archetypes": ["surface"],
  "type": "ruin",
  "themes": ["dungeon"],
  "rarities": ["common"],
  "biomeWhiteList": [],
  "biomeBlackList": [],
  "decayRuleSetName": ["default_ruleset", "aged_ruleset", "ruinous_ruleset"]
}

meta file properties

  • "name" - name of structure (not used in game).
  • "description" - description of structure (not used in game).
  • "author" - name of the creator of the structure (not used in game).
  • "archetypes" - list of main types that the structure belongs to. Values = surface | submerged | subterranean | float | (TODO) (required)
  • "type" - the type of structure. A categorization. (not used)
  • "themes" - a list of themes. Used to determine the block set to used. (not used)
  • "rarities" - a list of rarities of the structure. Used to determine the likelihood of generation. (not used)
  • "biomeWhiteList" - a list of allowed biomes to generate in. Mutually exclusive with biome black list. Supercedes black list if both values are populated. (optional)
  • "biomeBlackList" - a list of disallowed biomes to generate in. (optional)
  • "decayRuleSetName" - a list of decay rulesets to use for decay processing. (optional)

Structures / NBTs

(TODO)

Recipes

(TODO) The Treasure Tool is a special item used in recipes to remove collisions between Treasure2 recipes and vanilla minecraft and other mods recipes. It is used in most all the recipes in Treasure2.

Recipes
Treasure Tool treasure_tool_recipe
Pilferer's Lock Pick pilferers_lock_pick_recipe
Thief's Lock Pick thiefs_lock_pick_recipe
Spider Key spider_key_recipe
Wither Key wither_key_recipe
Ruby Key ruby_key_recipe
Sapphire Key sapphire_key_recipe
Key Ring
Pouch pouch_recipe
Skull Chest
Gold Skull Chest
Gravestone
Wither Planks

Decay Rulesets

Decay Rulesets allow you to control how treasure structures decay when they are generated. There are 3 rulesets that come bundled with the mod -> default_ruleset (medium decay), aged_ruleset (light decay), and ruinous_ruleset (heavy decay). These file can be found at [Minecraft install folder]/config/treasure2/decay/

A ruleset is made up of a few properties and a list of decayRules:

Ex. partial of default_ruleset.json

{
  "name": "default",
  "verticalDecayRate": {
    "min": 5.0,
    "max": 10.0
  },
  "initialBlockStrength": 100.0,
  "blockStrengthThreshold": 0.0,
  "blockStrengthDecayRate": {
    "min": 12.5,
    "max": 20.0
  },
  "blockStrengthDistanceDecayRate": {
    "min": 22.0,
    "max": 30.0
  },
  "decayRules": {
    "minecraft:stonebrick": {
      "decayIterations": 5,
      "decayProbability": 20.0,
      "decayBlocks": [
      "minecraft:stonebrick@1",
      "minecraft:stonebrick@2",
      "minecraft:cobblestone@0",
      "minecraft:gravel@0",
      "minecraft:air@0"
      ]
    },
    ...
  }
}

ruleset properties

  • "name" - the name of the ruleset.
  • "verticalDecayRate" - the minimum and maximum rate which the decay increases by, as the y position increases in the structure. A value will be randomized between the min. and max. values.
  • "initialBlockStrength" - this is the the initial strength that a block begins with. When a block's strength drops below the "blockStrengthThreshold" value, the block is removed.
  • "blockStrengthThresold" - when the block strength drop below with value, it is removed (replaced with air).
  • "blockStrengthDecayRate" - the minimum and maximum rate at which a block's strength decays as it decays from one block to another. A value will be randomized between the min. and max. values.
  • "blockStrengthDistanceDecayRate" - the minimum and maximum rate that a block loses strength as the distance from "wall" blocks increases.
  • "decayRules" - a set of rules to determine how a block decays into other blocks.

In the above ruleset, a block has an initial strength of 100. If the structure is 5 blocks high, the block strength at y=5 will be 50-75 (because the vertical decay rate is a random number between 5-10 * 5 height). If the block is 2 blocks away from a "wall" block (a wall block is a block that has a supporting block beneath it), then its strength will be further reduced by 22-30 (blockStrengthDistanceDecayRate * (distance-1)). If the block has decayed, say from stonebrick to mossy stonebrick, it's strength would be further reduced by 12.5-20 (decayStrengthDecayRate * 1). So the blocks final strength would be between -20 and 10.5. If at <= 0 then it would be removed from the structure.

ruleset > decayRules properties

  • block name - the name of the block being decayed. ex. "minecraft:stonebrick".
  • "decayIterations" - the number of times an attempt is made to decay the block.
  • "decayProbability" - the probability that a block will decay.
  • "decayBlocks" - an ordered list of block id/states that a block decays into.

In the above decayRules for stonebrick, a "roll" would be performed 5x. If a "roll" of 20 or less was rolled 3x, the current block would decay into cobblestone as it is the third block in the list.

Commands

Spawn Chest Command

Usage: /t2-chest <x> <y> <z> [-rarity <rarity>] [-facing <facing>] [-chest <chest>] [-locked] [-sealed]

  • rarity: determines chest and loot
  • facing: the direction the chest is facing (v1.14.0+)
  • chest: override which chest to use (loot is still dependent on rarity) (v1.14.0+)
  • locked: will the chest have locks (v1.14.0+)
  • sealed: is the chest sealed ie. generates loot on first open (v1.14.0+) (note: a locked chest is sealed, but a sealed chest is not necessarily locked ie. you can have a loot generating chest without locks).