The Gameplay
OFTRelics is built around one idea: relics are equipped, not held. This page explains the systems that shape how players get relics and use them: types and slots, the menus, unlocking slots, limits and soulbinding, levelling, obtaining relics, and what happens on death. Each is fully configurable.
Types and slots
Every relic has a type. The bundled relics use five: ring, amulet, cube, belt and circlet. A type is a free-form word, not a fixed list, so you can invent as many as you like.
A relic only does something while it sits in a slot. Slots are defined in relics-gui.slots in config.yml, and each one says which relics it accepts with a supports: list:
| Form | Matches |
|---|---|
type:<x> | Any relic whose type is <x> |
relic:<x> | Only the relic with id <x> |
* | Any relic |
A bare value (no type: or relic: prefix) is treated as a relic id if a relic with that id exists, and as a type otherwise. A slot with no supports: list accepts any relic.
The default config has one column of five slots per type: rings in column 1, amulets in column 3, cubes in column 5, belts in column 7 and circlets in column 9. The slot ids follow the pattern <type>-<n>, from ring-1 down to circlet-5.
The menus
Players equip relics through a relic menu, opened with /relics (or /oftrelics, or /oftrelics menu):
Chest menu (
/relics chest): a 6-row chest menu with a custom background drawn by the resource pack. Left-click a slot with a relic on your cursor to equip it, or left-click an equipped relic to pick it back up. Shift-click a relic in your own inventory to equip it into the first free compatible slot (slots are tried in config order), and shift-click an equipped relic to send it back to your inventory.Spatial menu (
/relics spatial): a floating panel of relic slots drawn in front of the player, only visible to them, and used with the mouse. Click an empty slot to equip the first fitting relic from your hand or inventory, and click an equipped one to take it back.Admin menu (
/relics admin, operators only by default): a browser of every loaded relic, grouped by type. Click a relic to get one, shift-click to get a stack.
menu.default-type in config.yml decides which menu opens when no type is given, and players can pick their own with /oftrelics style <type>. See Menus and HUD for everything the spatial menu and the HUD can do.
Unlocking slots
Each slot has its own conditions: list, using the standard libreforge conditions. An empty list means the slot is always open.
In the default config, the first two slots of every type are open, and slots 3 to 5 each need a permission: oftrelics.slot.<slot id>, such as oftrelics.slot.ring-3. Hand these out as rank perks to give players more relic slots. Because they are ordinary libreforge conditions, a slot could just as well unlock at a skill level, a playtime, or anything else libreforge can check.
A locked slot shows its locked-display item, whose lore can list why it is locked through the %conditions% placeholder. An open but empty slot shows its empty-display item. Relics in a slot that becomes locked again stop working until the slot is unlocked.
How many of one relic
max-active on a relic (default 1) caps how many copies of that specific relic one player can have equipped at once, across all their slots. With the default, a player can't fill all five ring slots with the same ring to stack its effect five times; they have to mix different rings.
Soulbinding
Setting soulbound-on-equip: true on a relic makes it bind on equip: the first player to equip a given copy becomes its owner for good. Anyone else who gets that copy later (by trading, picking it up, or through /oftrelics give) can still carry or sell it, but can't equip it. This suits relics whose levelling progress you don't want changing hands. None of the bundled relics are soulbound.
Relic conditions
A relic can have its own conditions: list. While they aren't met, the relic stays equipped but its effects are paused, and its lore shows each condition's not-met-lines. Individual effects can also have their own conditions; for example, the Fury Cube's damage bonus only applies below 40% health.
Levelling
Relics can level up. A levelling relic gains xp only while it is equipped, from the triggers listed in its leveling.xp-sources (for example, landing melee hits or mining blocks). Each copy keeps its own level and xp on the item, so a relic keeps its progress when it is unequipped, stored, traded or re-equipped. Its effects can scale with %level%, and an effect can be held back until a certain level with the relic_level_above condition.
All 22 bundled relics level from 1 to 5. See Leveling for the full system.
Obtaining relics
Players get relics in three ways:
Crafting. Each bundled relic has a crafting-table recipe. A recipe can also be a furnace, blast furnace, smoker, campfire, stonecutter, smithing table, anvil or brewing stand recipe. Every bundled recipe needs its own permission,
oftrelics.craft.<relic id>, which is granted to operators only by default, so give these to your players (oroftrelics.craft.*for all of them) to let them craft. A recipe can use other relics as ingredients; the Cosmos Cube is crafted from the four elemental cubes.Loot. A relic can be added to any loot table: chests in structures (
minecraft:chests/...) and mob drops (minecraft:entities/...). Mob drops only happen when a player made the kill by default, so mob farms can't produce relics, and Looting can be set to raise the chance.Commands. Admins can hand relics out with
/oftrelics giveor pick them from the admin menu.
Dying
Equipped relics live in the relic menu, not the player's inventory, so by default they are kept through death. Set relics-gui.drop-on-death: true in config.yml to make equipped relics drop with the player's other items, or set drop-on-death on a single relic to override the global setting for that relic. Nothing drops when the death keeps inventory (for example, with the keepInventory gamerule).
Where to go next
The bundled relics: what each of the 22 relics does, on the Default Relics page.
Make a relic: put these systems to use in the How to Make a Relic guide.
Configure slots and menus: every option in the Plugin Config.