Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Links
Tags
Creators
Details
๐งฑ C-erva Core
Shared utility library for C-erva Fabric mods.
C-erva Core provides a set of common building blocks โ text formatting, registration helpers, networking, inventory utilities, permissions, and more โ so that individual mods stay small and don't reinvent the wheel.
You don't use this mod directly. Install it as a dependency when another mod (e.g. PhotoChat) requires it.
๐ฆ What's inside
๐ฌ CervaText
Prefixed chat messages with consistent styling.
CervaText.success("MyMod", "Item given!"); // [MyMod] Item given! (green)
CervaText.warning("MyMod", "Low durability"); // [MyMod] Low durability (yellow)
CervaText.error("MyMod", "Not found"); // [MyMod] Not found (red)
๐ท๏ธ CervaRegistry
One-liner registration for identifiers, items, blocks, sounds, and entity types.
CervaRegistry.id("mymod", "ruby");
CervaRegistry.item("mymod", "ruby", new Item(settings));
CervaRegistry.sound("mymod", "ding");
๐ CervaNetworking
Broadcast a custom payload to all players who have the mod, with an automatic text fallback for everyone else.
CervaNetworking.broadcastWithFallback(server, TYPE, payload, fallbackText);
๐ CervaItems
Inventory helpers โ give items, drop stacks, count slots, check for space.
CervaItems.give(player, stack); // give or drop if full
CervaItems.hasSpace(player, stack); // check before giving
CervaItems.countItem(player, Items.DIAMOND);
๐ CervaPermissions
Simple permission checks for commands and players.
CervaPermissions.hasPermission(source, permission);
๐ CervaWorld
World and sound utilities.
CervaWorld.playSound(world, pos, soundEvent);
CervaWorld.isServerWorld(world);
โฑ๏ธ CervaCooldowns
UUID + key based cooldown map with automatic expiry.
if (CervaCooldowns.isReady(player.getUuid(), "ability", 60)) {
// 60-tick cooldown passed
}
๐ผ๏ธ CervaTooltips (client)
Tooltip builder for item descriptions.
CervaTooltips.builder()
.line("Rare artifact", Formatting.GOLD)
.line("+5 attack", Formatting.GREEN)
.build(tooltip);
๐ CervaPaths
Path parsing with quote and space support โ useful for commands that accept file paths.
๐ CervaFilePicker (client)
Native OS file dialog via TinyFD โ open/save dialogs with format filters.
๐ก๏ธ CervaSafe
Quick checks for client/server side, null world, null player โ guards against common crashes.
๐ Requirements
- Minecraft 1.21.11
- Fabric Loader โฅ 0.19.3
- Fabric API
- Java 21+
โ๏ธ For mod developers
Add C-erva Core as a dependency in your build.gradle:
modImplementation "com.andrewimm:cerva_core:1.2.91"
And in your fabric.mod.json:
"depends": {
"cerva_core": ">=1.2.91"
}
๐ Mods using C-erva Core
- PhotoChat โ send images directly into Minecraft chat


