Mahjong Titans

Seele01-Flash
By
Mahjong Titans is the iconic classic tile-matching puzzle game featuring traditional Chinese Mahjong tiles. Match pairs to clear all 144 tiles from the board in this timeless solitaire challenge.

Prompt

MODEL: Seele01-Flash
Please use Three.js to generate a **mobile-first game** with the theme "Mahjong Titans". Please read the following detailed game design requirements first, and then generate the code accordingly: ### 1. Assets & Environment * **Visual Style**: Realistic, high-fidelity 3D aesthetic. The tiles should look like polished ivory or bone with a green or bamboo backing. The symbols (characters, dots, bamboo) should be crisp vector-style textures applied to the top face. * **Environment**: A calm, dark grey or deep blue background with a subtle, static traditional pattern (like waves or clouds) to provide high contrast against the white tiles. * **3D Models**: Create the Mahjong tiles using `THREE.BoxGeometry` with slight beveling to catch light. * **Performance Optimization (Mobile)**: **Crucial:** Use `THREE.InstancedMesh` to render the 144 tiles to minimize draw calls. Use a shared material with a texture atlas for the different face symbols to keep texture lookups efficient. * **Lighting**: Use a Directional Light to cast soft shadows (helps the player visualize depth and stack height) and an Ambient Light for general visibility. ### 2. Audio Requirements * **BGM**: A relaxing, "Zen" style track featuring traditional Chinese instruments (like the Guzheng or Pipa). It should be loopable and non-intrusive. * **SFX - Selection**: A sharp, distinct "click" sound (like a stone hitting stone) when a tile is tapped. * **SFX - Match/Remove**: A satisfying "clatter" or sliding sound when two tiles are successfully paired and removed. * **SFX - Error**: A dull "thud" or wooden sound if the player taps a blocked tile. * **SFX - Win**: A celebratory chime or gong sound upon clearing the board. ### 3. Gameplay Loop * **Core Mechanic**: Classic Mahjong Solitaire (Shanghai) rules. * **Level Layout**: Initialize the board in the classic "Turtle" pyramid formation (144 tiles stacked in specific layers). * **Selection Logic**: A tile is selectable ONLY if: 1. It has no tile directly on top of it (Z-axis check). 2. It has an open space on either its left OR right side (X-axis check). * **Matching Logic**: Players select two identical tiles (e.g., Two of Bamboo) to remove them. **Exceptions**: The 4 "Season" tiles match each other, and the 4 "Flower" tiles match each other, regardless of the specific picture. * **Win Condition**: The game ends when all 144 tiles are removed. * **Game Over/Shuffle**: Include a check for "No Moves Left". If no moves remain, offer a "Shuffle" button or auto-shuffle. ### 4. Mobile Controls & Interaction * **Camera & View**: Use a Perspective Camera positioned at a roughly 60-degree angle. * **Touch Controls**: * **Tap**: Use `THREE.Raycaster` for tile selection. Tapping a tile should highlight it (e.g., lift it slightly on the Y-axis or add an emission glow). * **Pinch & Pan**: Implement `OrbitControls` but restrict rotation (azimuth/polar angles) to prevent the user from getting lost. Allow zooming in/out and panning to help users with smaller screens see details. * **Haptic Feedback**: Trigger a short vibration (`navigator.vibrate(50)`) when a valid tile is selected or matched. * **UI Layout**: * Place UI buttons (Restart, Shuffle, Hint) at the bottom corners of the screen. * Ensure buttons have a minimum touch target of 44x44 pixels. * Display a simple "Pairs Remaining" counter at the top center. * **Orientation**: The game should be responsive, but optimize the initial camera zoom for **Landscape Mode** as the Turtle layout is wide. Do not ask for clarification. Do not request confirmation. Directly execute the generation task based on the given instructions.

Game Introduction

About the Game

