← Playbook 首頁成品遊戲 · 3D 平台跳躍 · 僅限桌機

LANTERNMOSS HOLLOW

Pell 在黃昏的苔蘚谷地裡奔跑跳躍、收集 glowseed,再把發條甲蟲 Brassback 一塊一塊踩碎。Claude Code 依照 Playbook 提示詞草稿完成,只有一個 bug 是我們自己修的。

先玩玩看

WASD 移動,空白鍵跳躍(按住跳得更高),在空中按滑鼠左鍵下砸。

僅限桌機。點一下遊戲開始,滑鼠控制鏡頭。按 G 在 Tripo 模型和灰盒之間切換,1 換 Pell 的造型,2 換 Brassback 的。

灰盒、模型和六套造型

第 2 階段的灰盒、第 5 階段的 Tripo 模型,以及 Pell 和 Brassback 各三套造型:classic、Wood,還有一套用我們自己的圖片做出來的。

灰盒 · 第 2 階段

灰盒 · 第 2 階段

方塊和圓柱體。Brassback 已經是九個有命名的部件,各自繞著自己的鉸鏈轉動。

Tripo 模型 · 第 5 階段

Tripo 模型 · 第 5 階段

Pell 和 Brassback 是主角素材:三角面更多,4K 貼圖附法線貼圖和金屬粗糙度貼圖。

Brassback · Wood

Brassback · Wood

同一個網格,用 Tripo 的 Wood 風格重新貼圖。按 2 切換。

Brassback · 銅綠

Brassback · 銅綠

用我們自己的銅綠色樣做出的風格。它沒有金屬粗糙度貼圖,看起來有點像玻璃。

Pell · 三套造型

Pell · 三套造型

classic、Wood,以及用我們生成的毛線色樣做出的針織造型。按 1 切換。

一個階段一個階段看這次怎麼做出來

兩段對話共 13 輪,agent 實際執行約 2 小時 13 分鐘,agent 費用 $43,Tripo 點數 1,010。最久的一輪是換上模型:44 分鐘、145 次工具呼叫。

  1. 名字、設定和「黃昏玩具盒」風格都是 agent 自己想的。灰盒裡 Brassback 由九個帶鉸鏈的部件組成,另外還有調參面板和三個 bot。

    • 依照我們的回答只做桌機版:沒有觸控操作,也沒有手機版面
    • 一個 bot 通關、一個一直撞牆、一個近身纏鬥;並在 60、120、144 Hz 下檢查動作是否順暢
    • Pell 和 Brassback 標為主角,各寫了一份細節清單
    設計,接著做灰盒
  2. 8 個項目、12 個 GLB。Pell:HD Model、4K 貼圖加 PBR、重拓撲到 10k、綁定骨架、七個動作庫動作和一個 Text to Motion。Brassback:HD Model 依部件生成,重拓撲到 20k。兩位主角各加了 Wood 和一套用我們自己的圖片做出的風格。

    • 1,010 點數,兩個帳號同時進行,約 50 分鐘
    • 六件道具就花了其中 660,每件 110
    • 有一步在步驟頁之外完成:Pell 的圖把他畫了兩次,正面和背面
    在 Tripo 做兩位主角
  3. 8 個動畫全部依名稱對上,Brassback 的 11 塊依名稱和位置歸組。修改 9 個碰撞數值之前,它先來問過我們。模型周圍的世界仍是灰盒。

    • 它量出 Brassback 的頂面是 2.28 → 1.6 m 的斜坡,建議改成階梯式頂面
    • 換造型只換了貼圖,銅綠外殼碎成了玻璃般的碎片
    • 修正手臂穿模的處理,把 Pell 雙手插口袋的待機姿勢變成了稻草人
    換上模型
  4. 我們回報了四個看到的狀況。agent 用程式碼搭出黃昏世界,把待機姿勢改回原樣;我們第二次回報造型問題時,它查出每套造型各有自己的 UV。接著壓縮建置版本,主機擋下 WebAssembly 之後,它又改成不用 WebAssembly 重新建置。

    • 75.8 MB 的模型 → 24.9 MB 的建置版本;第一個畫面出現前載入 11.0 MB
    • 依我們的要求,8 顆 glowseed 收集到 4 顆,護盾就會破
    • 在 tripo.page 上,bot 以剩 3 顆愛心、8 個部件全數打掉的狀態通關,錯誤 0
    試玩、壓縮、發布

