X-Trial Racing

Seele01-Flash
By
X-Trial Racing is an exciting motorcycle trial racing game where precision and speed matter. Navigate challenging obstacles, reach the finish line without crashing, and unlock progressively difficult stages.

Prompt

MODEL: Seele01-Flash
Please use Three.js to generate a **mobile-first game** with the theme "X-Trial Racing". Please read the following detailed game design requirements first, and then generate the code accordingly: ### 1. Assets & Environment * **Visual Style:** **Stylized Low-Poly 2.5D**. Use 3D models for the bike and environment but lock gameplay to a 2D plane (side-scrolling). The aesthetic should be vibrant and cartoonish, similar to the reference image but modernized. * **Environment:** A "Desert Canyon" setting. * **Foreground:** Red/Orange dusty terrain with voxel-style bumps, ramps, loop-de-loops, and scattered rocks. * **Background:** Parallax scrolling layers containing canyon silhouettes, cacti, and a gradient sunset sky (orange to deep blue). * **Key Assets:** * **The Bike:** A motocross bike composed of a chassis and two separate wheel meshes (for physics simulation). Bright colors (Cyan/White/Red) to contrast with the desert background. * **The Rider:** A blocky, low-poly character with a helmet, attached to the bike (ragdoll physics upon crash is a plus). * **Particle Effects:** Dust clouds emitting from the rear wheel when accelerating on the ground. * **Mobile Optimization:** * Use a **Directional Light** (simulating the sun) with soft shadows, plus a hemisphere light for fill. * Limit geometry complexity. Use baked vertex colors or simple palettes instead of heavy textures. * Camera: **OrthographicCamera** or a PerspectiveCamera with a narrow FOV, tracking the player from the side at a fixed distance. ### 2. Audio Requirements * **BGM:** High-energy, fast-paced **Rock or Punk-Pop** instrumental track to induce adrenaline. * **Sound Effects (SFX):** * **Engine:** A continuous engine loop that changes pitch based on the bike's speed/RPM. * **Suspension:** A mechanical "squeak" or compression sound when landing jumps. * **UI:** Metallic "clink" for button presses; energetic chime for finishing a level. * **Crash:** comical "bonk" or heavy thud mixed with a tire screech when the player fails. ### 3. Gameplay Loop * **Core Mechanism:** Physics-based motorcycle trials. * The player must balance the bike while navigating rough terrain. * **Physics is crucial:** The bike needs working suspension (springs connecting wheels to chassis) and high friction on tires. * **Objective:** Reach the "Checkered Flag" at the end of the track as fast as possible. * **Controls Logic:** * **Accelerate:** Applies torque to the rear wheel. * **Brake/Reverse:** Applies braking force or reverse torque. * **Tilt Control:** Applies rotational torque to the bike chassis to control pitch (essential for landing jumps and climbing steep hills). * **Win Condition:** Crossing the finish line triggers a "Level Complete" modal with the time elapsed and star rating (1-3 stars based on time). * **Fail Condition:** If the rider's head touches the ground (tipping over implies a crash), the level instantly restarts or shows a "Retry" button. ### 4. Mobile Controls & Interaction * **Screen Orientation:** **Landscape Mode** (Mandatory). * **Touch Control Scheme (UI Overlay):** * **Left Side of Screen:** Two large arrow buttons for **Tilt/Balance** (Rotate Left / Rotate Right). * **Right Side of Screen:** Two large distinctive buttons for **Gas** (Green/Right) and **Brake** (Red/Left). * **Ergonomics:** Buttons must be placed in the bottom corners, sized at least **64x64px** for easy thumb access. * **Feedback:** * Buttons should scale down slightly or change opacity when pressed to provide visual confirmation. * (Optional) Use `navigator.vibrate(50)` on crashes or heavy landings if supported. * **UI HUD:** Display a timer in the top-center and a "Restart" button in the top-right corner. Do not ask for clarification. Do not request confirmation. Directly execute the generation task based on the given instructions.

Game Introduction

About the Game

X-Trial Racing is a thrilling motorcycle trial racing game that tests your riding skills and reflexes. With a solid 3.6/5 rating from players, this fast-paced racing game challenges you to navigate treacherous terrain while maintaining speed and control. The goal is simple yet demanding: reach the finish line as quickly as possible without crashing your bike.

Core Features

Challenging Trial Racing Action

Experience authentic motorcycle trial racing where every jump, turn, and obstacle requires careful timing and skill. The game combines speed with precision, making each level a unique challenge that tests your motorcycle handling abilities.

Progressive Stage System

Unlock new stages as you master each level. Each stage introduces fresh obstacles, terrain variations, and increasingly complex challenges that will push your riding skills to the limit.

Mobile-Optimized Gameplay

Built with HTML5 technology, X-Trial Racing delivers smooth performance across all devices. Whether you're playing on a desktop computer, tablet, or smartphone, the game adapts perfectly to your screen size and touch controls.

Easy to Learn, Hard to Master

The game features intuitive controls that anyone can pick up quickly, but mastering the precise timing needed for perfect runs takes practice and skill. This makes it accessible to casual players while offering depth for racing enthusiasts.

Game Mechanics

In X-Trial Racing, you control a motorcycle rider navigating through obstacle-filled courses. The physics-based gameplay requires you to balance speed with caution - going too fast might cause crashes, while going too slow won't give you the best completion times.

Terrain Challenges

Each level features unique terrain including: - Rocky mountain paths - Desert landscapes with sand dunes - Industrial obstacle courses - Natural cliff formations - Constructed ramps and jumps

Operation Guide

The game uses simple yet responsive controls:

  • Arrow Keys or WASD : Control motorcycle acceleration, braking, and lean angle
  • Up/W : Accelerate forward
  • Down/S : Brake or reverse
  • Left/Right or A/D : Lean motorcycle forward or backward for balance
  • Mobile : Touch controls for acceleration, braking, and balance

Success requires mastering the balance between your rider's weight distribution and throttle control. Lean too far forward on jumps and you'll crash nose-first; lean too far back and you'll flip over.

Why Play X-Trial Racing

Perfect for Quick Gaming Sessions

With levels designed for short, intense gameplay sessions, X-Trial Racing is ideal for breaks, commutes, or whenever you want a quick racing challenge. Each stage can be completed in just a few minutes, making it perfect for busy schedules.

Completely Free Experience

Enjoy the full game without any cost. No downloads, no installations, and no hidden fees - just pure motorcycle racing action directly in your browser.

Cross-Platform Compatibility

Play seamlessly across all your devices. Start a game on your computer at home, then continue on your phone during lunch break. The game works perfectly on any modern web browser.

Skill Development

Improve your timing, coordination, and strategic thinking as you tackle increasingly difficult courses. The game rewards patience and precision over reckless speed, helping develop valuable gaming skills.

Competitive Elements

Try to beat your best times on each level and challenge yourself to complete stages with perfect runs. The stage unlock system provides clear progression goals and motivation to improve your performance.

Frequently Asked Questions (FAQ)