Mahjong Titans is one of the most beloved classic puzzle games, offering players an authentic traditional Mahjong Solitaire experience. This iconic tile-matching game challenges you to systematically remove all 144 tiles from a carefully arranged pyramid structure by finding and matching identical pairs.

The game features stunning traditional Chinese tile designs, atmospheric music, and the satisfying challenge that has captivated puzzle enthusiasts for decades. Whether you're a seasoned Mahjong veteran or new to tile-matching puzzles, Mahjong Titans provides hours of engaging mental exercise.

Core Features

Authentic Traditional Experience

  • 144 Classic Tiles : Features the complete set of traditional Mahjong tiles divided into three primary suits
  • Traditional Tile Designs : Beautifully crafted tiles with authentic Chinese characters, bamboo sticks, and dot patterns
  • Atmospheric Audio : Immersive Chinese-inspired background music enhances the gaming experience
  • Pyramid Layout : Classic turtle-shaped tile arrangement that creates strategic depth

Completely Free Gaming

  • No Download Required : Play instantly in your web browser without any installation
  • Cross-Platform Support : Works seamlessly on desktop computers and mobile devices
  • No Registration Needed : Jump straight into the game without creating accounts
  • Unlimited Play : Enjoy unlimited games with no time restrictions or pay walls

Strategic Puzzle Elements

  • Pattern Recognition : Develop your ability to spot matching tiles quickly
  • Strategic Planning : Think ahead to avoid blocking yourself into impossible situations
  • Multiple Difficulty Levels : Various layouts provide different challenge levels
  • Hint System : Helpful guidance when you're stuck on difficult patterns

Game Mechanics

The Three Tile Suits

Mahjong Titans features the traditional three primary suits that form the core of the 144-tile set:

  • Dots (Circles) : Tiles featuring circular patterns in various arrangements
  • Bamboo (Sticks) : Tiles displaying vertical line patterns representing bamboo sticks
  • Characters : Tiles with traditional Chinese characters and symbols

Each suit contains multiple variations, and your goal is to match identical tiles to remove them from the board.

Winning Strategy

Success in Mahjong Titans requires both pattern recognition skills and strategic thinking. Focus on removing tiles that will unlock the most options for future moves. Always prioritize freeing tiles that are blocking multiple other tiles underneath.

Operation Guide

Simple Mouse Controls

  • Left Mouse Click : Select and match tiles
  • Click First Tile : Choose your first tile from available options
  • Click Matching Tile : Select the identical tile to remove both from the board
  • Tile Movement : Only tiles that can move left or right without disturbing others are selectable

Tile Selection Rules

A tile can only be selected if: - It has at least one free side (left or right) - It's not blocked by tiles above it - There's an identical tile also available for matching - Removing it won't cause structural instability

Game Progression

Start by identifying easily accessible matching pairs, typically around the edges of the formation. As you remove tiles, new tiles become available underneath, creating fresh matching opportunities. The game becomes more challenging as fewer tiles remain and options become limited.

Why Play Mahjong Titans

Mental Benefits

Mahjong Titans is more than entertainment - it's excellent brain training. The game improves: - Visual Pattern Recognition : Enhances your ability to spot similarities and differences quickly - Strategic Thinking : Develops forward-planning and consequence-analysis skills - Concentration : Requires sustained focus and attention to detail - Memory : Helps remember tile locations and available matches

Accessibility and Convenience

Unlike many modern games, Mahjong Titans respects your time and device storage. There's no lengthy download process, no forced updates, and no intrusive advertisements disrupting your peaceful puzzle-solving experience.

Stress Relief

The combination of engaging mental challenge and soothing traditional music creates a perfect environment for stress relief and mental relaxation. Many players find the systematic tile-clearing process meditative and calming.

Universal Appeal

Mahjong transcends cultural and age boundaries. Whether you're 8 or 80, the fundamental appeal of pattern matching and logical problem-solving makes this game endlessly enjoyable.

Frequently Asked Questions (FAQ)