六個階段之外

這次試了提示詞的主角等級:兩件素材比其他精細許多,各有三套造型,整個世界也要看起來像成品。選一個主題。

主角素材

把細節花在兩件素材上

最多可以把兩個項目標為主角。它們有更高的預算、附法線貼圖和金屬粗糙度貼圖的 4K 貼圖,以及列出材質、貼花和磨損的圖片提示詞。

Pell 的三角面
9,428
Brassback 的三角面
21,975
Pell / Brassback 的點數
180 / 170
  • Pell:HD Model、4K 貼圖加 PBR、重拓撲到 10k 三角面,再綁定骨架、套用動作。
  • Brassback:HD Model 依部件生成、4K 貼圖加 PBR、重拓撲到 20k 三角面,並用 Pack UV 讓所有部件共用同一個材質。
  • 主角的提示詞會加上材質、細小的細節、貼花和磨損,重點放在鏡頭最常看到的那一面。
  • 湊近看就會露出極限:Pell 的臉在 1 m 內會看出稜面,Brassback 外殼與車身之間的切口從上方看是黑的。
左:先前沒有主角素材那次製作中的 Boss。右:Brassback,同樣的光線。
左:先前沒有主角素材那次製作中的 Boss。右:Brassback,同樣的光線。
針織、縫補的補丁和靴子扣環,在約 2 m 的距離下依然清楚。
針織、縫補的補丁和靴子扣環,在約 2 m 的距離下依然清楚。
告訴你的 agent
最多標兩位主角,也就是玩家和主要敵人。描述它們的材質、貼花和磨損,並給它們附法線貼圖和金屬粗糙度貼圖的 4K 貼圖。

正面與背面

當圖片把主角畫了兩次

要求在「背面,也就是鏡頭最常看到的那一面」加上細節,圖像模型就把正面和背面並排畫了出來。

張圖裡有兩個人形
8 / 8
個步驟在步驟頁之外完成
1
  • 對這樣的圖執行 Generate 3D,會做出兩個連在一起的人形。
  • 我們的 Studio 助手把正面和背面分別裁出來,改用兩個視角生成。
  • 用多個視角生成的模型,在提供貼圖風格之前會先要求一張圖片:請上傳你生成它時用的那張圖。
每張候選圖都把 Pell 畫了兩次,正面和背面。
每張候選圖都把 Pell 畫了兩次,正面和背面。
告訴你的 agent
把背面描述成同一個人物單一正面視圖的一部分;不要要求背面視圖或多個視角。

造型

每套造型都帶著自己的 UV

用某個風格重新貼圖會保留形狀,但 UV 可能會移動,而且 Pack UV 每次匯出都會重新打包。把造型的貼圖套在預設網格上就會壞掉。

classic 和 Wood 相同的 UV
99.9%
classic 和銅綠相同的 UV
0%
次回報後才找到原因
2
  • 連沒有部件、也沒用 Pack UV 的 Pell,不同風格之間也只有 92–94% 的 UV 相同。
  • 同一個版本用 Pack UV 匯出兩次,UV 相同的比例是 0%;關掉 Pack UV 則是 100% 相同。
  • agent 一開始歸咎於法線貼圖。直到我們傳了 Studio 的螢幕截圖,它才找到 UV 的問題。
  • 風格版本沒有金屬粗糙度貼圖,所以 Wood 和銅綠看起來比 classic 平。
只換貼圖:銅綠外殼碎成了玻璃般的碎片。
只換貼圖:銅綠外殼碎成了玻璃般的碎片。
修好後:每套造型改為載入自己檔案的網格和貼圖。
修好後:每套造型改為載入自己檔案的網格和貼圖。
告訴你的 agent
比較每個風格的 UV 和預設檔案的 UV。不一樣時,就改用該風格檔案自己的網格,切成相同的部件,或綁到同一副骨架上。

部件

九個部件、十一塊、三個融合

Brassback 原本列了九個部件。用 Simple 依部件生成後,出來是 11 塊,其中車身、左外殼和鍋爐融合成了一塊。

