跳到正文
Orbit· 来源· @0xOrbitSpace · X·· 3 小时前AI 评分58
正文 · AI 翻译

我用 vibe-coding 写了《沙丘》里的沙虫
而且你能驾驶它
一个 HTML 文件。没有 Blender,没有游戏引擎,没有 3D 模型
里面有什么:
→ 25 节装甲环,像火车车厢一样跟着头部走
→ 口中旋转着由 40 颗牙齿和 36 片刀刃组成的冠
→ 身体划破沙面时扬起的尘土
→ X 光模式,显示仍在地下的部分
→ 方向键操控:左、右、下潜、破土

关键在于把运动写成一条路径,而不是动画。头部选定路线,每一节环只需跟随,所以身体自然弯曲
哪里翻车了:
> 第一版把相机放到了沙子下面
> 尘土一开始看不见,直到用正确的尺寸读取了深度缓冲
> 这是一只风格化机械虫,不是电影里那只

把这段粘贴进 Claude Code ↓
"Build a [creature] in a single three.js HTML file.
1. Describe the body as segments that follow one path, before any code
2. Build each segment from chamfered boxes, no textures, no imported models
3. Add arrow-key steering where only the head turns and the body follows
4. Add particles where the body crosses the ground
Show me the segment plan first and wait for my yes."
在这里驾驶它 ↓

https://claude.ai/artifact/YLtwmAeL6NL9M3DpXXXGKu
它应该先吃什么?

来源:Orbit · x.com