Let Sokko TCG players level up cards for Expeditions with Éclats or duplicates

- Each owned rare or better edition keeps a level and field experience; a level costs Éclats by current power, so every rarity reaches the same cap and a rare pays the longer road.
- A duplicate of the same edition gives a whole level; every claimed expedition grants field experience to the cards it sent.
- A one-way bridge turns stardust into Éclats at an admin-tuned rate.
- The card sheet shows level, power, stats and experience with upgrade buttons; expeditions use the upgraded power.
- Administration › Guilde tunes the cost formula, duplicate levels, field experience and the bridge rate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Shinuwa 2026-11-15 14:52:44 +01:00
parent 6b7605d04e
commit e0ffccd1c8
22 changed files with 373 additions and 10 deletions

View file

@ -18,7 +18,10 @@ const EVENT_LABELS = {
opening_purchased: "Ouverture achetée",
daily_won: "Carte du jour trouvée",
expedition_completed: "Expédition terminée",
expedition_cancelled_by_guild: "Expédition annulée par la Guilde"
expedition_cancelled_by_guild: "Expédition annulée par la Guilde",
expedition_dissolved: "Groupe d’expédition dissous",
card_upgraded: "Carte améliorée",
eclats_converted: "Éclats d’étoile obtenus"
};
// Le journal garde la quantité réellement offerte : les comptes plus anciens n'ont reçu qu'une ouverture.
@ -60,6 +63,9 @@ function HistoryDetail({ entry, catalog }) {
return <span>{[`${details.destinationName} · ${"★".repeat(details.difficulty)} · ${details.hours} h`, tier, ...gains].filter(Boolean).join(" · ")}</span>;
}
if (entry.type === "expedition_cancelled_by_guild") return <span>{details.destinationName} · cartes libérées, sans butin</span>;
if (entry.type === "expedition_dissolved") return <span>{details.destinationName} · {details.reason === "creator_left" ? "dissous par son créateur" : "pas assez de joueurs"} · cartes libérées</span>;
if (entry.type === "card_upgraded") return <span>{[cardReference(entry.entityId, catalog), `niveau ${details.level}`, `Puissance ${details.power}`, details.method === "duplicate" ? "un doublon utilisé" : `−${details.eclats} Éclats`].join(" · ")}</span>;
if (entry.type === "eclats_converted") return <span>+{details.eclats} Éclats · −{formatStardust(details.stardust)} d’étoiles</span>;
if (entry.type === "opening_purchased") return <span>−{formatStardust(details.price)} d’étoiles</span>;
if (!details.collectionId) return null;
const name = catalog.collections.find((item) => item.id === details.collectionId)?.name;