Remnant: OPC
A Minecraft library for Fabric and NeoForge that keeps registered player data accessible while players are offline.
介绍

Remnant
Remnant lets mods read registered player data after a player logs out. It is a server-side library for Minecraft 1.21.1 on Fabric and NeoForge, continuing Offline Player Cache (OPC).
An integrating mod registers a value, a Mojang Codec, and a serializer for reading that value from a live player. On disconnect, Remnant snapshots every registered value into world SavedData. When the player comes back, the stale offline snapshot is removed and reads return to the live player.
Use it for leaderboards, statistics, progression, and server tools that need player data while someone is offline. Remnant stores the values registered by integrating mods.
Requirements
- Fabric 1.21.1 — requires Fabric API and Fabric Language Kotlin
- NeoForge 1.21.1 — requires Kotlin for Forge
- Java 21
Install the JAR for your loader. Remnant does not add player-facing features on its own; other mods use its API.
Commands
All commands require permission level 2.
/remnant keys
/remnant players
/remnant get name <name> <key>
/remnant get uuid <uuid> <key>
/remnant list name <name>
/remnant list uuid <uuid>
/remnant remove name <name> <key>
/remnant remove uuid <uuid> <key>
/remnant clear name <name>
/remnant clear uuid <uuid>
get and list can inspect either a live player or an offline snapshot. remove and clear only modify offline cache data.
For developers
A registered value is identified by a ResourceLocation, serialized with a Mojang Codec, and produced from a live Player.
public static final PlayerLedgerKey<Contract> CONTRACT = PlayerLedger.register(
ResourceLocation.fromNamespaceAndPath("example", "contract"),
Contract.CODEC,
player -> new Contract(player.getName().getString(), true)
);
Read through PlayerLedger.getPlayer(...) to get either a live LedgerPlayer.Online or a cached LedgerPlayer.Offline.
For Modrinth Maven, use the project ID so the coordinate stays stable if the public slug changes:
repositories {
exclusiveContent {
forRepository {
maven("https://api.modrinth.com/maven")
}
filter {
includeGroup("maven.modrinth")
}
}
}
dependencies {
implementation("maven.modrinth:oLPaySSb:<version>")
}
Full API examples, source, development notes, and release history are available on the main GitHub repository.
Links
Sponsor
Use code bareminimum to get 25% off your first month.
License
Remnant is licensed under the Bare Minimum License (BML) v1.0. See the full license.
常见问题
Remnant: OPC 支持哪些 Minecraft 版本?
Remnant: OPC 支持 Minecraft Java 版 1.20.1–1.21.1,共 3 个版本,可用的加载器:Fabric / Forge / NeoForge / Quilt。下载时注意选择和你游戏版本一致的文件。
Remnant: OPC 怎么安装?
先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric / Forge / NeoForge / Quilt,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。
bibireden 的其他作品
查看全部 →Data Attributes: DC
一套灵活的 Minecraft 属性框架。通过数据包和服务器实时设置配置属性上下限、关联属性,并自定义实体基础属性值。
Data Attributes
通过可配置的上下限、属性函数、实体基础值、数据包支持和实时配置,自定义 Minecraft 属性。支持 Fabric 和 NeoForge。
PlayerEX
为游戏加入RPG成长体系,包含角色等级、属性、法术学派和装备升级。内置WizardEx与RelicEx功能、遗物战利品,并为Fabric和NeoForge重新设计了角色界面。
PlayerEx: DC
加入 RPG 式成长系统,包含角色等级、属性、法术学派和装备升级。内置 WizardEx 与 RelicEx 功能、遗物战利品,并为 Fabric 和 NeoForge 重新设计了角色界面。

评论
登录后评论和评分