Session 12: Save Slot System (3 slots, autosave toggle, cross-slot import/export) + fix goldenBlooms field missing from reset()/switchSlot empty-state
This commit is contained in:
+24
@@ -75,6 +75,16 @@ const Stats = {
|
||||
<div class="stat-bar-fill" id="stat-progress-bar" style="width: 0%"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Save Slot System -->
|
||||
<div class="stat-item">
|
||||
<div class="stat-label">Active Save Slot</div>
|
||||
<div class="stat-value" id="stat-active-slot">Slot 1 / ${Game.config.SLOTS}</div>
|
||||
</div>
|
||||
<div class="stat-item">
|
||||
<div class="stat-label">Autosave</div>
|
||||
<div class="stat-value" id="stat-autosave">ON</div>
|
||||
</div>
|
||||
`;
|
||||
},
|
||||
|
||||
@@ -132,6 +142,20 @@ const Stats = {
|
||||
achievementsEl.textContent = `${Achievements.getCount()}/${Achievements.getTotal()}`;
|
||||
}
|
||||
|
||||
// Active save slot display
|
||||
const activeSlotEl = document.getElementById('stat-active-slot');
|
||||
if (activeSlotEl) {
|
||||
const idx = Game.state.activeSlot || 0;
|
||||
activeSlotEl.textContent = `Slot ${idx + 1} / ${Game.config.SLOTS}`;
|
||||
}
|
||||
|
||||
// Autosave status display
|
||||
const autosaveEl = document.getElementById('stat-autosave');
|
||||
if (autosaveEl) {
|
||||
autosaveEl.textContent = Game.state.autoSave ? 'ON' : 'OFF';
|
||||
autosaveEl.style.color = Game.state.autoSave ? 'var(--accent-green)' : 'var(--text-muted)';
|
||||
}
|
||||
|
||||
// Total Golden Blooms claimed
|
||||
const goldenBloomsEl = document.getElementById('stat-golden-blooms');
|
||||
if (goldenBloomsEl) {
|
||||
|
||||
Reference in New Issue
Block a user