Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mystery Mansion

A text-based murder mystery game where you play as a detective investigating a murder in a mansion. Each playthrough features a randomly selected killer, creating a different mystery to solve every time.

How to Play

  1. Open index.html in a web browser
  2. Read the introduction and click "Begin Investigation"
  3. Explore rooms by clicking navigation buttons
  4. Search objects to find evidence
  5. Talk to suspects - use evidence to unlock new dialogue options
  6. When ready, click "Make Accusation" and choose the killer
  7. Win by correctly identifying the murderer!

Features

  • Randomized killer - Different culprit each playthrough
  • Branching dialogue - Conversations change based on evidence found
  • 3 unique suspects - Each with motive, alibi, and secrets
  • 6 explorable rooms - Search for clues throughout the mansion
  • 9 evidence items - Some implicate the killer, others are red herrings

Running Locally

Simply open index.html in any modern web browser. No server required.

For development with live reload, you can use any static server:

# Python
python -m http.server 8000

# Node.js
npx serve

Project Structure

mystery-mansion/
├── index.html          # Main page
├── css/style.css       # Styling
├── js/
│   ├── main.js         # Entry point
│   ├── state.js        # Game state management
│   ├── data.js         # Data loading
│   ├── engine.js       # Game logic
│   ├── dialogue.js     # Conversation system
│   ├── clues.js        # Clue/killer logic
│   └── ui.js           # DOM rendering
├── data/
│   ├── mansion.json    # Room definitions
│   ├── characters.json # Suspects & dialogue
│   ├── clues.json      # Evidence items
│   └── scenarios.json  # Story configuration
└── README.md

Adding Content

  • New rooms: Edit data/mansion.json
  • New suspects: Edit data/characters.json
  • New clues: Edit data/clues.json

No code changes needed for content additions.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages