Roguecraft Cards

A second, blue XP bar: every blue level, pick 1 of 3 roguelike cards that upgrade your character. Also a library for add-ons.
cards-rare.jpg

cards-rare.jpg

cards-reroll.jpg

cards-reroll.jpg

cards-luck.jpg

cards-luck.jpg

zombies.jpg

zombies.jpg

levelup.jpg

levelup.jpg

Description

Roguecraft Cards

A second, blue XP bar. Every blue level, pick 1 of 3 roguelike cards that upgrade your character.

Also an API. Other mods can add their own cards and card types, give blue XP and listen to card events. See For mod developers below.

▶ Watch the trailer on YouTube

How it works

Kill, mine, fight. Fill the blue bar. Pick 1 of 3 cards.

  • Every time vanilla XP drops (mobs, ores, furnaces, fishing, trading, breeding), blue XP orbs drop too.
  • Blue XP fills a thin blue bar above your normal XP bar. It levels up slower than vanilla XP.
  • Each blue level gives you a card choice: press K and pick 1 of 3 cards.
  • A pick trail at the bottom of the card screen shows every card you chose, in order.

Picking a card

Cards

The 5 rarities

Cards come in 5 rarities: Common (copper), Uncommon (iron), Rare (gold), Epic (diamond) and Legendary (netherite). Higher rarities give bigger bonuses.

Luck decides rarity. With no luck you only see Commons; Uncommon unlocks at luck 1, Rare at 3, Epic at 6 and Legendary at 10. At luck 50: 9.5% Common, 47% Uncommon, 23% Rare, 13% Epic, 7.8% Legendary. Bad-luck protection guarantees something better after a streak of Commons.

24 cards

Type Cards
Attributes (from level 1) Vitality, Strength, Toughness, Agility, Luck, Wisdom (more blue XP), Mining
Combat Thorns, Critical, Vampirism, Execution, Storm, Blood Pact
Survival Feather Fall, Satiety, Regeneration, Second Chance
Exploration Magnet, Mole (night vision underground), Prospector (double ore drops)
Cards Reroll, Harvest, Banish, Full Hand (4 cards per offer)

Abilities unlock gradually from blue level 5 to 60, so early offers stay simple. Every card has a pick limit and a cap.

Items

Four-Leaf Clover and Luck Charms

  • Four-Leaf Clover: rare drop from grass; the chance grows with your luck.
  • Luck Charms (iron +1, gold +2, diamond +3, netherite +5 luck): go in the Curios charm slot and also raise the luck limit of card rarity rolls.

Configuration

Server/world (roguecards-server.toml, also in the in-game mod config screen): blue XP ratio, XP cost per level, level cap (off by default), cards per offer, disabled cards, hardcore mode (lose everything on death), rarity luck thresholds, bad-luck protection, Four-Leaf Clover chances and more.

Player (roguecards-client.toml): show/hide the blue bar and the "Card! [K]" hint.

Add-ons

Roguecraft Cards: Cobblemon

Roguecraft Cards: Lockers

Made an add-on? Tell me in the comments and I'll list it here.

For mod developers

Build on Roguecraft Cards

Roguecraft Cards is also a library. Any mod can use its public API (package com.roguecards.api) to:

  • Add cards: register a CardType in the card registry, with values for each rarity, a pick limit, a cap and an icon.
  • Add card types: CardType.Category.register(id, color) creates a new type, like the Pokémon type of the Cobblemon add-on.
  • Give blue XP from your own actions: RoguecraftApi.giveBlueXp(player, amount, source).
  • Read a player's progress: RoguecraftApi.level(player), bonus(player, card) and picks(player, card).
  • Add luck to the rarity roll: RoguecraftApi.addRarityLuckSource(player -> ...).
  • Listen to events on NeoForge.EVENT_BUS: BlueXpGainEvent (cancellable), BlueLevelUpEvent, CardOfferEvent and CardChosenEvent.

Add it to your project with CurseMaven:

repositories {
    maven { url = "https://cursemaven.com" }
}
dependencies {
    implementation "curse.maven:roguecraft-cards-1825845:9771226"
}

Register a card:

public static final DeferredRegister<CardType> CARDS =
        DeferredRegister.create(RoguecraftApi.CARD_REGISTRY_KEY, MODID);

public static final DeferredHolder<CardType, CardType> SWIFT_STRIKE = CARDS.register("swift_strike",
        () -> CardType.builder()
                .category(CardType.Category.COMBAT)
                .minLevel(15)                           // first blue level it can appear
                .values(0.05, 0.08, 0.12, 0.18, 0.25)   // Common -> Legendary
                .limit(5).cap(0.5)
                .format(CardType.Format.PERCENT)
                .icon(() -> Items.GOLDEN_SWORD)
                .build());

// in your mod constructor: CARDS.register(modBus);
// your effect: double bonus = RoguecraftApi.bonus(player, SWIFT_STRIKE.get());

Card names come from your lang file: card.<modid>.<card> and card.<modid>.<card>.desc.

See the Cobblemon add-on for a full example. The API is LGPL-3.0, so add-ons can use any license.

Requirements

  • Minecraft 1.21.1, NeoForge
  • Curios API

This is a beta: numbers may change between versions. Feedback is welcome!


Em português

Uma segunda barra de XP, azul. A cada nível azul, você escolhe 1 entre 3 cartas (estilo roguelike) que melhoram o seu personagem: atributos, combate, sobrevivência e exploração. A raridade das cartas depende da sua sorte. Aperte K para abrir as cartas. Requer NeoForge 1.21.1 e Curios API.

License: LGPL-3.0-or-later.

Roguecraft Cards Team

profile avatar
  • 2
    Projects
  • 10
    Downloads

More from ShadowsCrow1122