Bust portraits for dialogue, generated once at build time: a neutral base per character, then each expression as an edit of that base with the base as the reference image, aligned onto one canvas so only the face changes. In the game the speaker slides in beside the box, cross-fades between expressions on each line's expr tag, breathes, blinks, and dims while someone else talks. Same hooks as the D-04 pixel portraits, so the H-01 dialogue box drives either.
Click the scene (or press Z) to advance when Advance is set to manual. Every line carries {speaker, expr, text}; nothing else drives the faces.
Each row is one neutral base and six edits of it (the blink is used only on the neutral face). Numbers under each file are the alignment check (assetcheck.py portrait-set): silhouette overlap with the base at zero offset and the best shift within ±6 px. A 0,0 shift means the bust does not jump when the images are swapped.
1. The base is generated from a role prompt plus the STYLE LOCK paragraph (no reference). The other two bases pass the first one as the reference so the cast shares brushwork, light and crop.
2. Each expression is an edit of its base (the base passed in referenced_image_paths):
Edit the referenced portrait: change ONLY the facial expression to <expression>. Keep the identical person, face shape, skin, hair, every mark, clothing and accessories, the same head angle and gaze direction, the same pose, position, size and crop on the canvas …
3. portraitset.py build registers every edit onto its base by silhouette (scale ± 7 %, shift ± 96 px), cuts the whole set with one crop box and one flat bottom line, resizes, binarises the alpha and exports WebP. The edits re-render the whole picture, so the game swaps whole images; it never pastes only a face.