# oop-text-adventure --- HAUNTED MANSION PROJECT ---
Written by:
A. GAME DESCRIPTION
The objective of the game is to escape from a haunted mansion. The player will need
to find and use items, navigate the mansion, and encounter and fight enemies. The
game ends when the player is either defeated (bad ending) or successfully escapes
(good ending).
This single-player game is called Mansion Escape and is structured as a text adventure
that incorporates various topics we have learned in OOP. The objective of the game is
to escape a haunted mansion by moving from room to room in search of the next open door
and any useful items that may help the player escape or fight off the monsters that
may lurk within. The player begins in the lobby, moves through the bar, the kitchen,
the hallway, the master bedroom, and the bathroom until they reach the outside.
Through each room, the user is presented with a puzzle or task, and the various rooms
may be locked, so the user must use the textual clues to discover where they can go
next and what they should do.
At the conclusion of the game, the user must defeat the final enemy to make it to
their car, which can only be accessed if the player had picked up their car keys in
one of the previous rooms. There are different endings depending on player actions,
so it is essentially a short and simple “Choose your own adventure” game. The game
serves as a mix between storytelling and problem solving although it lacks an actual
UI or graphics in the text adventure spirit, so it would be more entertaining to
players who are fans of the genre or are highly imaginative and love reading and logic
puzzles!
B. HOW TO PLAY
Enter Y to begin a game or N to quit the game. The game will then prompt the player for
his or her name. Once the game begins, you can type 'help' for a list of commands. Using
'go' *must* be followed by a direction (north, south, east, west). 'Take' does not need
the item listed after. Other commands include 'drink', 'heal', 'attack', 'look around',
'view inventory', and 'view health'.
C. CHEAT SHEET
How to win:
1. Go east
2. Take (flashlight and bottle)
3. Go west
4. take (car keys)
5. go east
6. go east
7. attack
8. take (hallway keys)
9. go west
10. go west
11. go west
12. answer puzzle: white
13. take (pipe)
14. Go north
15. attack (may need to use this command multiple times)
16. Go north
D. SECRET COMMAND
In the last room, there is a secret command that automatically defeats the last enemy if
you don't want to deal with fighting it. This command is 'skip'.
E. SOURCE CODE
The source code for this project can be found at https://github.com/soltk/oop-text-adventure