Three.js와 Cannon.js를 활용해 중력 회전 메커니즘을 가진 3D 웹 퍼즐 게임을 프로토타이핑할 때 사용합니다.
Game Concept: A puzzle-platformer named "Gravity Shift" where players rotate the entire world to navigate a 3D low-poly labyrinth. The environment is minimalist, using pastel gradients and sharp geometric shapes.
Technical Prompt:
Build a 3D platformer using Three.js and Cannon.js. The world is a cube-shaped maze. When the user presses 'R', rotate the world.gravity vector by 90 degrees.
JavaScript
// Gravity rotation logic
world.gravity.set(0, -9.82, 0); // Default
function rotateGravity() {
let newG = new CANNON.Vec3(-world.gravity.y, world.gravity.x, 0);
world.gravity.copy(newG);
}
Include smooth camera interpolation using Lerp to follow the player's rigid body during shifts.게임 컨셉: 플레이어가 3D 로우폴리 미로를 탐험하기 위해 세계 전체를 회전시키는 "Gravity Shift"라는 퍼즐 플랫폼 게임입니다. 환경은 미니멀하며 파스텔 그라데이션과 날카로운 기하학적 모양을 사용합니다.
기술 프롬프트:
Three.js와 Cannon.js를 사용하여 3D 플랫폼 게임을 제작하세요. 세계는 정육면체 모양의 미로입니다. 사용자가 'R'을 누르면 world.gravity 벡터를 90도 회전합니다.
JavaScript
// 중력 회전 로직
world.gravity.set(0, -9.82, 0); // 기본값
function rotateGravity() {
let newG = new CANNON.Vec3(-world.gravity.y, world.gravity.x, 0);
world.gravity.copy(newG);
}
중력 회전 중에 플레이어의 강체(rigid body)를 추적할 수 있도록 Lerp를 활용한 부드러운 카메라 보간을 포함하세요.출처 · prompts.chat · Gravity Shift: Low-Poly Physics Platformer — 원문은 출처에 게시된 그대로이며, 권리는 원작자에게 있습니다.
Gemini로 프롬프트를 실행해 생성한 화면입니다. 화면 안에서 직접 조작하실 수 있습니다.
Three.js와 Cannon.js 물리 엔진을 활용하여 파스텔 톤의 3D 입체 미로에서 중력의 방향을 90도씩 회전시키며 탈출하는 'TPI 중력 이동' 퍼즐 플랫폼 게임을 구축했습니다. 자동 시연 시스템을 내장하여 접속 즉시 3D 미로 및 중력 회전 동작을 감상할 수 있으며, 화면의 컨트롤 버튼(중력 회전, 재시작, 방향키)과 키보드 조작으로 즉시 전환되어 모든 기능이 실제로 완벽히 동작합니다.
Game Concept: A puzzle-platformer named "TPI 중력 이동" where players rotate the entire world to navigate a 3D low-poly labyrinth. The environment is minimalist, using pastel gradients and sharp geometric shapes.
Technical Prompt:
Build a 3D platformer using Three.js and Cannon.js. The world is a cube-shaped maze. When the user presses 'R', rotate the world.gravity vector by 90 degrees.
JavaScript
// Gravity rotation logic
world.gravity.set(0, -9.82, 0); // Default
function rotateGravity() {
let newG = new CANNON.Vec3(-world.gravity.y, world.gravity.x, 0);
world.gravity.copy(newG);
}
Include smooth camera interpolation using Lerp to follow the player's rigid body during shifts.Gemini로 실행한 결과입니다. 입력 항목에는 국내 환경의 예시값을 적용했습니다(AI 생성 — 사실 확인 필요).
Game Concept: A puzzle-platformer named "TPI 중력 이동" where players rotate the entire world to navigate a 3D low-poly labyrinth. The environment is minimalist, using pastel gradients and sharp geometric shapes.
Technical Prompt:
Build a 3D platformer using Three.js and Cannon.js. The world is a cube-shaped maze. When the user presses 'R', rotate the world.gravity vector by 90 degrees.
JavaScript
// Gravity rotation logic
world.gravity.set(0, -9.82, 0); // Default
function rotateGravity() {
let newG = new CANNON.Vec3(-world.gravity.y, world.gravity.x, 0);
world.gravity.copy(newG);
}
Include smooth camera interpolation using Lerp to follow the player's rigid body during shifts.Three.js와 Cannon.js 물리 엔진을 활용하여 파스텔 톤의 3D 입체 미로에서 중력의 방향을 90도씩 회전시키며 탈출하는 'TPI 중력 이동' 퍼즐 플랫폼 게임을 구축했습니다. 자동 시연 시스템을 내장하여 접속 즉시 3D 미로 및 중력 회전 동작을 감상할 수 있으며, 화면의 컨트롤 버튼(중력 회전, 재시작, 방향키)과 키보드 조작으로 즉시 전환되어 모든 기능이 실제로 완벽히 동작합니다.
원문과 같은 언어로 보완한 프롬프트입니다. 점수는 명확성 · 구체성 · 출력 형식 · 재사용성 기준의 AI 평가입니다.
Role: Senior WebGL Developer specializing in Three.js and Cannon.js.
Task: Create a runnable 3D puzzle-platformer prototype named "Gravity Shift".
Visual Style: Minimalist low-poly labyrinth with pastel gradients ([color_palette]).
Technical Requirements:
1. Scene Setup: Build a cube-shaped maze with static box colliders and a dynamic sphere player rigid body.
2. Gravity Shift Mechanic: When pressing '[key_trigger]' (default 'R'), rotate `world.gravity` 90 degrees around the Z-axis:
```javascript
function rotateGravity() {
let newG = new CANNON.Vec3(-world.gravity.y, world.gravity.x, 0);
world.gravity.copy(newG);
}
```
3. Camera & Physics Sync: In the render loop, update visual meshes to match rigid body positions. Implement smooth camera position and orientation Lerp following the player during gravity shifts.
Output Format: Provide a single fully functional, self-contained HTML file including libraries via CDN.