列出的部件 → 塊數
9 → 11
個部件融合成一塊
3
個材質,所有部件共用
1
  • agent 依名稱和中心位置為各塊歸組,並印出每塊歸到哪裡。
  • 閥門轉輪原本在車身的範圍框內,鍋爐掉落後會懸在半空;它把轉輪移到鍋爐上,並說明了原因。
  • 依區域切割,會在外殼與車身的交界留下一個黑色的面,從上方看得到。
  • 部件依材質合併成一個網格,讓 draw call 維持在低水準。
依部件生成:11 塊,命名為 tripo_part_N。
依部件生成:11 塊,命名為 tripo_part_N。
遊戲中外殼和鍋爐仍然可以打掉:agent 依區域從融合的那一塊裡切出來。
遊戲中外殼和鍋爐仍然可以打掉:agent 依區域從融合的那一塊裡切出來。
告訴你的 agent
主角的部件清單控制在六個以內。如果列出的兩個部件變成了一塊,要告訴你的 agent 是哪兩個。

世界

世界也是外觀的一部分

素材清單只涵蓋物件,所以地面、天空和關卡邊緣一直維持灰盒,直到我們說整款遊戲都要和角色一樣好看。

個地面和天空的 Tripo 項目
0
次回報就修好了
1
  • 模型周圍全是程式碼:天空漸層、草地、一圈石頭、螢火蟲、一片霧海。
  • 近看撐得住;遠處的小島和岩石是平面的低面數形狀,比主角低一個檔次。
  • 一盞有陰影的主光、一張環境貼圖和泛光,讓顏色不至於發灰。
換上模型之後:成品模型站在一片單調的綠色世界裡。
換上模型之後:成品模型站在一片單調的綠色世界裡。
再過一輪:黃昏天空、草地、石環、螢火蟲和霧,全是用程式碼做的。
再過一輪:黃昏天空、草地、石環、螢火蟲和霧,全是用程式碼做的。
告訴你的 agent
在素材清單裡寫明地面、天空和關卡邊緣要怎麼做,是用 Tripo 項目還是用程式碼做,這樣才不會有東西停留在灰盒。

手臂

別動本來就該接觸的姿勢

提示詞要求 agent 量出手臂陷進身體的深度,再把手臂轉開。在 Pell 的厚毛衣上,量到的深度其實只是袖子貼在毛料上,修正卻把他的手從口袋裡拉了出來。

量到的深度,其實只是接觸
39 / 47 mm
修正的上限
12°
現在允許的隱藏接觸
2 cm
  • 我們說待機姿勢看起來像稻草人,agent 就把它改回 Tripo 原本做出來的樣子。
  • 現在的修正最多只轉動手臂 12°,並忽略最多 2 cm 的隱藏接觸。
雙手插口袋,維持 Tripo 做出來的樣子。
雙手插口袋,維持 Tripo 做出來的樣子。
告訴你的 agent
忽略袖子貼著衣服的幾公釐,也不要更動雙手本來就該碰到身體的姿勢。

Text to Motion

空中的動作做出來卻是站著的

下砸這個動作是在空中收腿,再往下猛踩,我們把它寫成一句 Text to Motion。Tripo 回傳的卻是地面上的跺腳。

點數生成這個動作
20
點數重新套用
0
  • Studio 把它改名為 Tuck Jump with Stamp,放在 AI Animation 底下。
  • 重新貼圖後,再到那裡點一下就能免費重新套用。
  • agent 改用 jump_down 的一小段來做下砸。
用 Text to Motion 寫出的下砸,播放起來是站著跺腳。
用 Text to Motion 寫出的下砸,播放起來是站著跺腳。
告訴你的 agent
地面上的動作用 Text to Motion。空中的動作,請你的 agent 從動作庫的跳躍動作裡裁出來。

建置與主機

壓縮後,改成不用 WebAssembly 重新建置

壓縮把模型從 75.8 MB 縮到 22 MB,卻改變了骨骼讀取靜止姿勢的方式,之後 tripo.page 又擋下了 WebAssembly 解碼器。

