DuBlox - Block Puzzle Game

Seele01-Flash
By
DuBlox is an engaging block puzzle game where you guide a yellow square to red target tiles through strategic flipping and rolling. Perfect for puzzle enthusiasts seeking a mental challenge with scoring mechanics.

Prompt

MODEL: Seele01-Flash
Please use Three.js to generate a **mobile-first game** with the theme "DuBlox". Please read the following detailed game design requirements first, and then generate the code accordingly: ### 1. Assets & Environment * **Visual Style**: Minimalist Sci-Fi Isometric. Use a clean, high-contrast palette suitable for small screens and outdoor viewing. * **The Player (The Block)**: A rectangular prism with dimensions 1x1x2. * Color: Bright Yellow (`#FFD700`). * Detail: Add a thin black line or groove around the middle to visually separate it into two 1x1 cube sections. * Material: `MeshStandardMaterial` with slight roughness (0.4) to catch light without excessive glare. * **The Level (Grid Platform)**: Floating islands made of 1x1 cubes. * Floor Tiles: Cyan/Light Blue (`#00BFFF`). Top face is lighter, side faces are darker to emphasize depth. * Goal Tiles: Bright Red (`#FF4500`). Requires the block to stand upright on it to trigger. * Special Tiles: Green (`#32CD32`) for switches/bridges. * Void/Background: A deep blue radial gradient (`#000033` to `#000066`) or a wireframe grid floor far below to give a sense of height. * **Camera**: Orthographic Camera set to an isometric angle (looking down at approx 45 degrees). The camera should center on the player block and smoothly follow its movement. * **Mobile Optimization**: Use simple geometry (BoxGeometry). Avoid complex shadows; use a simple DirectionalLight and AmbientLight setup. Turn off antialiasing if DPI is high to save battery. ### 2. Audio Requirements * **BGM**: A "Thinking" track. Ambient, electronic, repetitive but non-intrusive. Similar to 'Portal' or 'Monument Valley' ambient tracks. * **Sound Effects (SFX)**: * *Roll/Impact*: A heavy, solid "thud" or stone-on-stone sound when the block flips. * *Bridge/Switch*: A mechanical high-pitched servo sound. * *Fall (Game Over)*: A "whoosh" decreasing in pitch (Doppler effect). * *Level Clear*: A harmonious positive chord (major triad). ### 3. Gameplay Loop * **Core Mechanic**: The player controls a 1x1x2 block on a grid of tiles. * The block moves by rolling over its edges. * **State Change**: The block alternates between "Standing" (occupying 1 tile) and "Lying" (occupying 2 tiles) depending on the direction of the roll. * **Objective**: Navigate the block to the Red Goal Tile. The block must fall into the goal hole vertically (standing up). If it rolls over the goal while lying down, it acts as a normal floor. * **Fail State**: If any part of the block rolls off the edge of the platform, the block falls into the void, and the level resets. * **Puzzle Elements**: * *Soft Tiles*: Orange tiles that cannot support the block if it stands upright (it will fall through), but can support it if it is lying flat. * *Switches*: Buttons that toggle bridges or extra tiles. * **Scoring**: Count the number of "Moves". Display a "Par" (target number of moves) for the level. ### 4. Mobile Controls & Interaction * **Input Method**: **Swipe Gestures** (Touch). * Swipe Up/Down/Left/Right anywhere on the screen to roll the block in the corresponding isometric direction. * Implement a "cooldown" or boolean lock (`isMoving`) to prevent the player from swiping again before the current roll animation completes. * **Orientation**: Portrait mode (preferred for one-handed play) or Landscape. Ensure the camera zoom creates large enough visible tiles for clarity. * **UI Overlay**: * **Top Center**: Level Indicator (e.g., "Level 1"). * **Top Right**: A distinct "Restart" icon (at least 44x44px touch target). * **Bottom Center**: Move Counter (e.g., "Moves: 12"). * **Feedback**: * **Haptic**: Trigger a short vibration (`navigator.vibrate(50)`) upon every successful land. * **Visual**: A subtle screen shake when the heavy block lands standing up. Highlight the tile under the block to show the player exactly where they are positioned. Do not ask for clarification. Do not request confirmation. Directly execute the generation task based on the given instructions.

Game Introduction

About the Game

DuBlox is a captivating puzzle game that challenges your spatial reasoning and strategic thinking. The objective is elegantly simple yet increasingly complex: move your yellow square across a grid-based playing field to reach the red target tiles. What makes this puzzle unique is the rolling mechanic - your square doesn't simply slide from position to position, but flips and rolls, changing its orientation with each move.

This brain teaser has earned a solid rating from puzzle enthusiasts who appreciate its perfect balance of accessibility and challenge. The game's clean, geometric design focuses your attention on the puzzle mechanics without visual distractions.

Core Features

Strategic Movement System

Every move in DuBlox requires careful consideration. Your yellow square responds to directional input by rolling in the chosen direction, and understanding how it will land is crucial to solving each level efficiently.

Scoring and Optimization

The game rewards efficient thinking through its scoring system. Minimize your moves to maximize your score, adding a competitive element that encourages players to find the optimal solution rather than just any solution.

Special Square Mechanics

As you progress, you'll encounter special squares that add new dimensions to the puzzle. These elements introduce additional mechanics that enhance your "flipping skills" and create more complex scenarios to solve.

Progressive Difficulty

Each level builds upon the previous one, gradually introducing new concepts and more challenging layouts. This ensures a smooth learning curve while maintaining long-term engagement.

Game Mechanics

The rolling mechanic is what sets DuBlox apart from traditional sliding puzzles. When you press an arrow key, your square doesn't simply move to an adjacent cell - it performs a complete roll, changing which face is in contact with the ground. This adds a three-dimensional thinking element to what appears to be a 2D puzzle.

Understanding the physics of your square's movement becomes increasingly important as levels become more complex. You'll need to visualize not just where your square will end up, but how it will be oriented when it arrives.

Operation Guide

Controls are intentionally simple to keep focus on the puzzle-solving aspect:

  • Arrow Keys : Move your yellow square in the corresponding direction
  • Up Arrow : Roll the square upward
  • Down Arrow : Roll the square downward
  • Left Arrow : Roll the square to the left
  • Right Arrow : Roll the square to the right

The game requires no complex input combinations - just directional thinking and strategic planning.

Why Play DuBlox

Perfect Brain Training

DuBlox offers excellent mental exercise, improving spatial reasoning, logical thinking, and planning skills. It's an ideal game for players who want to challenge their minds while having fun.

Accessible Yet Deep

While anyone can understand the basic concept immediately, mastering the game requires developing sophisticated problem-solving strategies. This makes it perfect for both casual puzzle solving and serious brain training.

No Pressure Gaming

There are no time limits or pressure mechanics - you can think through each move at your own pace. This makes it perfect for relaxation while still providing mental stimulation.

Free Browser-Based Fun

The game runs directly in your web browser without requiring downloads, subscriptions, or payments. It's completely free entertainment that's available whenever you want a mental challenge.

Frequently Asked Questions (FAQ)