RPG Lore 2.2.1 (Forge 1.20.1)
Curse Maven Snippet
What's new
New Features
- Lore Codex browser -- search across titles, authors, categories, and tags with live filtering; organize by category; filter by All, Collected, Unread, Favorites, or Missing; sort by Default, Title, Category, or Recently found; browse with arrow keys and Enter; press Esc to close or exit search; all view state (search text, category, filter, sort, page, selection) is restored when you return from reading a book
- Unread markers and favorites -- collected books show an unread indicator (toggleable in client config) when not yet read; click the star icon to mark any book as a favorite; favorite status persists across sessions
- Codex spare copy display -- duplicates appear as
×nwith a copy icon (greyed when no spares remain); extraction is blocked when the spare bank is empty - Entry tooltips -- hover over a Codex entry to see the collected book's full details, category, and series position
- Optional "Open Lore Codex" keybind -- unbound by default; opens the Codex from inventory or Curios slot when set (server verifies possession)
- Interactive text in books -- hover tooltips with
show_textand click events (suggest_command,copy_to_clipboard,open_url,change_page) work in page text;run_commandrequires the server configreader.allowRunCommandClicks=true(default false) for security - Book title wrapping -- titles up to two lines auto-scale (1.0× down to 0.75×) and truncate with ellipsis if needed, preventing poor display on long titles
- Pack validation command --
/rpglore validate [book_id](OP level 2) checks JSON syntax, unknown fields, field types and ranges, andformat_versionwithout reloading; bulk validation lists each definition, single-book validation shows full diagnostics - Structured validation diagnostics -- validation errors and warnings include JSON path, line/column position, and actionable suggestions; strict JSON parsing with lenient fallback
- Reload report --
/rpglore reloaddisplays loaded/added/changed/removed counts, config overrides of datapack definitions, and warning/error counts in chat;/reloadlogs a summary to the server log - Datapack lore support -- define books at
data/<namespace>/rpg_lore/books/<path>.jsonwith automatic ID generation (<namespace>:<path>unless the JSON declaresid); config definitions override datapack ones (logged at INFO) - Multiple acquisition routes -- books acquire through additive
entity_drop,loot_table, andadvancementrules, allowing the same book to drop from mobs, appear in chests, and be granted by advancements simultaneously; legacydrop_conditionsstill works and becomes a single entity_drop rule - Loot-table injection -- rules with type
loot_tableinject books into named tables (chests, fishing, gameplay) with configurable chance and weight; at most one book per table generation - Advancement delivery -- rules with type
advancementgrant books when players earn advancements; delivery mode chooses between Codex (permanent) or inventory (once per player per book; a revoke and re-grant cannot mint a duplicate) - Book discovery metadata --
tagsare searchable keywords;discovery_hintshows on uncollected entries when enabled;seriesandseries_orderorganize related books - Acquisition rules public API -- mods call
LoreAcquisitionService.collect()to add books with source attribution;LoreCollectedEventfires on the Forge event bus (server-side, first-time collection only) carrying player, book ID, and source - Automated regression tests -- JUnit tests cover data parsing and save format migration; Forge GameTests cover Codex gameplay including entity-drop conditions, Codex pruning and reset, player granting, and death/respawn scenarios (run
./gradlew runGameTestServeror./gradlew runDatawith Curios excluded from both headless runs)
Bug Fixes
- Long lore titles remain readable -- books with titles longer than vanilla's 32-character limit now load their pages without showing an invalid-book error; JSON text components and plain-text fallback remain supported
- Long author names fit the title page -- author text wraps within the page width and truncates with an ellipsis when it exceeds the remaining vertical space
- Starter Codex no longer lost on grant when inventory is full -- previously, the inventory-full path used the standard item-drop route, triggering the soulbound toss guard which cancelled the drop and pushed the item back at the full inventory, destroying the Codex while the grant flag was already set; the Codex is now placed directly on the ground at the player's feet via ItemEntity creation, so it can be picked up without re-triggering the guard
Improvements
- Reading marks books as read -- opening a book from the Codex or from your hand immediately records read state; read state persists with discovery timestamp
- Save format 2 with auto-migration -- existing 2.1.x saves migrate automatically; all pre-2.2.0 books are marked read so returning players are not flooded with "new" entries
- Network protocol 3 -- clients and servers must both update; traffic is reduced by sending the full catalog only when it changes or when a book switches from hidden to revealed
- Format version validation --
format_version: 1is supported; any other value produces an error - Codex read state and discovery timestamps -- tracked per book per player and persisted to
data/rpg_lore_codex.dat - Entity drop indexing -- registry builds an immutable index at load time with exact-mob buckets, tag/biome buckets, and loot-table/advancement lookups, so mob deaths only evaluate applicable rules instead of scanning all books
- Load resilience -- if the books directory becomes unreadable, the previous catalog remains active instead of being replaced with an empty one
- Duplicate handling naming -- "duplicate prevention" terminology replaced with "duplicates" control offering two modes: store spares (default) or leave on ground
- New server config options --
acquisition.enableEntityDrops(default true),acquisition.enableLootTables(default true),acquisition.enableAdvancements(default true),codex.enableDiscoveryHints(default true),reader.allowRunCommandClicks(default false) - New client config options --
codex_display.rememberSearch(default true) andcodex_display.showUnreadMarkers(default true) - Two-layer reload workflow --
/reloadrescans both datapack and config;/rpglore reloadrescans config only and merges with the existing datapack layer - Auto-regenerating config README --
config/rpg_lore/books/_README.txtregenerates when documentation version increments, keeping field docs current without user intervention - Ribbon controls for Codex browsing -- category, filter, and sort are now interactive red ribbon tabs that stick out from the book's top-right edge, each showing its role and current value (e.g. "Category: All", "Filter: Collected", "Sort: Default"); left-click cycles forward, Shift-click cycles backward, and all ribbons remain keyboard-accessible and remembered when returning from a book
- Codex header layout with 8 books per page -- removing the button row reflowed the header so the book list now displays eight entries per page instead of seven
- Codex progress counter removed -- the "x / y" collected-count display at the top of the parchment is removed; only the bottom page counter remains
- Spare-copy indicator simplified -- the duplicate-count display on each row now shows only the copy icon with spare count in tooltip, removing the textual "×n" annotation
- Read action replaced with icon -- the "Read" text link on each Codex entry is replaced by a small open-book icon with tooltip (new translation key
rpg_lore.codex.open_book, added to all 60 locales) - Title truncation with ellipsis -- row titles receive approximately 30 px additional width, and any title that still does not fit is truncated with "..." instead of being clipped mid-glyph
- Textured duplicate-handling icon button -- the spare/duplicate-prevention toggle is now a styled icon drawn from
textures/gui/codex.png(stacked books with a green tick = store spares; single book with a red cross = leave duplicates on the ground) instead of a vanilla button, keeping the same tooltip and behavior - Styled search field with magnifier glyph -- the search input gained a magnifier glyph and thin underline so it reads as an input field on the parchment rather than a plain vanilla box
- Ribbon translation keys for all 60 locales -- three new translation keys
rpg_lore.codex.ribbon.category,rpg_lore.codex.ribbon.filter,rpg_lore.codex.ribbon.sort(format "Category: %s" etc.) are added to all 60 locale files (translated where the locale already translates the Codex controls, English elsewhere); very long category names are automatically trimmed with the full label preserved in the tooltip - Curios slot icon texture -- the "codex" slot's empty-slot icon is a 16x16 greyscale silhouette of the Lore Codex item, following Curios's convention for empty-slot icons;
data/rpg_lore/curios/slots/codex.jsonpointsicontorpg_lore:slot/empty_codex_slot.
This mod has no additional files

