Harry Potter Hacker Code Progress

public class Hacker : MonoBehaviour
{
    //Terminal Hacker Game Theme: Harry Potter!!
    // Easy Level: Break Into The Leaky Cauldron 
    // Easy Words: "Wizard", "Hagrid", "Wand", "Spell", "Magic"

    // Medium Level: Break Into Hogwarts 
    // Medium Words: "Potion", "Hermione", "Quidditch", "Rememberall", "Herbology"

    // Hard Level: Break OUT of Azkaban 
    // Hard Words: "Xenophilius", "Bellatrix", "Dementor", "Basilisk", "Acromantula"

  
    // Start is called before the first frame update
    void Start()
    {
        print("Game Init");
        ShowMainMenu("Welcome to the Wizarding World Hacker");

    }

    void ShowMainMenu (string greeting) {
        Terminal.WriteLine(greeting);
        Terminal.WriteLine("Where in the wizarding world would you like to break into?");
        Terminal.WriteLine("=================/////=================");
        Terminal.WriteLine("Press 1 to head to the Leaky Cauldron!");
        Terminal.WriteLine("Press 2 to head to Hogwarts!");
        Terminal.WriteLine("Press 3 to escape from Azkaban!");
        Terminal.WriteLine("Enter your selection below");
    }

    //OnUserInput is called whenever the user hits return after having typed character(s)
    void OnUserInput(string input)
    {
        print("The user chose " + input); 
        if (input == "1"){
            Terminal.ClearScreen();
            Terminal.WriteLine("Ah, great choice. Time for a pint!");
        } else if (input == "2") {
            Terminal.ClearScreen();
            Terminal.WriteLine("Sounds like you are ready for the school year!");
        } else if (input == "3") {
            Terminal.ClearScreen();
            Terminal.WriteLine("Let's hope the dementors are on break...");
        } else if (input =="9.75"){
            Terminal.ClearScreen();
            Terminal.WriteLine("Uh oh! Looks like Dobby sealed the platform on you!");
            ShowMainMenu("Try another selection Wizard...");
        } else if (input == "menu"){
            Terminal.ClearScreen();
            ShowMainMenu("Welcome to the Wizarding World Hacker");
        } else {
            Terminal.ClearScreen();
            Terminal.WriteLine("Even Alohomora won't work where you are trying to go!");
            ShowMainMenu("Try another selection Wizard...");
        }

    }
     
}

Privacy & Terms