最終建置版本,模型原本 75.8 MB
24.9 MB
第一個畫面前載入
11.0 MB
Pell 在空中下沉,只出現在壓縮版
1.1 m
  • 壓縮後的建置版本中,所有空中動作都會把 Pell 壓進地面約 1.1 m。bot 還是通關了,所以沒有任何測試抓到。這個問題是我們自己修的,把骨骼的原始變換還原。
  • 主機只執行頁面本身的腳本,所以網格解碼器(WebAssembly)和 data: 字型被擋下,大多數模型退回灰盒。
  • 只告訴它症狀和主機的規則,agent 就改用不需要解碼器的量化幾何,把同樣的規則加進自己的預覽伺服器,順手修好了造型切換的競態問題。
在 tripo.page 上,bot 以剩 3 顆愛心、8 個部件全數打掉的狀態通關。
在 tripo.page 上,bot 以剩 3 顆愛心、8 個部件全數打掉的狀態通關。
告訴你的 agent
要試玩壓縮後的版本,不能只玩開發版,並比較壓縮前後的動畫。如果你的主機有嚴格的 Content Security Policy,就用同樣的標頭在本機測試。

這次踩到的坑

哪裡出了問題、為什麼,以及怎麼修好的。其中大部分已經記成下一版提示詞的修改筆記。

主角圖把角色畫了兩次

提示詞要求在背面加細節,圖像模型就會把正面和背面並排畫出來。把背面描述成同一個正面視圖的一部分,或重新生成。

造型載入了,看起來卻支離破碎或像迷彩

風格版本的 UV 可能不同,而且 Pack UV 每次匯出都會改動它們。請改為載入每套造型自己的網格和貼圖,不要只換貼圖。

風格版本看起來比預設的平

它們沒有金屬粗糙度貼圖,法線貼圖也是新的。先有心理準備,或在比較外觀前,先看每個檔案各有哪些貼圖。

列出的兩個部件變成了一塊

用 Simple 依部件生成,九個部件裡有三個融合了。主角的部件控制在六個以內,並告訴 agent 哪些部件融合了,讓它依區域切開。

角色看起來像成品,世界卻不像

素材清單裡沒有任何項目涵蓋地面或天空。請在素材清單中要求它們,用 Tripo 項目或程式碼都可以。

壓縮後的版本玩起來不一樣

量化網格改變了骨骼的靜止姿勢,讓每個空中動作都下沉;嚴格的主機也擋下了 WebAssembly 解碼器。請重新試玩壓縮後的版本,並在主機的 CSP 規則下測試。

做你自己的遊戲

把這段貼進你的 coding agent

在 Claude Code 或 Codex 開啟一個空資料夾,把提示詞貼進去。它會先問 5 個問題,再一個階段一個階段做下去,每個階段結束都會停下來讓你試玩。

提示詞
Help me make a small 3D browser game, step by step. I have never made a game before.

Before you write any code, ask me up to 5 short questions in one message: what the game is about, the one thing the player does, keyboard or phone or both, the art style, and anything I already have. Wait for my answers.

Once I have answered, start a git repository, save this whole prompt word for word to AGENTS.md, and add a CLAUDE.md that only says to read AGENTS.md. Keep a short PROGRESS.md: what is done, what we decided and what is next. Read both at the start of every stage, and commit at the end of every stage that works, so we can go back if a later change breaks something; each time, tell me the one command that takes us back to it.

Then work in stages. Stop at the end of every stage, tell me how to try it, and wait for my feedback:

1. Design — write GDD.md, one page: core loop, controls (keyboard and touch), win and lose, camera, and a table of every object on screen with an id, its size in metres and which way it faces. Keep it to one level and one core loop. Make up your own characters, names and level layout; do not copy any existing game, and do not make anything look like a well-known game character or item either. For every character that animates, list its states (for example idle, run, attack, hurt, knocked down) and when it switches between them, and say whether it is a person or another kind of body (an animal, a robot dog, a bug); only people get bones, so a body that is not a person is built from parts that move in code. If characters fight, write for each attack: which animation it uses, how much damage it does, and at what fraction of the animation the hit lands and ends. If a machine or object has parts that move, can be shot off or break apart, list its parts: what each part does, where it hinges, how much it can take, and what changes when it breaks. If parts can be swapped between machines or characters, give all of them the same set of slots, and for each slot write one attach point (where it sits, measured from the centre of the feet) and which way a part faces on that point.

