Update product definitions and revenue calculations in Falukant: Adjust product sell costs and production times for better balance. Refactor revenue calculations to focus on profit per minute instead of revenue per minute. Enhance localization files to include new terms related to product unlocks and certificate levels in English, German, and Spanish, improving user experience across languages.

This commit is contained in:
Torsten Schulz (local)
2026-03-26 20:19:49 +01:00
parent 01849c8ffe
commit e0c3b472db
10 changed files with 303 additions and 43 deletions

View File

@@ -187,6 +187,21 @@
</li>
</ul>
</article>
<article class="certificate-panel__block">
<h4>{{ $t('falukant.overview.certificate.levelMatrix') }}</h4>
<div class="certificate-level-list">
<div
v-for="entry in certificateLevelMatrix"
:key="entry.level"
class="certificate-level-list__item"
:class="{ 'is-current': entry.level === (falukantUser?.certificate ?? 1) }"
>
<strong>{{ $t('falukant.overview.certificate.levelLabel', { level: entry.level }) }}</strong>
<span>{{ entry.products.join(', ') }}</span>
</div>
</div>
</article>
</div>
</section>
@@ -338,6 +353,14 @@ const AVATAR_POSITIONS = {
},
};
const CERTIFICATE_PRODUCT_LEVELS = [
{ level: 1, products: ['fish', 'meat', 'leather', 'wood', 'stone', 'milk', 'cheese', 'bread', 'wheat', 'grain', 'carrot'] },
{ level: 2, products: ['beer', 'iron', 'copper', 'spices', 'salt', 'sugar', 'vinegar', 'cotton', 'wine'] },
{ level: 3, products: ['gold', 'diamond', 'furniture', 'clothing'] },
{ level: 4, products: ['jewelry', 'painting', 'book', 'weapon', 'armor', 'shield'] },
{ level: 5, products: ['horse', 'ox'] },
];
export default {
name: 'FalukantOverviewView',
components: {
@@ -409,6 +432,12 @@ export default {
certificateProgress() {
return this.falukantUser?.certificateProgress || null;
},
certificateLevelMatrix() {
return CERTIFICATE_PRODUCT_LEVELS.map((entry) => ({
level: entry.level,
products: entry.products.map((productKey) => this.$t(`falukant.product.${productKey}`)),
}));
},
routineActions() {
return [
{
@@ -851,6 +880,32 @@ export default {
font-weight: 600;
}
.certificate-level-list {
display: grid;
gap: 10px;
}
.certificate-level-list__item {
display: grid;
gap: 6px;
padding: 12px 14px;
border-radius: var(--radius-md);
background: rgba(138, 84, 17, 0.06);
}
.certificate-level-list__item strong {
color: #7a4b12;
}
.certificate-level-list__item span {
color: var(--color-text-secondary);
}
.certificate-level-list__item.is-current {
background: rgba(68, 138, 86, 0.12);
box-shadow: inset 0 0 0 1px rgba(68, 138, 86, 0.22);
}
.summary-card,
.routine-card {
padding: 18px;