guansss / pixi-live2d-display

A PixiJS plugin to display Live2D models of any kind.
https://guansss.github.io/pixi-live2d-display/
MIT License
898 stars 137 forks source link

如何在call model.motion的时候保留现有的expression #69

Closed randysu closed 2 years ago

randysu commented 2 years ago

大佬您好,我在live2d viewer当中play motion时会保留现有的表情(expression),但是本库在唤起model.motion的时候会把表情覆盖为默认然后再播放 motion

guansss commented 2 years ago

目前可以通过覆盖 MotionState#shouldOverrideExpression 并始终返回 false 来实现,下个版本我会加一个选项来控制该行为

randysu commented 2 years ago

谢谢大佬,我试试自己改Typescript build 一下

guansss commented 2 years ago

0.4.0-beta.2 已默认禁用该行为,如有需要可通过 config.preserveExpressionOnMotion = false 来重新开启