Inspiration

I wanted to build something that is fun and interactive instead of creating a regular chatbot. I like mystery games, so I thought it would be interesting to build a detective game where players can ask their own questions and get different answers from AI. This project shows how AI can make games feel more realistic and engaging.

What it does

AI Detective: The Missing Aurora Diamond is a detective game where the player investigates the theft of a valuable diamond. The player interviews three suspects, collects clues, and decides who stole the diamond. Each suspect responds using Google's Gemini AI, so the conversations feel natural instead of following fixed dialogue. As important information is discovered, clues are added to the evidence board, helping the player solve the mystery.

How we built it

I built the frontend using React and Vite to create a clean and responsive interface. The backend is built with Node.js and Express. I integrated the Google Gemini API to generate intelligent responses for each suspect while keeping them in character. I also created an evidence board that automatically collects important clues and an accusation screen where the player can make the final decision.

Challenges we ran into

One of the biggest challenges was making the AI stay in character throughout the conversation. I also had to make sure the clues appeared at the right time without making the mystery too easy or too difficult. Another challenge was dealing with Gemini API quota limits during development, so I added fallback responses to make sure the game could still be demonstrated.

Accomplishments that we're proud of

I am proud that I was able to build a complete detective game within the hackathon timeframe. The AI conversations feel natural, the investigation has a clear flow, and players solve the mystery by collecting evidence instead of simply guessing. I am also happy with the overall user experience, including the case briefing, evidence board, and final accusation screen.

What we learned

This project helped me learn how to build an AI-powered interactive application instead of a simple chatbot. I learned how to write better prompts for Gemini, manage conversation history, connect a React frontend with an Express backend, and design a game where AI plays a meaningful role in the player's experience.

What's next for AI Detective: The Missing Aurora Diamond

I would like to expand the game by adding multiple mystery cases, more suspects, hidden evidence, and different endings. I also want the guilty suspect to change every time a new game starts so each playthrough feels unique. In the future, like to add voice conversations, difficulty levels, and multiplayer detective challenges to make the experience even more immersive.

Share this project:

Updates