← all kitsgenre kit

deckbuilder

cards, intents, drafting

Card battler with runs (Slay-the-Spire-like): cards in a compact effect language, energy + draw/discard/exhaust piles, enemies with intent patterns, statuses, relics, procgen act maps (fights/elites/events/shops/rest/treasure/boss), rewards, upgrades/removal, multiple characters, meta unlocks, a greedy bot + balance sim, and a portrait UI that runs the whole loop. Requires core, progression, juice, combat (turn damage formula), procgen (rng, encounter budgets). Example: games/examples/kit-deckbuilder.

Setup

kits = ["deckbuilder"]       # core/progression/juice/combat/procgen come with it
-- scripts/client/main.luau (attached to the entry scene root)
local Core = require("@kit/core")
local DB = require("@kit/deckbuilder")
Core.setup({ save = { key = "mygame", version = 1 } })   -- core save slot also stores the run (section "deckbuilder")
DB.setup()                                              -- reads data/cards|enemies|relics|characters|events|acts + data/deckbuilder.json
DB.ui.play({ title = "My Game", subtitle = "...", logo = "asset:logo", background = "asset:bg", heroSprite = "asset:hero",
  nodeIcons = { fight = "asset:nd_fight", elite = …, rest = …, shop = …, event = …, treasure = …, boss = … },
  intentIcons = { attack = "asset:in_attack", defend = …, buff = …, debuff = …, attack_defend = …, attack_debuff = …, attack_buff = …, unknown = … },
  music = { title = "map", map = "map", battle = "battle", boss = "boss" }, restArt = "asset:fire", restTitle = "Campfire", shopTitle = "Shop",
  character = nil (first character / title picks), locked = false (true: respect meta unlocks) })

DB.setup({ content = { cards = {...}, enemies = …, relics = …, characters = …, events = …, acts = …, config = … } }) takes the same data as a table (lists or id maps). Unknown refs (deck cards, pattern moves, act enemies/events) are errors listing every problem (config.strict = false to relax). Without icons the UI falls back to glyphs/letters. All sfx are optional (juice.sfx): card hit hurt block buy win lose select heal power deny.

Example game

Lanternfall running on the Dreamsy engine

Lanternfall

Keep the last lamps burning: draft cards, read enemy intents, ring the Drowned Bell.

deckbuilderflat

Full reference on GitHub