2. Greybox — build it with Three.js and Vite, no game engine. Use only boxes, cylinders and capsules, sized from the table. Keep everything about how objects look in one place: a registry from id to a builder function, so a 3D model can replace any placeholder later without touching gameplay code. Build an object with parts as a group of named child placeholders, one per part, each turning around its own hinge, and let gameplay find parts by name. If parts can be swapped, hang each swappable part on a named attach point; swapping a part means hanging another part on that point and scaling it to fit the slot, and gameplay still finds parts by name. Every placeholder faces +Z. If the player jumps, make it feel good: a jump pressed just before landing still counts, a jump just after walking off a ledge still works, and holding the button jumps higher. If the player fights, make it feel good: a button pressed during an attack queues the next one, a hit freezes both fighters for a split second and pushes the target back, a character that was just hit cannot be hit again at once, and enemies take turns attacking instead of all at once. Show states on the placeholders (a colour or a lean) so I can see them. Put every number I might want to tune (speeds, sizes, camera, timings) in one config file, and add a hidden debug panel, opened with a key, with sliders for those numbers and readouts of FPS, draw calls, bounding boxes and each character's current state. Moving characters must look smooth on both 60 Hz and 120 Hz screens. Done when I can play a full round and restart, on desktop and on a phone. If a later change adds a new state, add it to GDD.md and tell me which animation it needs.

3. Asset list — write assets.json with one entry per id: its kind (prop, person or parts), size in metres (height for people, longest edge for everything else), a polygon budget in triangles (at least 500; at least 10000 for parts), and one English image prompt. Give every prompt the same art-style sentence, describe the shape and proportions it must have to fit its size, give visible details to the side the camera sees most (for a vehicle the player follows, its back) while still asking for one view of one object, and end it with "single isolated object, centered, on a plain white background". The ground, sky and edge of the level are part of the look too: say how each will be made (a Tripo entry or built in code), so none of them stays greybox. At most 8 entries; if several enemies share a shape, they share one entry, and one that differs only in colour gets a texture prompt on that entry instead of a new entry. A texture prompt repaints the whole model, so describe the whole object with every colour, not "the same but red"; a prop in one plain colour is tinted in code instead.

   - A person that animates must stand in a T-pose, facing the camera, with its head no more than a third of its height, arms long enough to reach mid-thigh, a body no wider than its shoulders, space between the arms, legs and body, and nothing loose that would flap or stick out (scarves, long hair, bandana tails, capes). Give it a list of animations taken only from these names in the Tripo library: idle, walk, run, jump, jump_down, fall, box_01, box_02, box_03, front_kick_01, slash, shoot, hit_to_body_01, hit_to_head, defeat_02, cheer. The name is only a label, so pick by what the motion is: jump has a long crouch before take-off, jump_down is a drop through the air, fall is tripping over onto the ground, defeat_02 is being knocked down, and the attacks are much slower than a game needs.

      If no name fits, write a one-line description of the motion instead, starting with its name and a colon (for example "dodge: a small character rolls forward and gets back up"); this works for people only, and it is reliable for motions on the ground; a motion in mid-air often comes out standing. Anything that only spins, bobs, squashes or flashes is animated in code, not in Tripo. A person who stays seated (a driver, a rider) keeps its legs and hips posed in code and uses animations for the upper body only; Text to Motion does not make good seated poses.

   - An object with parts (a machine, an animal or robot animal, anything that breaks apart) is one model that Tripo will split. List its parts in plain words (for example "left_cannon", "armour_plate", "front_left_leg"), at most 10, and if parts can be swapped, say which slot each part fits. Write the image prompt so that any central body is clearly its own piece, and every part in one main colour of its own, with a gap between parts. Parts that walk or swing are moved in code at their hinges, not rigged.

   - Mark at most two entries as hero: the player's character or vehicle and the main enemy, the ones the camera stays close to. A hero's image prompt keeps its name, colours and art-style sentence and adds what it is made of (painted metal, knitted wool, rubber), small details (rivets, stitching, buckles), decals or wear, and detail on the side the camera sees most, described as part of one front view of a single figure; never ask for a back view or several views. A hero gets 10000 triangles for a person and 15000–20000 for a model with parts; keep a hero's parts list to 6 or fewer, because Tripo merges neighbouring parts and cannot reduce small pieces much.

   - If I want more looks for the game (for example a skin switch, or an elite enemy), give the entry up to 4 styles, each one of classic, Wood (dark old wood), another style Tripo Studio lists under Create Your Own Texture Style, or "own image: [a close-up swatch of the material: colours and surface, no creature or object]" if I will make my own style picture and upload it; or "none". Pick only styles that suit the art style, and tell me what each will look like. Each style costs one more texture generation in Tripo.

   Add up the triangles and texture memory for the busiest moment on screen and say whether a phone can handle it. A Tripo model that is not a hero has colour textures only: one at the chosen resolution, or one per piece for a split model, smaller for small pieces. A hero has three 4K textures (colour, normal and metal-rough), shared by all its pieces. Count a split model that is not a hero at 1.5 times its budget, because filling its gaps adds triangles.

