diff --git a/public/break_escape/js/minigames/lockpicking/key-operations.js b/public/break_escape/js/minigames/lockpicking/key-operations.js index ea76583..fde408d 100644 --- a/public/break_escape/js/minigames/lockpicking/key-operations.js +++ b/public/break_escape/js/minigames/lockpicking/key-operations.js @@ -244,8 +244,8 @@ export class KeyOperations { // This is the locksmith-forge.html challenge mode this.parent.keySelection.createKeysForChallenge('correct_key'); } else { - // This is the main game - go back to key selection - this.parent.startWithKeySelection(); + // This is the main game - go back to key selection with original inventory keys + this.parent.startWithKeySelection(this.parent.originalInventoryKeys, this.parent.originalCorrectKeyId); } } }, 2000); // Longer delay to show the red flash diff --git a/public/break_escape/js/minigames/lockpicking/lockpicking-game-phaser.js b/public/break_escape/js/minigames/lockpicking/lockpicking-game-phaser.js index d19dc7d..f56b708 100644 --- a/public/break_escape/js/minigames/lockpicking/lockpicking-game-phaser.js +++ b/public/break_escape/js/minigames/lockpicking/lockpicking-game-phaser.js @@ -469,7 +469,10 @@ export class LockpickingMinigamePhaser extends MinigameScene { this.keySelectionMode = true; // Mark that we're in key selection mode + // Store the original inventory keys and correct key ID for use when retrying after wrong selection if (inventoryKeys && inventoryKeys.length > 0) { + this.originalInventoryKeys = inventoryKeys; + this.originalCorrectKeyId = correctKeyId; // Use provided inventory keys this.keySelection.createKeysFromInventory(inventoryKeys, correctKeyId); } else {