Repository navigation
[Core] Support receiving face - #926
Merged
Merged
Conversation
[Milky] Implement face incoming segment
NoirHare
approved these changes
Nov 6, 2026
Collaborator
|
thx. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题
收到 QQ 自带表情(小黄脸、超级表情)时,Milky 拿不到这个表情。只有一个表情的消息会变成一条没有任何消息段的空消息。
Milky 协议定义了
face接收段,但MilkyConverter里是// TODO: face is not implemented in core。修改
Core
Elem增加 field 2Face。QSmallFaceExtra和QBigFaceExtra,分别是CommonElem33 和 37 的PbElem,只声明了用到的FaceId。FaceEntity,只用于接收(Build抛出NotSupportedException),包含FaceId和IsLarge。解析以下三种元素:Face:普通表情;CommonElem33:新版小表情;CommonElem37:超级表情,IsLarge = true。[xxx]请使用最新版手机QQ体验新功能)放在Text的PbReserve里,TextEntity本来就不解析,所以不会多出 text 段。解析方式与 V1 的
FaceEntity一致。Milky
face接收段(FaceIncomingSegment),字段与 Milky 协议一致:face_idis_largeface标记为已实现。测试
在 linux-x64 构建(trimmed,非 AOT)上,在群聊里接收表情:
Face)与文字混在一起时,得到face段,is_large为false,前后的文字段不受影响;CommonElem33)得到face段,is_large为false,一条消息里的两个表情都能收到;CommonElem37)得到face段,is_large为true,不会多出 text 段。