diff --git a/mirai-core/src/commonMain/kotlin/network/notice/priv/FriendNoticeProcessor.kt b/mirai-core/src/commonMain/kotlin/network/notice/priv/FriendNoticeProcessor.kt index 99e3c00f9..5763f6bb9 100644 --- a/mirai-core/src/commonMain/kotlin/network/notice/priv/FriendNoticeProcessor.kt +++ b/mirai-core/src/commonMain/kotlin/network/notice/priv/FriendNoticeProcessor.kt @@ -102,10 +102,12 @@ internal class FriendNoticeProcessor( val body: SubMsgType0xb3.MsgBody = vProtobuf.loadAs(SubMsgType0xb3.MsgBody.serializer()) handleFriendAddedB(data, body) } + 0x44L -> { val body = vProtobuf.loadAs(Submsgtype0x44.MsgBody.serializer()) handleFriendAddedA(body) } + 0x27L -> { val body = vProtobuf.loadAs(SubMsgType0x27MsgBody.serializer()) for (msgModInfo in body.msgModInfos) { @@ -117,10 +119,12 @@ internal class FriendNoticeProcessor( } } } + 0x115L -> { val body = vProtobuf.loadAs(SubMsgType0x115.MsgBody.serializer()) handleInputStatusChanged(body) } + 0x122L -> { val body = vProtobuf.loadAs(Submsgtype0x122.Submsgtype0x122.MsgBody.serializer()) when (body.templId) { @@ -128,10 +132,12 @@ internal class FriendNoticeProcessor( 1132L, 1133L, 1134L, 1135L, 1136L, 10043L -> handlePrivateNudge(body) } } + 0x8AL -> { val body = vProtobuf.loadAs(Sub8A.serializer()) processFriendRecall(body) } + else -> markNotConsumed() } } @@ -150,12 +156,13 @@ internal class FriendNoticeProcessor( @ProtoNumber(3) val srcId: Int, @ProtoNumber(4) val srcInternalId: Long, @ProtoNumber(5) val time: Long, - @ProtoNumber(6) val random: Int, - @ProtoNumber(7) val pkgNum: Int, // 1 - @ProtoNumber(8) val pkgIndex: Int, // 0 - @ProtoNumber(9) val devSeq: Int, // 0 - @ProtoNumber(12) val flag: Int, // 1 - @ProtoNumber(13) val wording: Wording, + // see #2784 +// @ProtoNumber(6) val random: Int, +// @ProtoNumber(7) val pkgNum: Int, // 1 +// @ProtoNumber(8) val pkgIndex: Int, // 0 +// @ProtoNumber(9) val devSeq: Int, // 0 +// @ProtoNumber(12) val flag: Int, // 1 +// @ProtoNumber(13) val wording: Wording, ) : ProtoBuf @Serializable @@ -207,6 +214,7 @@ internal class FriendNoticeProcessor( friend.info.nick = to } } + else -> containsUnknown = true } }