
1. 弹射收集星星角度力度 抛物线Build a catapult-style star collector game using Canvas. Player drags back from a slingshot at bottom left to set angle and power, releasing launches a small ball. The ball flies in an arc affected by gravity. On the screen, 10 stars float at different positions. Collecting a star adds 10 points and makes it disappear. After launch, the ball bounces off walls and ground (restitution 0.6) until it comes to rest. Then player can launch again. Each level requires collecting all stars within 5 launches. Display launches left, score, current level. After clearing all stars, level increases, stars respawn in harder positions (higher up, behind obstacles). Add wind effect (random horizontal force each launch) displayed as an arrow. Use requestAnimationFrame for physics. Provide aim assist line (dotted trajectory). Reset button restarts level. The challenge is combining drag input, projectile simulation, collision detection with stars, and progressive difficulty.为什么选这个弹射玩法需要向量计算、碰撞检测和关卡设计。风力增加随机性让每次发射都不一样。2. 轨道跑酷自动奔跑 切换轨道Create an infinite runner where the player automatically runs forward on three parallel tracks (top, middle, bottom). The player character is a small sprite at left side, the world scrolls right to left. Obstacles (gaps, low barriers, high barriers) spawn on random tracks. Player switches tracks using up/down arrows. If the player is on the same track as an obstacle when it reaches them, game over. Collect coins (optional) on some tracks for score. Speed increases every 10 seconds. Display score (distance) and high score (localStorage). Provide restart on game over. Use Canvas, scroll using an offset or redraw positions. Obstacles are generated procedurally: every 1.5 seconds, pick a random track and an obstacle type. Gap: player must jump? But switching tracks already handles avoidance – simplify: just make obstacles that occupy one track, player must switch to a different track. Add a visual warning (flashing red) 0.5 seconds before obstacle appears. No physics, just collision based on track alignment. The challenge is managing scrolling, spawn timing, and increasing difficulty.说人话三轨道跑酷换轨道躲障碍。逻辑比平台跳跃简单但生成算法和难度曲线需要调好。闪红预警让玩家有反应时间。3. 拼字对战字母组合 词库校验Implement a word battle game (like Scrabble but simplified). Two players (human vs AI or human vs human) share a 5x5 letter grid. Letters are randomly generated (vowels more frequent). Players take turns forming a word of 3 to 5 letters using adjacent tiles (horizontally or vertically, no diagonals). After submitting a word, those tiles are removed, new random letters fall from top to fill gaps, and the player earns points equal to the word length squared. AI opponent: uses a small hardcoded dictionary of 100 common words (or you can use a Trie if you want, but for simplicity, predefine an array of valid short words). AI picks the longest possible word from the grid using brute force (check all starting positions and directions). Display scores, current player turn, and the grid. Validate words against dictionary. No animations, just grid updates. Include a pass button (skip turn) and restart. Game ends after 20 turns or when no valid words left. Use localStorage for high score. The challenge is generating falling letters, grid refill, word validation, and AI word search.核心价值拼字游戏考验字符串处理、字典查找和搜索算法。AI找最长词是个小型回溯问题。4. 重力迷宫旋转装置 滚球Build a gravity maze puzzle using Canvas. A ball (circle) rolls on a grid-based level (10x10 cells). Each cell can be empty, wall, goal (green), or a rotator (special tile). Player controls not the ball directly, but the direction of gravity. There are four buttons (up/down/left/right). Pressing a button changes the global gravity direction. The ball then rolls in that direction until it hits a wall or edge. Rotator tiles: when the ball rolls over them, they spin 90 degrees clockwise, changing the gravity direction? Or simpler: rotator tiles just redirect the ball (like a curve). Goal: reach the green goal cell. Provide 3 pre-made levels (hardcode arrays). Include undo button (revert last gravity change) and reset level. Display move count. Use a turn-based system: each gravity change is a move, ball moves step by step until collision. No physics, just grid movement. The challenge is implementing ball movement logic after each gravity change (loop: check next cell in gravity direction, if empty move, if wall stop, if rotator change direction and continue). Also need to handle multiple cells moved in one press.为什么选这个重力迷宫是解谜游戏核心是状态变化和移动逻辑。旋转器改变方向增加复杂度。做完你对队列或递归模拟移动会有深刻理解。5. 牌组构建Roguelike卡牌 随机奖励Create a deck-building roguelike prototype (like Slay the Spire basics). Player starts with a deck of 5 cards: 2x Strike (deal 6 damage), 2x Block (gain 5 block), 1x Heal (restore 3 HP). Enemy is a simple monster with 30 HP, dealing 8 damage per turn. Each turn, player draws 3 cards from deck (reshuffle when empty). Play cards: damage reduces enemy HP, block reduces incoming damage for that turn. After playing cards, end turn: enemy attacks, player loses HP equal to enemy attack minus block (block resets each turn). When enemy HP 0, player chooses one of three random new cards to add to deck (e.g., Strong Strike (10 damage), Big Block (8 block), Heal (5 HP)). Then proceed to next enemy (HP increases by 5 each time, damage increases by 2). Player HP persists between fights. Display current HP, enemy HP, hand cards, deck size, discard pile? (optional but nice). Provide restart button. Game ends when player HP 0. Use vanilla JS, no animations. Card effects modify player/enemy stats. The challenge is implementing turn flow, deck shuffling, hand management, and after-combat card reward selection.说人话牌组构建的核心是回合流程和卡牌效果。随机奖励让每次通关不一样。做完了你对卡牌游戏的状态机会有完整认识。这五个类型分别是弹射、跑酷、拼字、解谜、卡牌。每个都有明确的英文提示词和中文说明。写的时候先跑通最简版本比如弹射先让球飞出去碰到星星就加分再叠加高级功能风力、多关卡、随机奖励。代码能跑、不报错、逻辑闭环就已经合格了。