It wasn’t too bad overall, though I did run into a few hiccups.
-Early on a misplaced curly bracket invalidated a bunch of my code. It took a minute to sort where it missing. Caused by a bad keystroke in VS. I probably could have “undone” it, but I don’t think I noticed it immediately.
-I wasn’t happy with my output originally. On each password guess it would print as follows.
password input
Enter your password:
Incorrect Password/Congrats (depending on correct guess or not)
I had to think about where the Term.WriteLines were and just move them a bit.
-Lastly, the code is just kind of a mess and cumbersome atm. I think I’ll sit with it for now though. Spending too much time on it to have it unravel in a few more lessons seems moot. Excited to personalize a bit closer to the end though.
Pasted a portion of what I’ve got below. It’s part of the OnUserInput if statement. Duplicated code for level 2 and 3 with the obvious required changes.
else if (currentScreen == Screen.Password && level == 1)
{
if (input == easyPW)
Terminal.WriteLine("Congratulations!");
else if (input == "menu" || input == "Menu")
{
showMainMenu();
}
else
Terminal.WriteLine("Incorrect Password.\n" +
"Enter your password: ");
}