- Three major control structures exist. Input validation, win/lose conditions, and engine feeback.
- Repetitive actions such as user input and input evaluation will be broken down into functions.
- The program checks if "leaderboard.txt" exists. If it does, the program proceeds. If not, the file is generated with empty data.
- The player inputs their name to track their score.
- The program generates a random code to be broken by the player.
- The player inputs their guess.
- Checks will be made to verify clean input data. This will prevent runtime errors and penalize the player by making them take longer to break the code.
- If the data is clean, the input is evaluated.
- If the win condition is met, the player is scored and the game ends.
- If the win condition is not met, the lose condition is checked.
- If the lose condition is met, the player is scored and the game ends.
- If the lose condition is not met, feedback is provided to player.
- Return to step 1.
- Project complete.