Assignment #45 Choose Your Own Adventure

Code

    /// Name: DeeJay Cerezo
/// Period: 7
/// Program Name: Choose Your Own Adventure
/// File Name: Adventure.java
/// Date Finished: 11/30/2015
 

import java.util.Scanner;

class Adventure
{
      public static void main(String[] args) 
      {
          
          Scanner keyboard = new Scanner(System.in);
          
          String room1, room2, room3;
        room1 = room2 = room3 = "room";
        System.out.println( "Welcome to Lan-kun's spoopy adventure." );
        System.out.println();
        System.out.println( "You've found yourself in your girlfriend's house for the first time. You're very nervous and can feel the moisture of your sweat on your palms. 'Wait here, ok?', she says as she stands up from the table. 'I'm going to get something really quick'. You watch the flow of her hair as it disappears past the doorway. ... It's been at least 15 minutes since she left and you need to use the bathroom. Will you [wait] or get up and [search] for the bathroom?");
                           System.out.print( "> " );
        room1 = keyboard.nextLine();
        
        if ( room1.equals("wait") )
            {
                System.out.println( "You think you can hold it in and decide to wait a little bit longer. ... 5 more minutes pass and you begin to think something is wrong. Will you continue to [wait] or [look] for her? You're need to use the bathroom is still very evident." );
                System.out.print( "> " );
                room2 = keyboard.nextLine();
                    if ( room2.equals("wait") )
                    {
                    System.out.println( "You tap your foot in an effort to contain your bladder. Will you [wait] or [look] for your girlfriend and the bathroom? " );
                    System.out.print("> ");
                    room3 = keyboard.nextLine();
                        if ( room3.equals("wait") )
                        {
                        System.out.println("You're bladder explodes and your stood there, sopping wet and helpless. You're girlfriend appears in the doorway. 'Sorry, I was-', she cuts off with a disgusted look on her face. Unable to say and thing you find yourself standing outside of her house, still soaking, and wondering where it all went wrong. [Worse-then-death End]" );
                        }
                        else if ( room3.equals("look") )
                        {
                        System.out.println("You can't wait any longer. You spring from your chair and take a left turn into the hall at mach speeds. While you turn your head to peek into a room to look for a toilet, you suddenly crash into your girlfriend and in your panic your bladder explodes and you soak both yourself and your girlfriend. The newly waxed floor combined with the product of your bladder results in zero traction and you slide 15 feet down the hall and you both crash into the wall. You're knocked out, on the floor, covered and in fluid. [Worse-than-death End ");
                        }
                    }
                    else if ( room2.equals("look") )
                    {
                    System.out.println( "You decide you can't wait any longer. You get up and look for the bathroom. While searching, you see your girlfriend in one of the rooms, covered in blood and holding a knife. You don't have a good enough view but you think there are bodies on the ground. Do you [call] out to her or [nope] the hell out of there. " );
                    System.out.print( "> " );
                    room3 = keyboard.nextLine();
                        if ( room3.equals("call") )
                        {
                        System.out.println( "You call out to her. She cranes her head slowly and says,'I'm sorry.. you weren't supposed to see this. Let's revert and try again' She lunges and you now have a knife in your chest. Youre vision blurs and you collapse to the floor.[Bad End]" );
                        }
                        else if ( room3.equals("nope") )
                        {
                        System.out.println("You gtfo real fast. You lock yourself in your room and stare at your phone which is constantly buzzing from messages from her. You ignore it. [Good End]");
                        }
                    } 
                }
        else if ( room1.equals("search") )
            {
            System.out.println( "You get up and search for the bathroom. There are two directions to go. Will you go [left] or [right]?" );
            System.out.print( "> " );
            room2 = keyboard.nextLine();
                if ( room2.equals("left") )
                {
                System.out.println( "You see the bathroom down the hall. You notice a door on your left that's slightly open. It's pitch black and you sense an ominous atmosphere." );
                System.out.println( "Will you [peek] inside or [go] to the bathroom?" );
                System.out.print( "> " );
                room3 = keyboard.nextLine();
                    if ( room3.equals("peek") )
                    {
                    System.out.println( "You let your curiousity get the better of you. As you approach the door you smell something wretched. You crack the door open further and the room is still dim but just bright enough to make out what you see. The walls and floor are splattered with a black fluid. There are what look like people slumped on the floor. You hear the floor creak behind you and you turn to see your girlfiend standing before you. 'I'm sorry. Your weren't supposed to see this. We were supposed to be happy. Let's reset and try again' She moves toward you fast and your vision starts to blur. [Bad End] " );
                    }
                    else if ( room3.equals("go") )
                    {
                    System.out.println( "You go to the bathroom and relieve yourself. You head back and your girlfriend's back in the living room. She smiles gently. The rest of the day goes without incident [Good End]" );
                    }
                }
                else if ( room2.equals("right") )
                {
                System.out.println( "You go right. The bathroom is nowhere to be found but you see a plastic bottle in the middle the hall." );
                System.out.println( "Will you do it? Will you [pee] in a bottle like a disgusting animal or just continue [search]ing? " );
                System.out.print( "> " );
                room3 = keyboard.nextLine();
                    if ( room3.equals("pee") )
                    {
                    System.out.println( "You pee in a bottle. You animal. The rest of the day goes without incident. [Somewhat Good End]" );
                    }
                    else if ( room3.equals("search") )
                    {
                    System.out.println( "Like an Ikea department store you search for hours to no avail. You get lost and are condemned to endless searching and die a lonely death [Bad End]." );
                    }   
                }
            }
    }
}

 
    

Picture of the output

Assignment 45