Light the Lamp - Brain Puzzle Game

Seele01-Flash
By
Light the Lamp is an engaging puzzle game that challenges your strategic thinking. Navigate power cords with limited length to connect bulbs to sockets while avoiding obstacles.

Prompt

MODEL: Seele01-Flash
Please use Three.js to generate a **mobile-first game** with the theme "Light the Lamp". Please read the following detailed game design requirements first, and then generate the code accordingly: ### 1. Assets & Environment * **Visual Style**: Create a **"Flat 2.5D" aesthetic**. Use an Orthographic Camera to simulate a purely 2D top-down view but give the objects (lamp, plug, obstacles) slight depth (extruded geometry) and soft shadows to make them pop against the background. * **Color Palette**: Replicate the screenshot's mood. Background: Muted Dark Teal-Grey (`#4a555c`) with a subtle dot pattern. Lamp: Warm Yellow (`#eebb4d`). Cord: Off-white/Beige (`#e0d8c0`) with thick black outlines (using Three.js LineSegments or edge geometry). Obstacles: Dark Grey circles. * **The Cord (Crucial)**: The cord should be rendered as a smooth TubeGeometry or a series of connected cylinders. It must visually behave like a flexible rubber cable. * **Performance**: Use simple geometries (Cylinders for pegs, Extruded Shapes for the bulb/plug). Merge geometries where possible. Target 60fps on mobile browsers. ### 2. Audio Requirements * **BGM**: A quiet, lo-fi "thinking music" track. Minimalist piano or soft synth pads that loop seamlessly. * **Sound Effects (SFX)**: * **Drag**: A subtle rubbery sliding sound when moving the plug. * **Tension**: A strained "creak" sound when the cord reaches its maximum length limit. * **Collision**: A soft "thud" when the cord wraps around a peg. * **Success**: A satisfying "Click" followed by an electrical hum and a joyful chime when the socket is plugged in. * **UI**: Crisp clicks for Restart/Hint buttons. ### 3. Gameplay Loop * **Core Mechanic**: The player controls the **Plug**. The **Lamp** is stationary. They are connected by a cord with a **fixed maximum length**. * **Physics Logic**: Implement a rope physics system (e.g., Verlet integration or chain of constraints). The rope must collide with and wrap around circular obstacles (pegs) in the environment. It cannot pass through them. * **Constraint**: The player must navigate the Plug around obstacles to reach the **Socket**. If the cord is wrapped around too many obstacles, it becomes too short to reach the goal. * **Win Condition**: The Plug collides with the Socket target area. Upon winning, the Lamp mesh should change material to purely emissive (glowing) and particle effects (sparks/light rays) should burst. * **Fail/Retry**: If the cord is fully stretched and the target is not reached, the player must backtrack to unspool the cord. ### 4. Mobile Controls & Interaction * **Control Scheme**: **"Relative Virtual Joystick"**. The user can touch anywhere on the screen and drag to move the Plug. This prevents the user's finger from obscuring the puzzle piece. * *Movement Vector*: Calculate the delta between the touch start and current touch position to apply velocity to the Plug. * **Orientation**: Force **Portrait Mode** for vertical levels, but the camera should resize responsively to fit the puzzle board within the screen width. * **UI Layout**: * Place "Restart" and "Hint" buttons in the top-right corner. * Touch targets for buttons must be at least 44x44 pixels. * **Haptic Feedback**: * Trigger a **heavy vibration** (approx 40ms) when the socket is successfully plugged in. * Trigger a **light tap** (approx 10ms) when the cord hits its maximum length limit (simulating tension). Do not ask for clarification. Do not request confirmation. Directly execute the generation task based on the given instructions.

Game Introduction

About Light the Lamp

Light the Lamp is a captivating puzzle game that combines simple mechanics with challenging strategic gameplay. Your mission seems straightforward - connect a power plug to a socket to light up a bulb. However, this deceptively simple concept evolves into a mind-bending puzzle experience that will test your spatial reasoning and planning skills.

The game features a minimalist design with clean graphics and intuitive controls, making it accessible to players of all ages while providing depth that keeps puzzle enthusiasts engaged for hours.

Core Features

Strategic Puzzle Mechanics

Each level presents a unique challenge where you must navigate a power cord from the plug to the socket. The cord has a limited length , which means every move counts. You'll need to plan your route carefully, considering obstacles and the cord's path to successfully light each lamp.

Progressive Difficulty

Start with simple connections and gradually face more complex puzzles featuring: - Obstacle avoidance : Navigate around barriers and hazards - Path optimization : Find the most efficient route with limited cord length - Strategic planning : Think several moves ahead to avoid getting stuck

Brain Training Benefits

This puzzle game serves as excellent brain exercise, improving: - Spatial awareness and visual processing - Problem-solving skills through logical deduction - Strategic thinking and forward planning - Patience and persistence in overcoming challenges

Accessibility Features

  • Hint system : Get helpful tips when you're stuck
  • Restart option : Try different approaches without penalty
  • Cross-platform compatibility : Play seamlessly on any device

Gameplay Mechanics

The core gameplay revolves around maneuvering a power plug connected to a cord of limited length. Each level presents a different layout with the plug starting at one position and the socket located elsewhere on the grid.

Challenge Elements

  • Limited cord length : You can't extend beyond the cord's reach
  • Obstacle navigation : Avoid barriers that block your path
  • Optimal pathfinding : Discover the most efficient route
  • Multiple solutions : Some levels offer various ways to succeed

Operation Guide

Controls are intuitive and responsive:

  • WASD Keys : Move the power plug in four directions
  • Arrow Keys : Alternative movement controls
  • Hint Button : Located at the top of the screen for guidance
  • Restart Button : Reset the level to try a different approach

The game automatically detects when you've successfully connected the plug to the socket, lighting up the bulb and advancing you to the next challenge.

Why Play Light the Lamp

Perfect for All Skill Levels

Whether you're a puzzle game novice or a seasoned strategist, Light the Lamp offers an engaging experience. The difficulty curves smoothly, introducing new concepts gradually while maintaining the core mechanics that make the game addictive.

Excellent Brain Exercise

This game provides meaningful mental stimulation without overwhelming complexity. It's perfect for: - Daily brain training sessions - Stress relief through focused problem-solving - Improving concentration and attention to detail - Developing logical thinking skills

Convenient Gaming Experience

  • No download required : Play instantly in your browser
  • Cross-device compatibility : Continue playing on different devices
  • Quick sessions : Perfect for short breaks or extended play
  • Family-friendly : Suitable for players of all ages

Addictive Progression System

Each successfully lit lamp provides a sense of accomplishment, motivating you to tackle the next challenge. The question "How many lamps can you successfully light?" becomes a personal challenge that keeps you coming back.

Light the Lamp successfully combines the satisfaction of puzzle-solving with the accessibility of casual gaming, making it an ideal choice for anyone looking to exercise their mind while having fun.

Frequently Asked Questions (FAQ)