4. Models — first ask me whether the Tripo MCP (https://studio.tripo3d.ai/mcp?from=vgh-prompt-agent) is connected in this session. If it is, make these entries yourself through it: every prop, every object with parts, and every hero or person that does not animate. Generate each one from its prompt and keep it within its polygon budget; for a hero, use the high-detail model and then reduce it to the budget. Before the first job, tell me roughly how many credits the list will cost and wait for my yes. Run one job at a time and wait until it finishes; a high-detail job can take ten minutes. Export GLB, save each file straight from the link the MCP returns (do not retype the link) into public/assets with the entry's file name, and check that it loads. If the MCP is not connected, or an entry fails twice, leave that entry to me.

   My turn — give me one table with a row per entry you did not make (people that animate always come to me, because the MCP cannot export their animations yet): id, kind, hero or not, prompt, polygon budget, file name, animations or parts, and styles or texture prompt (or "none"). Then tell me to make them in Tripo Studio (https://studio.tripo3d.ai/workspace/generate?from=vgh-prompt-agent) by following these steps, which cover every kind of entry, heroes, styles, colour versions and export: https://github.com/TripoGrowthLab/vibe-gaming-interactive-playbook/blob/main/prompt/tripo-studio-steps.md . Wait until I say they are in.

5. Swap — load each GLB in place of its placeholder (models made through the MCP are compressed with meshopt, so load them with the MeshoptDecoder): scale it to the size in the list (people by height), sit it on the ground, and add an environment map so materials are not black. Keep every map a model comes with (colour, normal, metal-rough) and its metal and roughness values; only a model with a colour map alone gets roughness 1 and metalness 0. Render every model next to its placeholder and check it faces the same way; rotate it if it does not. Do this again whenever a model is replaced: a new version can face another way and has new UVs, so its style and colour files must be made again from it. First list what is really inside each file: animation names (Tripo often renames them: defeat_02 can come out as defeat_03, and a Text to Motion clip is named after the start of its description) and, for split models, every piece with its name, size and position. Match animations by the closest name. Match pieces by name first; a piece still called tripo_part_N belongs to a part only if its centre sits inside that part's placeholder, and to the body otherwise, so group them in code; print the pieces of each part and check them on a render before you move any hinge. The sizes stored in the file are not reliable, so recompute each bounding box before you measure anything. The order of meshes changes from file to file, so always match pieces by node name. Tell me what you matched and what is missing. Every piece keeps the whole model's origin: move each part's pivot to its hinge before you turn it, and since a few pieces may still have small holes, make sure nothing looks see-through when a part comes off (close it, show both sides, or put something dark behind it). Merge the pieces of each part into one mesh when they share one material (a hero with parts comes that way) or when draw calls hurt on a phone. If parts can be swapped between machines, line up where each part joins with its slot's attach point and scale it to fit the slot. When a swapped part has a different height, such as another machine's legs, seat everything above it on the new part's real height and hinges, not the old part's or the placeholder's, so nothing floats or sinks. If an entry has style versions, they have the same shape, but Tripo can change their UVs: compare each style's UVs with the default file's, and where they differ, use that style file's own mesh with its textures, cut into the same parts or bound to the same skeleton. List which maps each style file has; a style may come without a metal-rough map. Look at each version and tell me if one does not match its prompt, and add a button that switches skins, loading each style only the first time it is chosen. Never pair the shape data of one file with another file. Put a close-up of each model in the game next to how it looks in Tripo Studio; if colours look washed out or flat, fix the lighting (one main light that casts shadows, less flat ambient light, the right colour space), not the textures.

   Look at the frames of every animation before you use it: pick the part you need, find the moment a punch or kick really lands, and check arms and feet do not go through the body or clothes. Tripo animations are the same for every body shape, so on a character with a big head, a round belly or thick clothes the arms often sink into the hips or chest when they hang down and pass through the head when they go up. Measure this in code instead of judging it from small frames: in every frame of every animation, work out where the arm vertices really are and test whether they are inside the rest of the body (a winding-number test stays right on clothes and open meshes), using the T-pose as zero. Also look at close-ups from the front and from a 3/4 angle, including the armpits. If an arm goes in, fix it in code: after each animation frame, turn the upper arm outward at the shoulder just enough to clear the body (hips, belly, chest and head); ignore a few millimetres of sleeve resting on clothes, and never change a pose where the hands are meant to touch the body (pockets, hips). Tell me the worst depth for every animation before and after the fix.

   Play character animations by name with an AnimationMixer, blending between states, and keep the character in place so only gameplay code moves it: "stay in place" can still leave the body ahead of or behind its feet, so check the hips over the whole clip and centre them. Match walk and run playback speed to how fast the character really moves so the feet do not slide. If a character must do two things at once (run and shoot), play the legs from one animation and the upper body from another: the legs always face where it runs, the upper body twists toward the aim, and it backpedals when aiming behind. When one model is used by several characters at once, clone it with SkeletonUtils so each has its own skeleton. Check where characters stop and touch things using the models' real sizes, not the placeholders', colliding with simple shapes that follow each model's visible surface (a capsule for every character; for a rounded top, step it down and keep it inside the visible edge, so no one stands in the air) and never with a model's mesh itself; fit the shapes to the models, never stretch a model unevenly to fit an old shape, and measure every frame of a crash or knockdown so no character ends up inside what it hit. On a phone held upright, measure over a full round how much of the screen height the player takes up and how much of the screen is empty sky or background, and tell me the smallest and largest of each. Keep a button that switches between greybox and models. The colour tints and white hit flashes that showed states on the placeholders wash out painted models, so on models glow only the part that matters and brighten its own colours instead of adding white; then check that a landed hit is still easy to see and hear (a flash or sparks at the spot, a jolt of the part, a sound). Effects that shake a part must not move the point used for hit detection. Do not change gameplay code, not even to fix a bug; if timings, sizes or triggers need new numbers, tell me what and why, and wait for my yes. Tell me which files, animations or pieces did not load and why.

6. Publish — as a build step, shrink every GLB with glTF Transform (meshopt geometry, WebP textures no larger than they ever appear on screen) and load them with the matching decoders, leaving the files in public/assets as they are. Play a full round on the small files to check that every animation, piece and style still works. Compression changes a rigged model's bind matrices, so play every animation on both the small and the original files and compare how high the feet sit above the ground; anything measured from the bind pose (such as skeleton.pose()) should use the bones' own starting positions instead. Then tell me the total download size and how long the first screen takes to appear on a phone. Then help me put it on a free static host and give me the link. Ask me before you create any account, repository or public page.

Test your own work before you hand it to me: run the build, open the game, check the console for errors, and tell me exactly what you checked. If the game has fights or levels, write a small bot that plays a full round and report what it hit and whether it won, and a second one that plays badly (holds forward into walls and obstacles) to check nothing gets stuck. Wait for every test to finish before you reply; never start a test with & or in the background. Use only a browser that is already installed on this machine; never download one. If you cannot test something, tell me what to try myself. If something does not work, say so.
在 GitHub 上查看
Pell · 三套造型

為你自己的遊戲做模型

描述一個角色或丟一張圖片進去,Tripo Studio 就會給你可以直接放進遊戲的模型;需要動的話,也會綁好骨架、套好動畫。新帳號有免費點數。

免費做出你的第一個模型 ↗
或跟著六個階段的教學做 →