制作梯子游戏

用一个AI提示词制作梯子游戏(사다리타기)。设置参与者姓名和奖品,观看动画路径揭晓结果!

提示词

复制下面的提示词粘贴到Claude或ChatGPT。

Prompt

Create a single-file HTML ladder game (사다리타기) with these specifications:

1. **Setup screen**:
   - Number of players input (2-8)
   - Editable name fields for each player
   - Editable result/prize fields for each player (emoji or text)
   - "Start" button to begin

2. **Ladder generation**:
   - Random horizontal rungs between vertical lines
   - 8-13 rows of rungs, ~45% chance per position
   - No two adjacent rungs on the same row
   - Results are shuffled randomly

3. **Gameplay**:
   - Click a player name at the top to trace their path
   - Animated path tracing with a colored moving dot
   - Path follows: go down, if horizontal rung exists go left/right, continue down
   - Each player gets a unique color
   - Show result popup when trace completes

4. **Visual style**:
   - Dark background (#0a0a1a), colored player name badges at top
   - Results hidden as "?" until revealed by tracing
   - Smooth animation, rounded corners
   - Canvas-based rendering, responsive to screen size
   - Touch support for mobile

5. **Controls**:
   - "Reset" button to go back to setup
   - Result banner auto-hides after 2.5 seconds

6. **Single file**: Everything (HTML, CSS, JS) in one file. No external dependencies.

成果展示

  • 2-8人参与者,自定义姓名和结果
  • 随机梯子+动画路径追踪
  • 每位参与者独特颜色
  • 移动端触控支持

运行方法

  1. 复制上面的提示词
  2. 粘贴到Claude或ChatGPT
  3. 保存为ladder.html
  4. 在浏览器中打开!