tiktok-live-proto 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2489 @@
1
+ import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
+ //#region src/generated/node/v1/tiktok-schema.ts
3
+ const protobufPackage = "TikTok";
4
+ let ControlAction = /* @__PURE__ */ function(ControlAction) {
5
+ ControlAction[ControlAction["CONTROL_ACTION_FALLBACK_UNKNOWN"] = 0] = "CONTROL_ACTION_FALLBACK_UNKNOWN";
6
+ ControlAction[ControlAction["CONTROL_ACTION_STREAM_PAUSED"] = 1] = "CONTROL_ACTION_STREAM_PAUSED";
7
+ ControlAction[ControlAction["CONTROL_ACTION_STREAM_UNPAUSED"] = 2] = "CONTROL_ACTION_STREAM_UNPAUSED";
8
+ ControlAction[ControlAction["CONTROL_ACTION_STREAM_ENDED"] = 3] = "CONTROL_ACTION_STREAM_ENDED";
9
+ ControlAction[ControlAction["CONTROL_ACTION_STREAM_SUSPENDED"] = 4] = "CONTROL_ACTION_STREAM_SUSPENDED";
10
+ ControlAction[ControlAction["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
11
+ return ControlAction;
12
+ }({});
13
+ let WebcastChatMessage_CommentTag = /* @__PURE__ */ function(WebcastChatMessage_CommentTag) {
14
+ WebcastChatMessage_CommentTag[WebcastChatMessage_CommentTag["COMMENT_TAG_NORMAL"] = 0] = "COMMENT_TAG_NORMAL";
15
+ WebcastChatMessage_CommentTag[WebcastChatMessage_CommentTag["COMMENT_TAG_CANDIDATE"] = 1] = "COMMENT_TAG_CANDIDATE";
16
+ WebcastChatMessage_CommentTag[WebcastChatMessage_CommentTag["COMMENT_TAG_OVERAGE"] = 2] = "COMMENT_TAG_OVERAGE";
17
+ WebcastChatMessage_CommentTag[WebcastChatMessage_CommentTag["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
18
+ return WebcastChatMessage_CommentTag;
19
+ }({});
20
+ let EmoteUploadInfo_UserEmoteUploadSource = /* @__PURE__ */ function(EmoteUploadInfo_UserEmoteUploadSource) {
21
+ EmoteUploadInfo_UserEmoteUploadSource[EmoteUploadInfo_UserEmoteUploadSource["USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_ANCHOR"] = 0] = "USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_ANCHOR";
22
+ EmoteUploadInfo_UserEmoteUploadSource[EmoteUploadInfo_UserEmoteUploadSource["USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_SUBSCRIBER"] = 1] = "USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_SUBSCRIBER";
23
+ EmoteUploadInfo_UserEmoteUploadSource[EmoteUploadInfo_UserEmoteUploadSource["USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_MODERATOR"] = 2] = "USER_EMOTE_UPLOAD_SOURCE_EMOTE_UPLOAD_SOURCE_MODERATOR";
24
+ EmoteUploadInfo_UserEmoteUploadSource[EmoteUploadInfo_UserEmoteUploadSource["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
25
+ return EmoteUploadInfo_UserEmoteUploadSource;
26
+ }({});
27
+ function createBaseWebcastResponse() {
28
+ return {
29
+ messages: [],
30
+ cursor: "",
31
+ fetchInterval: 0,
32
+ serverTimestamp: "0",
33
+ internalExt: "",
34
+ fetchType: 0,
35
+ wsParams: [],
36
+ heartbeatDuration: 0,
37
+ needAck: false,
38
+ wsUrl: ""
39
+ };
40
+ }
41
+ const WebcastResponse = {
42
+ encode(message, writer = new BinaryWriter()) {
43
+ for (const v of message.messages) Message.encode(v, writer.uint32(10).fork()).join();
44
+ if (message.cursor !== "") writer.uint32(18).string(message.cursor);
45
+ if (message.fetchInterval !== 0) writer.uint32(24).int32(message.fetchInterval);
46
+ if (message.serverTimestamp !== "0") writer.uint32(32).int64(message.serverTimestamp);
47
+ if (message.internalExt !== "") writer.uint32(42).string(message.internalExt);
48
+ if (message.fetchType !== 0) writer.uint32(48).int32(message.fetchType);
49
+ for (const v of message.wsParams) WebsocketParam.encode(v, writer.uint32(58).fork()).join();
50
+ if (message.heartbeatDuration !== 0) writer.uint32(64).int32(message.heartbeatDuration);
51
+ if (message.needAck !== false) writer.uint32(72).bool(message.needAck);
52
+ if (message.wsUrl !== "") writer.uint32(82).string(message.wsUrl);
53
+ return writer;
54
+ },
55
+ decode(input, length) {
56
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
57
+ const end = length === void 0 ? reader.len : reader.pos + length;
58
+ const message = createBaseWebcastResponse();
59
+ while (reader.pos < end) {
60
+ const tag = reader.uint32();
61
+ switch (tag >>> 3) {
62
+ case 1:
63
+ if (tag !== 10) break;
64
+ message.messages.push(Message.decode(reader, reader.uint32()));
65
+ continue;
66
+ case 2:
67
+ if (tag !== 18) break;
68
+ message.cursor = reader.string();
69
+ continue;
70
+ case 3:
71
+ if (tag !== 24) break;
72
+ message.fetchInterval = reader.int32();
73
+ continue;
74
+ case 4:
75
+ if (tag !== 32) break;
76
+ message.serverTimestamp = reader.int64().toString();
77
+ continue;
78
+ case 5:
79
+ if (tag !== 42) break;
80
+ message.internalExt = reader.string();
81
+ continue;
82
+ case 6:
83
+ if (tag !== 48) break;
84
+ message.fetchType = reader.int32();
85
+ continue;
86
+ case 7:
87
+ if (tag !== 58) break;
88
+ message.wsParams.push(WebsocketParam.decode(reader, reader.uint32()));
89
+ continue;
90
+ case 8:
91
+ if (tag !== 64) break;
92
+ message.heartbeatDuration = reader.int32();
93
+ continue;
94
+ case 9:
95
+ if (tag !== 72) break;
96
+ message.needAck = reader.bool();
97
+ continue;
98
+ case 10:
99
+ if (tag !== 82) break;
100
+ message.wsUrl = reader.string();
101
+ continue;
102
+ }
103
+ if ((tag & 7) === 4 || tag === 0) break;
104
+ reader.skip(tag & 7);
105
+ }
106
+ return message;
107
+ }
108
+ };
109
+ function createBaseMessage() {
110
+ return {
111
+ type: "",
112
+ binary: Buffer.alloc(0)
113
+ };
114
+ }
115
+ const Message = {
116
+ encode(message, writer = new BinaryWriter()) {
117
+ if (message.type !== "") writer.uint32(10).string(message.type);
118
+ if (message.binary.length !== 0) writer.uint32(18).bytes(message.binary);
119
+ return writer;
120
+ },
121
+ decode(input, length) {
122
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
123
+ const end = length === void 0 ? reader.len : reader.pos + length;
124
+ const message = createBaseMessage();
125
+ while (reader.pos < end) {
126
+ const tag = reader.uint32();
127
+ switch (tag >>> 3) {
128
+ case 1:
129
+ if (tag !== 10) break;
130
+ message.type = reader.string();
131
+ continue;
132
+ case 2:
133
+ if (tag !== 18) break;
134
+ message.binary = Buffer.from(reader.bytes());
135
+ continue;
136
+ }
137
+ if ((tag & 7) === 4 || tag === 0) break;
138
+ reader.skip(tag & 7);
139
+ }
140
+ return message;
141
+ }
142
+ };
143
+ function createBaseWebsocketParam() {
144
+ return {
145
+ name: "",
146
+ value: ""
147
+ };
148
+ }
149
+ const WebsocketParam = {
150
+ encode(message, writer = new BinaryWriter()) {
151
+ if (message.name !== "") writer.uint32(10).string(message.name);
152
+ if (message.value !== "") writer.uint32(18).string(message.value);
153
+ return writer;
154
+ },
155
+ decode(input, length) {
156
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
157
+ const end = length === void 0 ? reader.len : reader.pos + length;
158
+ const message = createBaseWebsocketParam();
159
+ while (reader.pos < end) {
160
+ const tag = reader.uint32();
161
+ switch (tag >>> 3) {
162
+ case 1:
163
+ if (tag !== 10) break;
164
+ message.name = reader.string();
165
+ continue;
166
+ case 2:
167
+ if (tag !== 18) break;
168
+ message.value = reader.string();
169
+ continue;
170
+ }
171
+ if ((tag & 7) === 4 || tag === 0) break;
172
+ reader.skip(tag & 7);
173
+ }
174
+ return message;
175
+ }
176
+ };
177
+ function createBaseWebcastControlMessage() {
178
+ return { action: 0 };
179
+ }
180
+ const WebcastControlMessage = {
181
+ encode(message, writer = new BinaryWriter()) {
182
+ if (message.action !== 0) writer.uint32(16).int32(message.action);
183
+ return writer;
184
+ },
185
+ decode(input, length) {
186
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
187
+ const end = length === void 0 ? reader.len : reader.pos + length;
188
+ const message = createBaseWebcastControlMessage();
189
+ while (reader.pos < end) {
190
+ const tag = reader.uint32();
191
+ switch (tag >>> 3) {
192
+ case 2:
193
+ if (tag !== 16) break;
194
+ message.action = reader.int32();
195
+ continue;
196
+ }
197
+ if ((tag & 7) === 4 || tag === 0) break;
198
+ reader.skip(tag & 7);
199
+ }
200
+ return message;
201
+ }
202
+ };
203
+ function createBaseWebcastRoomUserSeqMessage() {
204
+ return {
205
+ topViewers: [],
206
+ viewerCount: 0
207
+ };
208
+ }
209
+ const WebcastRoomUserSeqMessage = {
210
+ encode(message, writer = new BinaryWriter()) {
211
+ for (const v of message.topViewers) TopUser.encode(v, writer.uint32(18).fork()).join();
212
+ if (message.viewerCount !== 0) writer.uint32(24).int32(message.viewerCount);
213
+ return writer;
214
+ },
215
+ decode(input, length) {
216
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
217
+ const end = length === void 0 ? reader.len : reader.pos + length;
218
+ const message = createBaseWebcastRoomUserSeqMessage();
219
+ while (reader.pos < end) {
220
+ const tag = reader.uint32();
221
+ switch (tag >>> 3) {
222
+ case 2:
223
+ if (tag !== 18) break;
224
+ message.topViewers.push(TopUser.decode(reader, reader.uint32()));
225
+ continue;
226
+ case 3:
227
+ if (tag !== 24) break;
228
+ message.viewerCount = reader.int32();
229
+ continue;
230
+ }
231
+ if ((tag & 7) === 4 || tag === 0) break;
232
+ reader.skip(tag & 7);
233
+ }
234
+ return message;
235
+ }
236
+ };
237
+ function createBaseTopUser() {
238
+ return {
239
+ coinCount: "0",
240
+ user: void 0
241
+ };
242
+ }
243
+ const TopUser = {
244
+ encode(message, writer = new BinaryWriter()) {
245
+ if (message.coinCount !== "0") writer.uint32(8).uint64(message.coinCount);
246
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
247
+ return writer;
248
+ },
249
+ decode(input, length) {
250
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
251
+ const end = length === void 0 ? reader.len : reader.pos + length;
252
+ const message = createBaseTopUser();
253
+ while (reader.pos < end) {
254
+ const tag = reader.uint32();
255
+ switch (tag >>> 3) {
256
+ case 1:
257
+ if (tag !== 8) break;
258
+ message.coinCount = reader.uint64().toString();
259
+ continue;
260
+ case 2:
261
+ if (tag !== 18) break;
262
+ message.user = User.decode(reader, reader.uint32());
263
+ continue;
264
+ }
265
+ if ((tag & 7) === 4 || tag === 0) break;
266
+ reader.skip(tag & 7);
267
+ }
268
+ return message;
269
+ }
270
+ };
271
+ function createBaseImageModel() {
272
+ return {
273
+ mUrls: [],
274
+ mUri: "",
275
+ height: 0,
276
+ width: 0,
277
+ avgColor: "",
278
+ imageType: 0,
279
+ schema: "",
280
+ content: void 0,
281
+ isAnimated: false
282
+ };
283
+ }
284
+ const ImageModel = {
285
+ encode(message, writer = new BinaryWriter()) {
286
+ for (const v of message.mUrls) writer.uint32(10).string(v);
287
+ if (message.mUri !== "") writer.uint32(18).string(message.mUri);
288
+ if (message.height !== 0) writer.uint32(24).int32(message.height);
289
+ if (message.width !== 0) writer.uint32(32).int32(message.width);
290
+ if (message.avgColor !== "") writer.uint32(42).string(message.avgColor);
291
+ if (message.imageType !== 0) writer.uint32(48).int32(message.imageType);
292
+ if (message.schema !== "") writer.uint32(58).string(message.schema);
293
+ if (message.content !== void 0) ImageModel_Content.encode(message.content, writer.uint32(66).fork()).join();
294
+ if (message.isAnimated !== false) writer.uint32(72).bool(message.isAnimated);
295
+ return writer;
296
+ },
297
+ decode(input, length) {
298
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
299
+ const end = length === void 0 ? reader.len : reader.pos + length;
300
+ const message = createBaseImageModel();
301
+ while (reader.pos < end) {
302
+ const tag = reader.uint32();
303
+ switch (tag >>> 3) {
304
+ case 1:
305
+ if (tag !== 10) break;
306
+ message.mUrls.push(reader.string());
307
+ continue;
308
+ case 2:
309
+ if (tag !== 18) break;
310
+ message.mUri = reader.string();
311
+ continue;
312
+ case 3:
313
+ if (tag !== 24) break;
314
+ message.height = reader.int32();
315
+ continue;
316
+ case 4:
317
+ if (tag !== 32) break;
318
+ message.width = reader.int32();
319
+ continue;
320
+ case 5:
321
+ if (tag !== 42) break;
322
+ message.avgColor = reader.string();
323
+ continue;
324
+ case 6:
325
+ if (tag !== 48) break;
326
+ message.imageType = reader.int32();
327
+ continue;
328
+ case 7:
329
+ if (tag !== 58) break;
330
+ message.schema = reader.string();
331
+ continue;
332
+ case 8:
333
+ if (tag !== 66) break;
334
+ message.content = ImageModel_Content.decode(reader, reader.uint32());
335
+ continue;
336
+ case 9:
337
+ if (tag !== 72) break;
338
+ message.isAnimated = reader.bool();
339
+ continue;
340
+ }
341
+ if ((tag & 7) === 4 || tag === 0) break;
342
+ reader.skip(tag & 7);
343
+ }
344
+ return message;
345
+ }
346
+ };
347
+ function createBaseImageModel_Content() {
348
+ return {
349
+ name: "",
350
+ fontColor: "",
351
+ level: "0"
352
+ };
353
+ }
354
+ const ImageModel_Content = {
355
+ encode(message, writer = new BinaryWriter()) {
356
+ if (message.name !== "") writer.uint32(10).string(message.name);
357
+ if (message.fontColor !== "") writer.uint32(18).string(message.fontColor);
358
+ if (message.level !== "0") writer.uint32(24).int64(message.level);
359
+ return writer;
360
+ },
361
+ decode(input, length) {
362
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
363
+ const end = length === void 0 ? reader.len : reader.pos + length;
364
+ const message = createBaseImageModel_Content();
365
+ while (reader.pos < end) {
366
+ const tag = reader.uint32();
367
+ switch (tag >>> 3) {
368
+ case 1:
369
+ if (tag !== 10) break;
370
+ message.name = reader.string();
371
+ continue;
372
+ case 2:
373
+ if (tag !== 18) break;
374
+ message.fontColor = reader.string();
375
+ continue;
376
+ case 3:
377
+ if (tag !== 24) break;
378
+ message.level = reader.int64().toString();
379
+ continue;
380
+ }
381
+ if ((tag & 7) === 4 || tag === 0) break;
382
+ reader.skip(tag & 7);
383
+ }
384
+ return message;
385
+ }
386
+ };
387
+ function createBaseWebcastChatMessage() {
388
+ return {
389
+ event: void 0,
390
+ user: void 0,
391
+ comment: "",
392
+ visibleToSender: false,
393
+ background: void 0,
394
+ fullScreenTextColor: "",
395
+ backgroundImageV2: void 0,
396
+ giftImage: void 0,
397
+ inputType: 0,
398
+ atUser: void 0,
399
+ emotes: [],
400
+ contentLanguage: "",
401
+ quickChatScene: 0,
402
+ communityflaggedStatus: 0,
403
+ commentQualityScores: [],
404
+ userIdentity: void 0,
405
+ commentTag: [],
406
+ screenTime: "0",
407
+ signature: "",
408
+ signatureVersion: "",
409
+ ecStreamerKey: ""
410
+ };
411
+ }
412
+ const WebcastChatMessage = {
413
+ encode(message, writer = new BinaryWriter()) {
414
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
415
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
416
+ if (message.comment !== "") writer.uint32(26).string(message.comment);
417
+ if (message.visibleToSender !== false) writer.uint32(32).bool(message.visibleToSender);
418
+ if (message.background !== void 0) ImageModel.encode(message.background, writer.uint32(42).fork()).join();
419
+ if (message.fullScreenTextColor !== "") writer.uint32(50).string(message.fullScreenTextColor);
420
+ if (message.backgroundImageV2 !== void 0) ImageModel.encode(message.backgroundImageV2, writer.uint32(58).fork()).join();
421
+ if (message.giftImage !== void 0) ImageModel.encode(message.giftImage, writer.uint32(82).fork()).join();
422
+ if (message.inputType !== 0) writer.uint32(88).int32(message.inputType);
423
+ if (message.atUser !== void 0) User.encode(message.atUser, writer.uint32(98).fork()).join();
424
+ for (const v of message.emotes) WebcastSubEmote.encode(v, writer.uint32(106).fork()).join();
425
+ if (message.contentLanguage !== "") writer.uint32(114).string(message.contentLanguage);
426
+ if (message.quickChatScene !== 0) writer.uint32(128).int32(message.quickChatScene);
427
+ if (message.communityflaggedStatus !== 0) writer.uint32(136).int32(message.communityflaggedStatus);
428
+ for (const v of message.commentQualityScores) WebcastChatMessage_CommentQualityScore.encode(v, writer.uint32(154).fork()).join();
429
+ if (message.userIdentity !== void 0) WebcastChatMessage_UserIdentity.encode(message.userIdentity, writer.uint32(146).fork()).join();
430
+ writer.uint32(162).fork();
431
+ for (const v of message.commentTag) writer.int32(v);
432
+ writer.join();
433
+ if (message.screenTime !== "0") writer.uint32(176).int64(message.screenTime);
434
+ if (message.signature !== "") writer.uint32(186).string(message.signature);
435
+ if (message.signatureVersion !== "") writer.uint32(194).string(message.signatureVersion);
436
+ if (message.ecStreamerKey !== "") writer.uint32(202).string(message.ecStreamerKey);
437
+ return writer;
438
+ },
439
+ decode(input, length) {
440
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
441
+ const end = length === void 0 ? reader.len : reader.pos + length;
442
+ const message = createBaseWebcastChatMessage();
443
+ while (reader.pos < end) {
444
+ const tag = reader.uint32();
445
+ switch (tag >>> 3) {
446
+ case 1:
447
+ if (tag !== 10) break;
448
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
449
+ continue;
450
+ case 2:
451
+ if (tag !== 18) break;
452
+ message.user = User.decode(reader, reader.uint32());
453
+ continue;
454
+ case 3:
455
+ if (tag !== 26) break;
456
+ message.comment = reader.string();
457
+ continue;
458
+ case 4:
459
+ if (tag !== 32) break;
460
+ message.visibleToSender = reader.bool();
461
+ continue;
462
+ case 5:
463
+ if (tag !== 42) break;
464
+ message.background = ImageModel.decode(reader, reader.uint32());
465
+ continue;
466
+ case 6:
467
+ if (tag !== 50) break;
468
+ message.fullScreenTextColor = reader.string();
469
+ continue;
470
+ case 7:
471
+ if (tag !== 58) break;
472
+ message.backgroundImageV2 = ImageModel.decode(reader, reader.uint32());
473
+ continue;
474
+ case 10:
475
+ if (tag !== 82) break;
476
+ message.giftImage = ImageModel.decode(reader, reader.uint32());
477
+ continue;
478
+ case 11:
479
+ if (tag !== 88) break;
480
+ message.inputType = reader.int32();
481
+ continue;
482
+ case 12:
483
+ if (tag !== 98) break;
484
+ message.atUser = User.decode(reader, reader.uint32());
485
+ continue;
486
+ case 13:
487
+ if (tag !== 106) break;
488
+ message.emotes.push(WebcastSubEmote.decode(reader, reader.uint32()));
489
+ continue;
490
+ case 14:
491
+ if (tag !== 114) break;
492
+ message.contentLanguage = reader.string();
493
+ continue;
494
+ case 16:
495
+ if (tag !== 128) break;
496
+ message.quickChatScene = reader.int32();
497
+ continue;
498
+ case 17:
499
+ if (tag !== 136) break;
500
+ message.communityflaggedStatus = reader.int32();
501
+ continue;
502
+ case 19:
503
+ if (tag !== 154) break;
504
+ message.commentQualityScores.push(WebcastChatMessage_CommentQualityScore.decode(reader, reader.uint32()));
505
+ continue;
506
+ case 18:
507
+ if (tag !== 146) break;
508
+ message.userIdentity = WebcastChatMessage_UserIdentity.decode(reader, reader.uint32());
509
+ continue;
510
+ case 20:
511
+ if (tag === 160) {
512
+ message.commentTag.push(reader.int32());
513
+ continue;
514
+ }
515
+ if (tag === 162) {
516
+ const end2 = reader.uint32() + reader.pos;
517
+ while (reader.pos < end2) message.commentTag.push(reader.int32());
518
+ continue;
519
+ }
520
+ break;
521
+ case 22:
522
+ if (tag !== 176) break;
523
+ message.screenTime = reader.int64().toString();
524
+ continue;
525
+ case 23:
526
+ if (tag !== 186) break;
527
+ message.signature = reader.string();
528
+ continue;
529
+ case 24:
530
+ if (tag !== 194) break;
531
+ message.signatureVersion = reader.string();
532
+ continue;
533
+ case 25:
534
+ if (tag !== 202) break;
535
+ message.ecStreamerKey = reader.string();
536
+ continue;
537
+ }
538
+ if ((tag & 7) === 4 || tag === 0) break;
539
+ reader.skip(tag & 7);
540
+ }
541
+ return message;
542
+ }
543
+ };
544
+ function createBaseWebcastChatMessage_UserIdentity() {
545
+ return {
546
+ isGiftGiverOfAnchor: false,
547
+ isSubscriberOfAnchor: false,
548
+ isMutualFollowingWithAnchor: false,
549
+ isFollowerOfAnchor: false,
550
+ isModeratorOfAnchor: false,
551
+ isAnchor: false
552
+ };
553
+ }
554
+ const WebcastChatMessage_UserIdentity = {
555
+ encode(message, writer = new BinaryWriter()) {
556
+ if (message.isGiftGiverOfAnchor !== false) writer.uint32(8).bool(message.isGiftGiverOfAnchor);
557
+ if (message.isSubscriberOfAnchor !== false) writer.uint32(16).bool(message.isSubscriberOfAnchor);
558
+ if (message.isMutualFollowingWithAnchor !== false) writer.uint32(24).bool(message.isMutualFollowingWithAnchor);
559
+ if (message.isFollowerOfAnchor !== false) writer.uint32(32).bool(message.isFollowerOfAnchor);
560
+ if (message.isModeratorOfAnchor !== false) writer.uint32(40).bool(message.isModeratorOfAnchor);
561
+ if (message.isAnchor !== false) writer.uint32(48).bool(message.isAnchor);
562
+ return writer;
563
+ },
564
+ decode(input, length) {
565
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
566
+ const end = length === void 0 ? reader.len : reader.pos + length;
567
+ const message = createBaseWebcastChatMessage_UserIdentity();
568
+ while (reader.pos < end) {
569
+ const tag = reader.uint32();
570
+ switch (tag >>> 3) {
571
+ case 1:
572
+ if (tag !== 8) break;
573
+ message.isGiftGiverOfAnchor = reader.bool();
574
+ continue;
575
+ case 2:
576
+ if (tag !== 16) break;
577
+ message.isSubscriberOfAnchor = reader.bool();
578
+ continue;
579
+ case 3:
580
+ if (tag !== 24) break;
581
+ message.isMutualFollowingWithAnchor = reader.bool();
582
+ continue;
583
+ case 4:
584
+ if (tag !== 32) break;
585
+ message.isFollowerOfAnchor = reader.bool();
586
+ continue;
587
+ case 5:
588
+ if (tag !== 40) break;
589
+ message.isModeratorOfAnchor = reader.bool();
590
+ continue;
591
+ case 6:
592
+ if (tag !== 48) break;
593
+ message.isAnchor = reader.bool();
594
+ continue;
595
+ }
596
+ if ((tag & 7) === 4 || tag === 0) break;
597
+ reader.skip(tag & 7);
598
+ }
599
+ return message;
600
+ }
601
+ };
602
+ function createBaseWebcastChatMessage_CommentQualityScore() {
603
+ return {
604
+ version: "",
605
+ score: "0"
606
+ };
607
+ }
608
+ const WebcastChatMessage_CommentQualityScore = {
609
+ encode(message, writer = new BinaryWriter()) {
610
+ if (message.version !== "") writer.uint32(10).string(message.version);
611
+ if (message.score !== "0") writer.uint32(16).int64(message.score);
612
+ return writer;
613
+ },
614
+ decode(input, length) {
615
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
616
+ const end = length === void 0 ? reader.len : reader.pos + length;
617
+ const message = createBaseWebcastChatMessage_CommentQualityScore();
618
+ while (reader.pos < end) {
619
+ const tag = reader.uint32();
620
+ switch (tag >>> 3) {
621
+ case 1:
622
+ if (tag !== 10) break;
623
+ message.version = reader.string();
624
+ continue;
625
+ case 2:
626
+ if (tag !== 16) break;
627
+ message.score = reader.int64().toString();
628
+ continue;
629
+ }
630
+ if ((tag & 7) === 4 || tag === 0) break;
631
+ reader.skip(tag & 7);
632
+ }
633
+ return message;
634
+ }
635
+ };
636
+ function createBaseEmoteUploadInfo() {
637
+ return {
638
+ userId: "0",
639
+ emoteUploadSource: void 0,
640
+ userInfo: void 0,
641
+ userIdStr: ""
642
+ };
643
+ }
644
+ const EmoteUploadInfo = {
645
+ encode(message, writer = new BinaryWriter()) {
646
+ if (message.userId !== "0") writer.uint32(8).int64(message.userId);
647
+ if (message.emoteUploadSource !== void 0) writer.uint32(16).int32(message.emoteUploadSource);
648
+ if (message.userInfo !== void 0) User.encode(message.userInfo, writer.uint32(26).fork()).join();
649
+ if (message.userIdStr !== "") writer.uint32(34).string(message.userIdStr);
650
+ return writer;
651
+ },
652
+ decode(input, length) {
653
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
654
+ const end = length === void 0 ? reader.len : reader.pos + length;
655
+ const message = createBaseEmoteUploadInfo();
656
+ while (reader.pos < end) {
657
+ const tag = reader.uint32();
658
+ switch (tag >>> 3) {
659
+ case 1:
660
+ if (tag !== 8) break;
661
+ message.userId = reader.int64().toString();
662
+ continue;
663
+ case 2:
664
+ if (tag !== 16) break;
665
+ message.emoteUploadSource = reader.int32();
666
+ continue;
667
+ case 3:
668
+ if (tag !== 26) break;
669
+ message.userInfo = User.decode(reader, reader.uint32());
670
+ continue;
671
+ case 4:
672
+ if (tag !== 34) break;
673
+ message.userIdStr = reader.string();
674
+ continue;
675
+ }
676
+ if ((tag & 7) === 4 || tag === 0) break;
677
+ reader.skip(tag & 7);
678
+ }
679
+ return message;
680
+ }
681
+ };
682
+ function createBaseWebcastEmoteChatMessage() {
683
+ return {
684
+ user: void 0,
685
+ emote: void 0
686
+ };
687
+ }
688
+ const WebcastEmoteChatMessage = {
689
+ encode(message, writer = new BinaryWriter()) {
690
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
691
+ if (message.emote !== void 0) EmoteDetails.encode(message.emote, writer.uint32(26).fork()).join();
692
+ return writer;
693
+ },
694
+ decode(input, length) {
695
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
696
+ const end = length === void 0 ? reader.len : reader.pos + length;
697
+ const message = createBaseWebcastEmoteChatMessage();
698
+ while (reader.pos < end) {
699
+ const tag = reader.uint32();
700
+ switch (tag >>> 3) {
701
+ case 2:
702
+ if (tag !== 18) break;
703
+ message.user = User.decode(reader, reader.uint32());
704
+ continue;
705
+ case 3:
706
+ if (tag !== 26) break;
707
+ message.emote = EmoteDetails.decode(reader, reader.uint32());
708
+ continue;
709
+ }
710
+ if ((tag & 7) === 4 || tag === 0) break;
711
+ reader.skip(tag & 7);
712
+ }
713
+ return message;
714
+ }
715
+ };
716
+ function createBaseWebcastSubEmote() {
717
+ return {
718
+ placeInComment: 0,
719
+ emote: void 0
720
+ };
721
+ }
722
+ const WebcastSubEmote = {
723
+ encode(message, writer = new BinaryWriter()) {
724
+ if (message.placeInComment !== 0) writer.uint32(8).int32(message.placeInComment);
725
+ if (message.emote !== void 0) EmoteDetails.encode(message.emote, writer.uint32(18).fork()).join();
726
+ return writer;
727
+ },
728
+ decode(input, length) {
729
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
730
+ const end = length === void 0 ? reader.len : reader.pos + length;
731
+ const message = createBaseWebcastSubEmote();
732
+ while (reader.pos < end) {
733
+ const tag = reader.uint32();
734
+ switch (tag >>> 3) {
735
+ case 1:
736
+ if (tag !== 8) break;
737
+ message.placeInComment = reader.int32();
738
+ continue;
739
+ case 2:
740
+ if (tag !== 18) break;
741
+ message.emote = EmoteDetails.decode(reader, reader.uint32());
742
+ continue;
743
+ }
744
+ if ((tag & 7) === 4 || tag === 0) break;
745
+ reader.skip(tag & 7);
746
+ }
747
+ return message;
748
+ }
749
+ };
750
+ function createBaseWebcastMemberMessage() {
751
+ return {
752
+ event: void 0,
753
+ user: void 0,
754
+ actionId: 0
755
+ };
756
+ }
757
+ const WebcastMemberMessage = {
758
+ encode(message, writer = new BinaryWriter()) {
759
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
760
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
761
+ if (message.actionId !== 0) writer.uint32(80).int32(message.actionId);
762
+ return writer;
763
+ },
764
+ decode(input, length) {
765
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
766
+ const end = length === void 0 ? reader.len : reader.pos + length;
767
+ const message = createBaseWebcastMemberMessage();
768
+ while (reader.pos < end) {
769
+ const tag = reader.uint32();
770
+ switch (tag >>> 3) {
771
+ case 1:
772
+ if (tag !== 10) break;
773
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
774
+ continue;
775
+ case 2:
776
+ if (tag !== 18) break;
777
+ message.user = User.decode(reader, reader.uint32());
778
+ continue;
779
+ case 10:
780
+ if (tag !== 80) break;
781
+ message.actionId = reader.int32();
782
+ continue;
783
+ }
784
+ if ((tag & 7) === 4 || tag === 0) break;
785
+ reader.skip(tag & 7);
786
+ }
787
+ return message;
788
+ }
789
+ };
790
+ function createBaseWebcastGiftMessage() {
791
+ return {
792
+ event: void 0,
793
+ giftId: 0,
794
+ repeatCount: 0,
795
+ user: void 0,
796
+ repeatEnd: 0,
797
+ groupId: "0",
798
+ giftDetails: void 0,
799
+ monitorExtra: "",
800
+ giftExtra: void 0
801
+ };
802
+ }
803
+ const WebcastGiftMessage = {
804
+ encode(message, writer = new BinaryWriter()) {
805
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
806
+ if (message.giftId !== 0) writer.uint32(16).int32(message.giftId);
807
+ if (message.repeatCount !== 0) writer.uint32(40).int32(message.repeatCount);
808
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(58).fork()).join();
809
+ if (message.repeatEnd !== 0) writer.uint32(72).int32(message.repeatEnd);
810
+ if (message.groupId !== "0") writer.uint32(88).uint64(message.groupId);
811
+ if (message.giftDetails !== void 0) WebcastGiftMessageGiftDetails.encode(message.giftDetails, writer.uint32(122).fork()).join();
812
+ if (message.monitorExtra !== "") writer.uint32(178).string(message.monitorExtra);
813
+ if (message.giftExtra !== void 0) WebcastGiftMessageGiftExtra.encode(message.giftExtra, writer.uint32(186).fork()).join();
814
+ return writer;
815
+ },
816
+ decode(input, length) {
817
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
818
+ const end = length === void 0 ? reader.len : reader.pos + length;
819
+ const message = createBaseWebcastGiftMessage();
820
+ while (reader.pos < end) {
821
+ const tag = reader.uint32();
822
+ switch (tag >>> 3) {
823
+ case 1:
824
+ if (tag !== 10) break;
825
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
826
+ continue;
827
+ case 2:
828
+ if (tag !== 16) break;
829
+ message.giftId = reader.int32();
830
+ continue;
831
+ case 5:
832
+ if (tag !== 40) break;
833
+ message.repeatCount = reader.int32();
834
+ continue;
835
+ case 7:
836
+ if (tag !== 58) break;
837
+ message.user = User.decode(reader, reader.uint32());
838
+ continue;
839
+ case 9:
840
+ if (tag !== 72) break;
841
+ message.repeatEnd = reader.int32();
842
+ continue;
843
+ case 11:
844
+ if (tag !== 88) break;
845
+ message.groupId = reader.uint64().toString();
846
+ continue;
847
+ case 15:
848
+ if (tag !== 122) break;
849
+ message.giftDetails = WebcastGiftMessageGiftDetails.decode(reader, reader.uint32());
850
+ continue;
851
+ case 22:
852
+ if (tag !== 178) break;
853
+ message.monitorExtra = reader.string();
854
+ continue;
855
+ case 23:
856
+ if (tag !== 186) break;
857
+ message.giftExtra = WebcastGiftMessageGiftExtra.decode(reader, reader.uint32());
858
+ continue;
859
+ }
860
+ if ((tag & 7) === 4 || tag === 0) break;
861
+ reader.skip(tag & 7);
862
+ }
863
+ return message;
864
+ }
865
+ };
866
+ function createBaseWebcastGiftMessageGiftDetails() {
867
+ return {
868
+ giftImage: void 0,
869
+ giftName: "",
870
+ describe: "",
871
+ giftType: 0,
872
+ diamondCount: 0
873
+ };
874
+ }
875
+ const WebcastGiftMessageGiftDetails = {
876
+ encode(message, writer = new BinaryWriter()) {
877
+ if (message.giftImage !== void 0) WebcastGiftMessageGiftImage.encode(message.giftImage, writer.uint32(10).fork()).join();
878
+ if (message.giftName !== "") writer.uint32(130).string(message.giftName);
879
+ if (message.describe !== "") writer.uint32(18).string(message.describe);
880
+ if (message.giftType !== 0) writer.uint32(88).int32(message.giftType);
881
+ if (message.diamondCount !== 0) writer.uint32(96).int32(message.diamondCount);
882
+ return writer;
883
+ },
884
+ decode(input, length) {
885
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
886
+ const end = length === void 0 ? reader.len : reader.pos + length;
887
+ const message = createBaseWebcastGiftMessageGiftDetails();
888
+ while (reader.pos < end) {
889
+ const tag = reader.uint32();
890
+ switch (tag >>> 3) {
891
+ case 1:
892
+ if (tag !== 10) break;
893
+ message.giftImage = WebcastGiftMessageGiftImage.decode(reader, reader.uint32());
894
+ continue;
895
+ case 16:
896
+ if (tag !== 130) break;
897
+ message.giftName = reader.string();
898
+ continue;
899
+ case 2:
900
+ if (tag !== 18) break;
901
+ message.describe = reader.string();
902
+ continue;
903
+ case 11:
904
+ if (tag !== 88) break;
905
+ message.giftType = reader.int32();
906
+ continue;
907
+ case 12:
908
+ if (tag !== 96) break;
909
+ message.diamondCount = reader.int32();
910
+ continue;
911
+ }
912
+ if ((tag & 7) === 4 || tag === 0) break;
913
+ reader.skip(tag & 7);
914
+ }
915
+ return message;
916
+ }
917
+ };
918
+ function createBaseWebcastGiftMessageGiftExtra() {
919
+ return {
920
+ timestamp: "0",
921
+ receiverUserId: "0"
922
+ };
923
+ }
924
+ const WebcastGiftMessageGiftExtra = {
925
+ encode(message, writer = new BinaryWriter()) {
926
+ if (message.timestamp !== "0") writer.uint32(48).uint64(message.timestamp);
927
+ if (message.receiverUserId !== "0") writer.uint32(64).uint64(message.receiverUserId);
928
+ return writer;
929
+ },
930
+ decode(input, length) {
931
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
932
+ const end = length === void 0 ? reader.len : reader.pos + length;
933
+ const message = createBaseWebcastGiftMessageGiftExtra();
934
+ while (reader.pos < end) {
935
+ const tag = reader.uint32();
936
+ switch (tag >>> 3) {
937
+ case 6:
938
+ if (tag !== 48) break;
939
+ message.timestamp = reader.uint64().toString();
940
+ continue;
941
+ case 8:
942
+ if (tag !== 64) break;
943
+ message.receiverUserId = reader.uint64().toString();
944
+ continue;
945
+ }
946
+ if ((tag & 7) === 4 || tag === 0) break;
947
+ reader.skip(tag & 7);
948
+ }
949
+ return message;
950
+ }
951
+ };
952
+ function createBaseWebcastGiftMessageGiftImage() {
953
+ return { giftPictureUrl: "" };
954
+ }
955
+ const WebcastGiftMessageGiftImage = {
956
+ encode(message, writer = new BinaryWriter()) {
957
+ if (message.giftPictureUrl !== "") writer.uint32(10).string(message.giftPictureUrl);
958
+ return writer;
959
+ },
960
+ decode(input, length) {
961
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
962
+ const end = length === void 0 ? reader.len : reader.pos + length;
963
+ const message = createBaseWebcastGiftMessageGiftImage();
964
+ while (reader.pos < end) {
965
+ const tag = reader.uint32();
966
+ switch (tag >>> 3) {
967
+ case 1:
968
+ if (tag !== 10) break;
969
+ message.giftPictureUrl = reader.string();
970
+ continue;
971
+ }
972
+ if ((tag & 7) === 4 || tag === 0) break;
973
+ reader.skip(tag & 7);
974
+ }
975
+ return message;
976
+ }
977
+ };
978
+ function createBaseWebcastLinkMicBattle() {
979
+ return { battleUsers: [] };
980
+ }
981
+ const WebcastLinkMicBattle = {
982
+ encode(message, writer = new BinaryWriter()) {
983
+ for (const v of message.battleUsers) WebcastLinkMicBattleItems.encode(v, writer.uint32(82).fork()).join();
984
+ return writer;
985
+ },
986
+ decode(input, length) {
987
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
988
+ const end = length === void 0 ? reader.len : reader.pos + length;
989
+ const message = createBaseWebcastLinkMicBattle();
990
+ while (reader.pos < end) {
991
+ const tag = reader.uint32();
992
+ switch (tag >>> 3) {
993
+ case 10:
994
+ if (tag !== 82) break;
995
+ message.battleUsers.push(WebcastLinkMicBattleItems.decode(reader, reader.uint32()));
996
+ continue;
997
+ }
998
+ if ((tag & 7) === 4 || tag === 0) break;
999
+ reader.skip(tag & 7);
1000
+ }
1001
+ return message;
1002
+ }
1003
+ };
1004
+ function createBaseWebcastLinkMicBattleItems() {
1005
+ return { battleGroup: void 0 };
1006
+ }
1007
+ const WebcastLinkMicBattleItems = {
1008
+ encode(message, writer = new BinaryWriter()) {
1009
+ if (message.battleGroup !== void 0) WebcastLinkMicBattleGroup.encode(message.battleGroup, writer.uint32(18).fork()).join();
1010
+ return writer;
1011
+ },
1012
+ decode(input, length) {
1013
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1014
+ const end = length === void 0 ? reader.len : reader.pos + length;
1015
+ const message = createBaseWebcastLinkMicBattleItems();
1016
+ while (reader.pos < end) {
1017
+ const tag = reader.uint32();
1018
+ switch (tag >>> 3) {
1019
+ case 2:
1020
+ if (tag !== 18) break;
1021
+ message.battleGroup = WebcastLinkMicBattleGroup.decode(reader, reader.uint32());
1022
+ continue;
1023
+ }
1024
+ if ((tag & 7) === 4 || tag === 0) break;
1025
+ reader.skip(tag & 7);
1026
+ }
1027
+ return message;
1028
+ }
1029
+ };
1030
+ function createBaseWebcastLinkMicBattleGroup() {
1031
+ return { user: void 0 };
1032
+ }
1033
+ const WebcastLinkMicBattleGroup = {
1034
+ encode(message, writer = new BinaryWriter()) {
1035
+ if (message.user !== void 0) LinkUser.encode(message.user, writer.uint32(10).fork()).join();
1036
+ return writer;
1037
+ },
1038
+ decode(input, length) {
1039
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1040
+ const end = length === void 0 ? reader.len : reader.pos + length;
1041
+ const message = createBaseWebcastLinkMicBattleGroup();
1042
+ while (reader.pos < end) {
1043
+ const tag = reader.uint32();
1044
+ switch (tag >>> 3) {
1045
+ case 1:
1046
+ if (tag !== 10) break;
1047
+ message.user = LinkUser.decode(reader, reader.uint32());
1048
+ continue;
1049
+ }
1050
+ if ((tag & 7) === 4 || tag === 0) break;
1051
+ reader.skip(tag & 7);
1052
+ }
1053
+ return message;
1054
+ }
1055
+ };
1056
+ function createBaseWebcastLinkMicArmies() {
1057
+ return {
1058
+ battleItems: [],
1059
+ battleStatus: 0
1060
+ };
1061
+ }
1062
+ const WebcastLinkMicArmies = {
1063
+ encode(message, writer = new BinaryWriter()) {
1064
+ for (const v of message.battleItems) WebcastLinkMicArmiesItems.encode(v, writer.uint32(26).fork()).join();
1065
+ if (message.battleStatus !== 0) writer.uint32(56).int32(message.battleStatus);
1066
+ return writer;
1067
+ },
1068
+ decode(input, length) {
1069
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1070
+ const end = length === void 0 ? reader.len : reader.pos + length;
1071
+ const message = createBaseWebcastLinkMicArmies();
1072
+ while (reader.pos < end) {
1073
+ const tag = reader.uint32();
1074
+ switch (tag >>> 3) {
1075
+ case 3:
1076
+ if (tag !== 26) break;
1077
+ message.battleItems.push(WebcastLinkMicArmiesItems.decode(reader, reader.uint32()));
1078
+ continue;
1079
+ case 7:
1080
+ if (tag !== 56) break;
1081
+ message.battleStatus = reader.int32();
1082
+ continue;
1083
+ }
1084
+ if ((tag & 7) === 4 || tag === 0) break;
1085
+ reader.skip(tag & 7);
1086
+ }
1087
+ return message;
1088
+ }
1089
+ };
1090
+ function createBaseWebcastLinkMicArmiesItems() {
1091
+ return {
1092
+ hostUserId: "0",
1093
+ battleGroups: []
1094
+ };
1095
+ }
1096
+ const WebcastLinkMicArmiesItems = {
1097
+ encode(message, writer = new BinaryWriter()) {
1098
+ if (message.hostUserId !== "0") writer.uint32(8).uint64(message.hostUserId);
1099
+ for (const v of message.battleGroups) WebcastLinkMicArmiesGroup.encode(v, writer.uint32(18).fork()).join();
1100
+ return writer;
1101
+ },
1102
+ decode(input, length) {
1103
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1104
+ const end = length === void 0 ? reader.len : reader.pos + length;
1105
+ const message = createBaseWebcastLinkMicArmiesItems();
1106
+ while (reader.pos < end) {
1107
+ const tag = reader.uint32();
1108
+ switch (tag >>> 3) {
1109
+ case 1:
1110
+ if (tag !== 8) break;
1111
+ message.hostUserId = reader.uint64().toString();
1112
+ continue;
1113
+ case 2:
1114
+ if (tag !== 18) break;
1115
+ message.battleGroups.push(WebcastLinkMicArmiesGroup.decode(reader, reader.uint32()));
1116
+ continue;
1117
+ }
1118
+ if ((tag & 7) === 4 || tag === 0) break;
1119
+ reader.skip(tag & 7);
1120
+ }
1121
+ return message;
1122
+ }
1123
+ };
1124
+ function createBaseWebcastLinkMicArmiesGroup() {
1125
+ return {
1126
+ users: [],
1127
+ points: 0
1128
+ };
1129
+ }
1130
+ const WebcastLinkMicArmiesGroup = {
1131
+ encode(message, writer = new BinaryWriter()) {
1132
+ for (const v of message.users) User.encode(v, writer.uint32(10).fork()).join();
1133
+ if (message.points !== 0) writer.uint32(16).int32(message.points);
1134
+ return writer;
1135
+ },
1136
+ decode(input, length) {
1137
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1138
+ const end = length === void 0 ? reader.len : reader.pos + length;
1139
+ const message = createBaseWebcastLinkMicArmiesGroup();
1140
+ while (reader.pos < end) {
1141
+ const tag = reader.uint32();
1142
+ switch (tag >>> 3) {
1143
+ case 1:
1144
+ if (tag !== 10) break;
1145
+ message.users.push(User.decode(reader, reader.uint32()));
1146
+ continue;
1147
+ case 2:
1148
+ if (tag !== 16) break;
1149
+ message.points = reader.int32();
1150
+ continue;
1151
+ }
1152
+ if ((tag & 7) === 4 || tag === 0) break;
1153
+ reader.skip(tag & 7);
1154
+ }
1155
+ return message;
1156
+ }
1157
+ };
1158
+ function createBaseWebcastSocialMessage() {
1159
+ return {
1160
+ event: void 0,
1161
+ user: void 0
1162
+ };
1163
+ }
1164
+ const WebcastSocialMessage = {
1165
+ encode(message, writer = new BinaryWriter()) {
1166
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
1167
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
1168
+ return writer;
1169
+ },
1170
+ decode(input, length) {
1171
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1172
+ const end = length === void 0 ? reader.len : reader.pos + length;
1173
+ const message = createBaseWebcastSocialMessage();
1174
+ while (reader.pos < end) {
1175
+ const tag = reader.uint32();
1176
+ switch (tag >>> 3) {
1177
+ case 1:
1178
+ if (tag !== 10) break;
1179
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
1180
+ continue;
1181
+ case 2:
1182
+ if (tag !== 18) break;
1183
+ message.user = User.decode(reader, reader.uint32());
1184
+ continue;
1185
+ }
1186
+ if ((tag & 7) === 4 || tag === 0) break;
1187
+ reader.skip(tag & 7);
1188
+ }
1189
+ return message;
1190
+ }
1191
+ };
1192
+ function createBaseWebcastLikeMessage() {
1193
+ return {
1194
+ event: void 0,
1195
+ user: void 0,
1196
+ likeCount: 0,
1197
+ totalLikeCount: 0
1198
+ };
1199
+ }
1200
+ const WebcastLikeMessage = {
1201
+ encode(message, writer = new BinaryWriter()) {
1202
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
1203
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(42).fork()).join();
1204
+ if (message.likeCount !== 0) writer.uint32(16).int32(message.likeCount);
1205
+ if (message.totalLikeCount !== 0) writer.uint32(24).int32(message.totalLikeCount);
1206
+ return writer;
1207
+ },
1208
+ decode(input, length) {
1209
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1210
+ const end = length === void 0 ? reader.len : reader.pos + length;
1211
+ const message = createBaseWebcastLikeMessage();
1212
+ while (reader.pos < end) {
1213
+ const tag = reader.uint32();
1214
+ switch (tag >>> 3) {
1215
+ case 1:
1216
+ if (tag !== 10) break;
1217
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
1218
+ continue;
1219
+ case 5:
1220
+ if (tag !== 42) break;
1221
+ message.user = User.decode(reader, reader.uint32());
1222
+ continue;
1223
+ case 2:
1224
+ if (tag !== 16) break;
1225
+ message.likeCount = reader.int32();
1226
+ continue;
1227
+ case 3:
1228
+ if (tag !== 24) break;
1229
+ message.totalLikeCount = reader.int32();
1230
+ continue;
1231
+ }
1232
+ if ((tag & 7) === 4 || tag === 0) break;
1233
+ reader.skip(tag & 7);
1234
+ }
1235
+ return message;
1236
+ }
1237
+ };
1238
+ function createBaseWebcastQuestionNewMessage() {
1239
+ return { questionDetails: void 0 };
1240
+ }
1241
+ const WebcastQuestionNewMessage = {
1242
+ encode(message, writer = new BinaryWriter()) {
1243
+ if (message.questionDetails !== void 0) QuestionDetails.encode(message.questionDetails, writer.uint32(18).fork()).join();
1244
+ return writer;
1245
+ },
1246
+ decode(input, length) {
1247
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1248
+ const end = length === void 0 ? reader.len : reader.pos + length;
1249
+ const message = createBaseWebcastQuestionNewMessage();
1250
+ while (reader.pos < end) {
1251
+ const tag = reader.uint32();
1252
+ switch (tag >>> 3) {
1253
+ case 2:
1254
+ if (tag !== 18) break;
1255
+ message.questionDetails = QuestionDetails.decode(reader, reader.uint32());
1256
+ continue;
1257
+ }
1258
+ if ((tag & 7) === 4 || tag === 0) break;
1259
+ reader.skip(tag & 7);
1260
+ }
1261
+ return message;
1262
+ }
1263
+ };
1264
+ function createBaseQuestionDetails() {
1265
+ return {
1266
+ questionText: "",
1267
+ user: void 0
1268
+ };
1269
+ }
1270
+ const QuestionDetails = {
1271
+ encode(message, writer = new BinaryWriter()) {
1272
+ if (message.questionText !== "") writer.uint32(18).string(message.questionText);
1273
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(42).fork()).join();
1274
+ return writer;
1275
+ },
1276
+ decode(input, length) {
1277
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1278
+ const end = length === void 0 ? reader.len : reader.pos + length;
1279
+ const message = createBaseQuestionDetails();
1280
+ while (reader.pos < end) {
1281
+ const tag = reader.uint32();
1282
+ switch (tag >>> 3) {
1283
+ case 2:
1284
+ if (tag !== 18) break;
1285
+ message.questionText = reader.string();
1286
+ continue;
1287
+ case 5:
1288
+ if (tag !== 42) break;
1289
+ message.user = User.decode(reader, reader.uint32());
1290
+ continue;
1291
+ }
1292
+ if ((tag & 7) === 4 || tag === 0) break;
1293
+ reader.skip(tag & 7);
1294
+ }
1295
+ return message;
1296
+ }
1297
+ };
1298
+ function createBaseWebcastMessageEvent() {
1299
+ return {
1300
+ msgId: "0",
1301
+ createTime: "0",
1302
+ eventDetails: void 0
1303
+ };
1304
+ }
1305
+ const WebcastMessageEvent = {
1306
+ encode(message, writer = new BinaryWriter()) {
1307
+ if (message.msgId !== "0") writer.uint32(16).uint64(message.msgId);
1308
+ if (message.createTime !== "0") writer.uint32(32).uint64(message.createTime);
1309
+ if (message.eventDetails !== void 0) WebcastMessageEventDetails.encode(message.eventDetails, writer.uint32(66).fork()).join();
1310
+ return writer;
1311
+ },
1312
+ decode(input, length) {
1313
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1314
+ const end = length === void 0 ? reader.len : reader.pos + length;
1315
+ const message = createBaseWebcastMessageEvent();
1316
+ while (reader.pos < end) {
1317
+ const tag = reader.uint32();
1318
+ switch (tag >>> 3) {
1319
+ case 2:
1320
+ if (tag !== 16) break;
1321
+ message.msgId = reader.uint64().toString();
1322
+ continue;
1323
+ case 4:
1324
+ if (tag !== 32) break;
1325
+ message.createTime = reader.uint64().toString();
1326
+ continue;
1327
+ case 8:
1328
+ if (tag !== 66) break;
1329
+ message.eventDetails = WebcastMessageEventDetails.decode(reader, reader.uint32());
1330
+ continue;
1331
+ }
1332
+ if ((tag & 7) === 4 || tag === 0) break;
1333
+ reader.skip(tag & 7);
1334
+ }
1335
+ return message;
1336
+ }
1337
+ };
1338
+ function createBaseWebcastMessageEventDetails() {
1339
+ return {
1340
+ displayType: "",
1341
+ label: ""
1342
+ };
1343
+ }
1344
+ const WebcastMessageEventDetails = {
1345
+ encode(message, writer = new BinaryWriter()) {
1346
+ if (message.displayType !== "") writer.uint32(10).string(message.displayType);
1347
+ if (message.label !== "") writer.uint32(18).string(message.label);
1348
+ return writer;
1349
+ },
1350
+ decode(input, length) {
1351
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1352
+ const end = length === void 0 ? reader.len : reader.pos + length;
1353
+ const message = createBaseWebcastMessageEventDetails();
1354
+ while (reader.pos < end) {
1355
+ const tag = reader.uint32();
1356
+ switch (tag >>> 3) {
1357
+ case 1:
1358
+ if (tag !== 10) break;
1359
+ message.displayType = reader.string();
1360
+ continue;
1361
+ case 2:
1362
+ if (tag !== 18) break;
1363
+ message.label = reader.string();
1364
+ continue;
1365
+ }
1366
+ if ((tag & 7) === 4 || tag === 0) break;
1367
+ reader.skip(tag & 7);
1368
+ }
1369
+ return message;
1370
+ }
1371
+ };
1372
+ function createBaseWebcastLiveIntroMessage() {
1373
+ return {
1374
+ id: "0",
1375
+ description: "",
1376
+ user: void 0
1377
+ };
1378
+ }
1379
+ const WebcastLiveIntroMessage = {
1380
+ encode(message, writer = new BinaryWriter()) {
1381
+ if (message.id !== "0") writer.uint32(16).uint64(message.id);
1382
+ if (message.description !== "") writer.uint32(34).string(message.description);
1383
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(42).fork()).join();
1384
+ return writer;
1385
+ },
1386
+ decode(input, length) {
1387
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1388
+ const end = length === void 0 ? reader.len : reader.pos + length;
1389
+ const message = createBaseWebcastLiveIntroMessage();
1390
+ while (reader.pos < end) {
1391
+ const tag = reader.uint32();
1392
+ switch (tag >>> 3) {
1393
+ case 2:
1394
+ if (tag !== 16) break;
1395
+ message.id = reader.uint64().toString();
1396
+ continue;
1397
+ case 4:
1398
+ if (tag !== 34) break;
1399
+ message.description = reader.string();
1400
+ continue;
1401
+ case 5:
1402
+ if (tag !== 42) break;
1403
+ message.user = User.decode(reader, reader.uint32());
1404
+ continue;
1405
+ }
1406
+ if ((tag & 7) === 4 || tag === 0) break;
1407
+ reader.skip(tag & 7);
1408
+ }
1409
+ return message;
1410
+ }
1411
+ };
1412
+ function createBaseSystemMessage() {
1413
+ return { description: "" };
1414
+ }
1415
+ const SystemMessage = {
1416
+ encode(message, writer = new BinaryWriter()) {
1417
+ if (message.description !== "") writer.uint32(18).string(message.description);
1418
+ return writer;
1419
+ },
1420
+ decode(input, length) {
1421
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1422
+ const end = length === void 0 ? reader.len : reader.pos + length;
1423
+ const message = createBaseSystemMessage();
1424
+ while (reader.pos < end) {
1425
+ const tag = reader.uint32();
1426
+ switch (tag >>> 3) {
1427
+ case 2:
1428
+ if (tag !== 18) break;
1429
+ message.description = reader.string();
1430
+ continue;
1431
+ }
1432
+ if ((tag & 7) === 4 || tag === 0) break;
1433
+ reader.skip(tag & 7);
1434
+ }
1435
+ return message;
1436
+ }
1437
+ };
1438
+ function createBaseWebcastInRoomBannerMessage() {
1439
+ return { data: "" };
1440
+ }
1441
+ const WebcastInRoomBannerMessage = {
1442
+ encode(message, writer = new BinaryWriter()) {
1443
+ if (message.data !== "") writer.uint32(18).string(message.data);
1444
+ return writer;
1445
+ },
1446
+ decode(input, length) {
1447
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1448
+ const end = length === void 0 ? reader.len : reader.pos + length;
1449
+ const message = createBaseWebcastInRoomBannerMessage();
1450
+ while (reader.pos < end) {
1451
+ const tag = reader.uint32();
1452
+ switch (tag >>> 3) {
1453
+ case 2:
1454
+ if (tag !== 18) break;
1455
+ message.data = reader.string();
1456
+ continue;
1457
+ }
1458
+ if ((tag & 7) === 4 || tag === 0) break;
1459
+ reader.skip(tag & 7);
1460
+ }
1461
+ return message;
1462
+ }
1463
+ };
1464
+ function createBaseRankItem() {
1465
+ return {
1466
+ colour: "",
1467
+ id: "0"
1468
+ };
1469
+ }
1470
+ const RankItem = {
1471
+ encode(message, writer = new BinaryWriter()) {
1472
+ if (message.colour !== "") writer.uint32(10).string(message.colour);
1473
+ if (message.id !== "0") writer.uint32(32).uint64(message.id);
1474
+ return writer;
1475
+ },
1476
+ decode(input, length) {
1477
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1478
+ const end = length === void 0 ? reader.len : reader.pos + length;
1479
+ const message = createBaseRankItem();
1480
+ while (reader.pos < end) {
1481
+ const tag = reader.uint32();
1482
+ switch (tag >>> 3) {
1483
+ case 1:
1484
+ if (tag !== 10) break;
1485
+ message.colour = reader.string();
1486
+ continue;
1487
+ case 4:
1488
+ if (tag !== 32) break;
1489
+ message.id = reader.uint64().toString();
1490
+ continue;
1491
+ }
1492
+ if ((tag & 7) === 4 || tag === 0) break;
1493
+ reader.skip(tag & 7);
1494
+ }
1495
+ return message;
1496
+ }
1497
+ };
1498
+ function createBaseWeeklyRanking() {
1499
+ return {
1500
+ type: "",
1501
+ label: "",
1502
+ rank: void 0
1503
+ };
1504
+ }
1505
+ const WeeklyRanking = {
1506
+ encode(message, writer = new BinaryWriter()) {
1507
+ if (message.type !== "") writer.uint32(10).string(message.type);
1508
+ if (message.label !== "") writer.uint32(18).string(message.label);
1509
+ if (message.rank !== void 0) RankItem.encode(message.rank, writer.uint32(26).fork()).join();
1510
+ return writer;
1511
+ },
1512
+ decode(input, length) {
1513
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1514
+ const end = length === void 0 ? reader.len : reader.pos + length;
1515
+ const message = createBaseWeeklyRanking();
1516
+ while (reader.pos < end) {
1517
+ const tag = reader.uint32();
1518
+ switch (tag >>> 3) {
1519
+ case 1:
1520
+ if (tag !== 10) break;
1521
+ message.type = reader.string();
1522
+ continue;
1523
+ case 2:
1524
+ if (tag !== 18) break;
1525
+ message.label = reader.string();
1526
+ continue;
1527
+ case 3:
1528
+ if (tag !== 26) break;
1529
+ message.rank = RankItem.decode(reader, reader.uint32());
1530
+ continue;
1531
+ }
1532
+ if ((tag & 7) === 4 || tag === 0) break;
1533
+ reader.skip(tag & 7);
1534
+ }
1535
+ return message;
1536
+ }
1537
+ };
1538
+ function createBaseRankContainer() {
1539
+ return { rankings: void 0 };
1540
+ }
1541
+ const RankContainer = {
1542
+ encode(message, writer = new BinaryWriter()) {
1543
+ if (message.rankings !== void 0) WeeklyRanking.encode(message.rankings, writer.uint32(34).fork()).join();
1544
+ return writer;
1545
+ },
1546
+ decode(input, length) {
1547
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1548
+ const end = length === void 0 ? reader.len : reader.pos + length;
1549
+ const message = createBaseRankContainer();
1550
+ while (reader.pos < end) {
1551
+ const tag = reader.uint32();
1552
+ switch (tag >>> 3) {
1553
+ case 4:
1554
+ if (tag !== 34) break;
1555
+ message.rankings = WeeklyRanking.decode(reader, reader.uint32());
1556
+ continue;
1557
+ }
1558
+ if ((tag & 7) === 4 || tag === 0) break;
1559
+ reader.skip(tag & 7);
1560
+ }
1561
+ return message;
1562
+ }
1563
+ };
1564
+ function createBaseWebcastHourlyRankMessage() {
1565
+ return { data: void 0 };
1566
+ }
1567
+ const WebcastHourlyRankMessage = {
1568
+ encode(message, writer = new BinaryWriter()) {
1569
+ if (message.data !== void 0) RankContainer.encode(message.data, writer.uint32(18).fork()).join();
1570
+ return writer;
1571
+ },
1572
+ decode(input, length) {
1573
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1574
+ const end = length === void 0 ? reader.len : reader.pos + length;
1575
+ const message = createBaseWebcastHourlyRankMessage();
1576
+ while (reader.pos < end) {
1577
+ const tag = reader.uint32();
1578
+ switch (tag >>> 3) {
1579
+ case 2:
1580
+ if (tag !== 18) break;
1581
+ message.data = RankContainer.decode(reader, reader.uint32());
1582
+ continue;
1583
+ }
1584
+ if ((tag & 7) === 4 || tag === 0) break;
1585
+ reader.skip(tag & 7);
1586
+ }
1587
+ return message;
1588
+ }
1589
+ };
1590
+ function createBaseEmoteDetails() {
1591
+ return {
1592
+ emoteId: "",
1593
+ image: void 0
1594
+ };
1595
+ }
1596
+ const EmoteDetails = {
1597
+ encode(message, writer = new BinaryWriter()) {
1598
+ if (message.emoteId !== "") writer.uint32(10).string(message.emoteId);
1599
+ if (message.image !== void 0) EmoteImage.encode(message.image, writer.uint32(18).fork()).join();
1600
+ return writer;
1601
+ },
1602
+ decode(input, length) {
1603
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1604
+ const end = length === void 0 ? reader.len : reader.pos + length;
1605
+ const message = createBaseEmoteDetails();
1606
+ while (reader.pos < end) {
1607
+ const tag = reader.uint32();
1608
+ switch (tag >>> 3) {
1609
+ case 1:
1610
+ if (tag !== 10) break;
1611
+ message.emoteId = reader.string();
1612
+ continue;
1613
+ case 2:
1614
+ if (tag !== 18) break;
1615
+ message.image = EmoteImage.decode(reader, reader.uint32());
1616
+ continue;
1617
+ }
1618
+ if ((tag & 7) === 4 || tag === 0) break;
1619
+ reader.skip(tag & 7);
1620
+ }
1621
+ return message;
1622
+ }
1623
+ };
1624
+ function createBaseEmoteImage() {
1625
+ return { imageUrl: "" };
1626
+ }
1627
+ const EmoteImage = {
1628
+ encode(message, writer = new BinaryWriter()) {
1629
+ if (message.imageUrl !== "") writer.uint32(10).string(message.imageUrl);
1630
+ return writer;
1631
+ },
1632
+ decode(input, length) {
1633
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1634
+ const end = length === void 0 ? reader.len : reader.pos + length;
1635
+ const message = createBaseEmoteImage();
1636
+ while (reader.pos < end) {
1637
+ const tag = reader.uint32();
1638
+ switch (tag >>> 3) {
1639
+ case 1:
1640
+ if (tag !== 10) break;
1641
+ message.imageUrl = reader.string();
1642
+ continue;
1643
+ }
1644
+ if ((tag & 7) === 4 || tag === 0) break;
1645
+ reader.skip(tag & 7);
1646
+ }
1647
+ return message;
1648
+ }
1649
+ };
1650
+ function createBaseWebcastEnvelopeMessage() {
1651
+ return {
1652
+ treasureBoxData: void 0,
1653
+ treasureBoxUser: void 0
1654
+ };
1655
+ }
1656
+ const WebcastEnvelopeMessage = {
1657
+ encode(message, writer = new BinaryWriter()) {
1658
+ if (message.treasureBoxData !== void 0) TreasureBoxData.encode(message.treasureBoxData, writer.uint32(18).fork()).join();
1659
+ if (message.treasureBoxUser !== void 0) TreasureBoxUser.encode(message.treasureBoxUser, writer.uint32(10).fork()).join();
1660
+ return writer;
1661
+ },
1662
+ decode(input, length) {
1663
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1664
+ const end = length === void 0 ? reader.len : reader.pos + length;
1665
+ const message = createBaseWebcastEnvelopeMessage();
1666
+ while (reader.pos < end) {
1667
+ const tag = reader.uint32();
1668
+ switch (tag >>> 3) {
1669
+ case 2:
1670
+ if (tag !== 18) break;
1671
+ message.treasureBoxData = TreasureBoxData.decode(reader, reader.uint32());
1672
+ continue;
1673
+ case 1:
1674
+ if (tag !== 10) break;
1675
+ message.treasureBoxUser = TreasureBoxUser.decode(reader, reader.uint32());
1676
+ continue;
1677
+ }
1678
+ if ((tag & 7) === 4 || tag === 0) break;
1679
+ reader.skip(tag & 7);
1680
+ }
1681
+ return message;
1682
+ }
1683
+ };
1684
+ function createBaseTreasureBoxUser() {
1685
+ return { user2: void 0 };
1686
+ }
1687
+ const TreasureBoxUser = {
1688
+ encode(message, writer = new BinaryWriter()) {
1689
+ if (message.user2 !== void 0) TreasureBoxUser2.encode(message.user2, writer.uint32(66).fork()).join();
1690
+ return writer;
1691
+ },
1692
+ decode(input, length) {
1693
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1694
+ const end = length === void 0 ? reader.len : reader.pos + length;
1695
+ const message = createBaseTreasureBoxUser();
1696
+ while (reader.pos < end) {
1697
+ const tag = reader.uint32();
1698
+ switch (tag >>> 3) {
1699
+ case 8:
1700
+ if (tag !== 66) break;
1701
+ message.user2 = TreasureBoxUser2.decode(reader, reader.uint32());
1702
+ continue;
1703
+ }
1704
+ if ((tag & 7) === 4 || tag === 0) break;
1705
+ reader.skip(tag & 7);
1706
+ }
1707
+ return message;
1708
+ }
1709
+ };
1710
+ function createBaseTreasureBoxUser2() {
1711
+ return { user3: [] };
1712
+ }
1713
+ const TreasureBoxUser2 = {
1714
+ encode(message, writer = new BinaryWriter()) {
1715
+ for (const v of message.user3) TreasureBoxUser3.encode(v, writer.uint32(34).fork()).join();
1716
+ return writer;
1717
+ },
1718
+ decode(input, length) {
1719
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1720
+ const end = length === void 0 ? reader.len : reader.pos + length;
1721
+ const message = createBaseTreasureBoxUser2();
1722
+ while (reader.pos < end) {
1723
+ const tag = reader.uint32();
1724
+ switch (tag >>> 3) {
1725
+ case 4:
1726
+ if (tag !== 34) break;
1727
+ message.user3.push(TreasureBoxUser3.decode(reader, reader.uint32()));
1728
+ continue;
1729
+ }
1730
+ if ((tag & 7) === 4 || tag === 0) break;
1731
+ reader.skip(tag & 7);
1732
+ }
1733
+ return message;
1734
+ }
1735
+ };
1736
+ function createBaseTreasureBoxUser3() {
1737
+ return { user4: void 0 };
1738
+ }
1739
+ const TreasureBoxUser3 = {
1740
+ encode(message, writer = new BinaryWriter()) {
1741
+ if (message.user4 !== void 0) TreasureBoxUser4.encode(message.user4, writer.uint32(170).fork()).join();
1742
+ return writer;
1743
+ },
1744
+ decode(input, length) {
1745
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1746
+ const end = length === void 0 ? reader.len : reader.pos + length;
1747
+ const message = createBaseTreasureBoxUser3();
1748
+ while (reader.pos < end) {
1749
+ const tag = reader.uint32();
1750
+ switch (tag >>> 3) {
1751
+ case 21:
1752
+ if (tag !== 170) break;
1753
+ message.user4 = TreasureBoxUser4.decode(reader, reader.uint32());
1754
+ continue;
1755
+ }
1756
+ if ((tag & 7) === 4 || tag === 0) break;
1757
+ reader.skip(tag & 7);
1758
+ }
1759
+ return message;
1760
+ }
1761
+ };
1762
+ function createBaseTreasureBoxUser4() {
1763
+ return { user: void 0 };
1764
+ }
1765
+ const TreasureBoxUser4 = {
1766
+ encode(message, writer = new BinaryWriter()) {
1767
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(10).fork()).join();
1768
+ return writer;
1769
+ },
1770
+ decode(input, length) {
1771
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1772
+ const end = length === void 0 ? reader.len : reader.pos + length;
1773
+ const message = createBaseTreasureBoxUser4();
1774
+ while (reader.pos < end) {
1775
+ const tag = reader.uint32();
1776
+ switch (tag >>> 3) {
1777
+ case 1:
1778
+ if (tag !== 10) break;
1779
+ message.user = User.decode(reader, reader.uint32());
1780
+ continue;
1781
+ }
1782
+ if ((tag & 7) === 4 || tag === 0) break;
1783
+ reader.skip(tag & 7);
1784
+ }
1785
+ return message;
1786
+ }
1787
+ };
1788
+ function createBaseTreasureBoxData() {
1789
+ return {
1790
+ coins: 0,
1791
+ canOpen: 0,
1792
+ timestamp: "0"
1793
+ };
1794
+ }
1795
+ const TreasureBoxData = {
1796
+ encode(message, writer = new BinaryWriter()) {
1797
+ if (message.coins !== 0) writer.uint32(40).uint32(message.coins);
1798
+ if (message.canOpen !== 0) writer.uint32(48).uint32(message.canOpen);
1799
+ if (message.timestamp !== "0") writer.uint32(56).uint64(message.timestamp);
1800
+ return writer;
1801
+ },
1802
+ decode(input, length) {
1803
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1804
+ const end = length === void 0 ? reader.len : reader.pos + length;
1805
+ const message = createBaseTreasureBoxData();
1806
+ while (reader.pos < end) {
1807
+ const tag = reader.uint32();
1808
+ switch (tag >>> 3) {
1809
+ case 5:
1810
+ if (tag !== 40) break;
1811
+ message.coins = reader.uint32();
1812
+ continue;
1813
+ case 6:
1814
+ if (tag !== 48) break;
1815
+ message.canOpen = reader.uint32();
1816
+ continue;
1817
+ case 7:
1818
+ if (tag !== 56) break;
1819
+ message.timestamp = reader.uint64().toString();
1820
+ continue;
1821
+ }
1822
+ if ((tag & 7) === 4 || tag === 0) break;
1823
+ reader.skip(tag & 7);
1824
+ }
1825
+ return message;
1826
+ }
1827
+ };
1828
+ function createBaseWebcastSubNotifyMessage() {
1829
+ return {
1830
+ event: void 0,
1831
+ user: void 0,
1832
+ exhibitionType: 0,
1833
+ subMonth: 0,
1834
+ subscribeType: 0,
1835
+ oldSubscribeStatus: 0,
1836
+ subscribingStatus: 0
1837
+ };
1838
+ }
1839
+ const WebcastSubNotifyMessage = {
1840
+ encode(message, writer = new BinaryWriter()) {
1841
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
1842
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(18).fork()).join();
1843
+ if (message.exhibitionType !== 0) writer.uint32(24).int32(message.exhibitionType);
1844
+ if (message.subMonth !== 0) writer.uint32(32).int32(message.subMonth);
1845
+ if (message.subscribeType !== 0) writer.uint32(40).int32(message.subscribeType);
1846
+ if (message.oldSubscribeStatus !== 0) writer.uint32(48).int32(message.oldSubscribeStatus);
1847
+ if (message.subscribingStatus !== 0) writer.uint32(64).int32(message.subscribingStatus);
1848
+ return writer;
1849
+ },
1850
+ decode(input, length) {
1851
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1852
+ const end = length === void 0 ? reader.len : reader.pos + length;
1853
+ const message = createBaseWebcastSubNotifyMessage();
1854
+ while (reader.pos < end) {
1855
+ const tag = reader.uint32();
1856
+ switch (tag >>> 3) {
1857
+ case 1:
1858
+ if (tag !== 10) break;
1859
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
1860
+ continue;
1861
+ case 2:
1862
+ if (tag !== 18) break;
1863
+ message.user = User.decode(reader, reader.uint32());
1864
+ continue;
1865
+ case 3:
1866
+ if (tag !== 24) break;
1867
+ message.exhibitionType = reader.int32();
1868
+ continue;
1869
+ case 4:
1870
+ if (tag !== 32) break;
1871
+ message.subMonth = reader.int32();
1872
+ continue;
1873
+ case 5:
1874
+ if (tag !== 40) break;
1875
+ message.subscribeType = reader.int32();
1876
+ continue;
1877
+ case 6:
1878
+ if (tag !== 48) break;
1879
+ message.oldSubscribeStatus = reader.int32();
1880
+ continue;
1881
+ case 8:
1882
+ if (tag !== 64) break;
1883
+ message.subscribingStatus = reader.int32();
1884
+ continue;
1885
+ }
1886
+ if ((tag & 7) === 4 || tag === 0) break;
1887
+ reader.skip(tag & 7);
1888
+ }
1889
+ return message;
1890
+ }
1891
+ };
1892
+ function createBaseUser() {
1893
+ return {
1894
+ userId: "0",
1895
+ nickname: "",
1896
+ profilePicture: void 0,
1897
+ uniqueId: "",
1898
+ secUid: "",
1899
+ badges: [],
1900
+ createTime: "0",
1901
+ bioDescription: "",
1902
+ followInfo: void 0
1903
+ };
1904
+ }
1905
+ const User = {
1906
+ encode(message, writer = new BinaryWriter()) {
1907
+ if (message.userId !== "0") writer.uint32(8).uint64(message.userId);
1908
+ if (message.nickname !== "") writer.uint32(26).string(message.nickname);
1909
+ if (message.profilePicture !== void 0) ProfilePicture.encode(message.profilePicture, writer.uint32(74).fork()).join();
1910
+ if (message.uniqueId !== "") writer.uint32(306).string(message.uniqueId);
1911
+ if (message.secUid !== "") writer.uint32(370).string(message.secUid);
1912
+ for (const v of message.badges) UserBadgesAttributes.encode(v, writer.uint32(514).fork()).join();
1913
+ if (message.createTime !== "0") writer.uint32(128).uint64(message.createTime);
1914
+ if (message.bioDescription !== "") writer.uint32(42).string(message.bioDescription);
1915
+ if (message.followInfo !== void 0) FollowInfo.encode(message.followInfo, writer.uint32(178).fork()).join();
1916
+ return writer;
1917
+ },
1918
+ decode(input, length) {
1919
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1920
+ const end = length === void 0 ? reader.len : reader.pos + length;
1921
+ const message = createBaseUser();
1922
+ while (reader.pos < end) {
1923
+ const tag = reader.uint32();
1924
+ switch (tag >>> 3) {
1925
+ case 1:
1926
+ if (tag !== 8) break;
1927
+ message.userId = reader.uint64().toString();
1928
+ continue;
1929
+ case 3:
1930
+ if (tag !== 26) break;
1931
+ message.nickname = reader.string();
1932
+ continue;
1933
+ case 9:
1934
+ if (tag !== 74) break;
1935
+ message.profilePicture = ProfilePicture.decode(reader, reader.uint32());
1936
+ continue;
1937
+ case 38:
1938
+ if (tag !== 306) break;
1939
+ message.uniqueId = reader.string();
1940
+ continue;
1941
+ case 46:
1942
+ if (tag !== 370) break;
1943
+ message.secUid = reader.string();
1944
+ continue;
1945
+ case 64:
1946
+ if (tag !== 514) break;
1947
+ message.badges.push(UserBadgesAttributes.decode(reader, reader.uint32()));
1948
+ continue;
1949
+ case 16:
1950
+ if (tag !== 128) break;
1951
+ message.createTime = reader.uint64().toString();
1952
+ continue;
1953
+ case 5:
1954
+ if (tag !== 42) break;
1955
+ message.bioDescription = reader.string();
1956
+ continue;
1957
+ case 22:
1958
+ if (tag !== 178) break;
1959
+ message.followInfo = FollowInfo.decode(reader, reader.uint32());
1960
+ continue;
1961
+ }
1962
+ if ((tag & 7) === 4 || tag === 0) break;
1963
+ reader.skip(tag & 7);
1964
+ }
1965
+ return message;
1966
+ }
1967
+ };
1968
+ function createBaseFollowInfo() {
1969
+ return {
1970
+ followingCount: 0,
1971
+ followerCount: 0,
1972
+ followStatus: 0,
1973
+ pushStatus: 0
1974
+ };
1975
+ }
1976
+ const FollowInfo = {
1977
+ encode(message, writer = new BinaryWriter()) {
1978
+ if (message.followingCount !== 0) writer.uint32(8).int32(message.followingCount);
1979
+ if (message.followerCount !== 0) writer.uint32(16).int32(message.followerCount);
1980
+ if (message.followStatus !== 0) writer.uint32(24).int32(message.followStatus);
1981
+ if (message.pushStatus !== 0) writer.uint32(32).int32(message.pushStatus);
1982
+ return writer;
1983
+ },
1984
+ decode(input, length) {
1985
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
1986
+ const end = length === void 0 ? reader.len : reader.pos + length;
1987
+ const message = createBaseFollowInfo();
1988
+ while (reader.pos < end) {
1989
+ const tag = reader.uint32();
1990
+ switch (tag >>> 3) {
1991
+ case 1:
1992
+ if (tag !== 8) break;
1993
+ message.followingCount = reader.int32();
1994
+ continue;
1995
+ case 2:
1996
+ if (tag !== 16) break;
1997
+ message.followerCount = reader.int32();
1998
+ continue;
1999
+ case 3:
2000
+ if (tag !== 24) break;
2001
+ message.followStatus = reader.int32();
2002
+ continue;
2003
+ case 4:
2004
+ if (tag !== 32) break;
2005
+ message.pushStatus = reader.int32();
2006
+ continue;
2007
+ }
2008
+ if ((tag & 7) === 4 || tag === 0) break;
2009
+ reader.skip(tag & 7);
2010
+ }
2011
+ return message;
2012
+ }
2013
+ };
2014
+ function createBaseLinkUser() {
2015
+ return {
2016
+ userId: "0",
2017
+ nickname: "",
2018
+ profilePicture: void 0,
2019
+ uniqueId: ""
2020
+ };
2021
+ }
2022
+ const LinkUser = {
2023
+ encode(message, writer = new BinaryWriter()) {
2024
+ if (message.userId !== "0") writer.uint32(8).uint64(message.userId);
2025
+ if (message.nickname !== "") writer.uint32(18).string(message.nickname);
2026
+ if (message.profilePicture !== void 0) ProfilePicture.encode(message.profilePicture, writer.uint32(26).fork()).join();
2027
+ if (message.uniqueId !== "") writer.uint32(34).string(message.uniqueId);
2028
+ return writer;
2029
+ },
2030
+ decode(input, length) {
2031
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2032
+ const end = length === void 0 ? reader.len : reader.pos + length;
2033
+ const message = createBaseLinkUser();
2034
+ while (reader.pos < end) {
2035
+ const tag = reader.uint32();
2036
+ switch (tag >>> 3) {
2037
+ case 1:
2038
+ if (tag !== 8) break;
2039
+ message.userId = reader.uint64().toString();
2040
+ continue;
2041
+ case 2:
2042
+ if (tag !== 18) break;
2043
+ message.nickname = reader.string();
2044
+ continue;
2045
+ case 3:
2046
+ if (tag !== 26) break;
2047
+ message.profilePicture = ProfilePicture.decode(reader, reader.uint32());
2048
+ continue;
2049
+ case 4:
2050
+ if (tag !== 34) break;
2051
+ message.uniqueId = reader.string();
2052
+ continue;
2053
+ }
2054
+ if ((tag & 7) === 4 || tag === 0) break;
2055
+ reader.skip(tag & 7);
2056
+ }
2057
+ return message;
2058
+ }
2059
+ };
2060
+ function createBaseProfilePicture() {
2061
+ return { urls: [] };
2062
+ }
2063
+ const ProfilePicture = {
2064
+ encode(message, writer = new BinaryWriter()) {
2065
+ for (const v of message.urls) writer.uint32(10).string(v);
2066
+ return writer;
2067
+ },
2068
+ decode(input, length) {
2069
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2070
+ const end = length === void 0 ? reader.len : reader.pos + length;
2071
+ const message = createBaseProfilePicture();
2072
+ while (reader.pos < end) {
2073
+ const tag = reader.uint32();
2074
+ switch (tag >>> 3) {
2075
+ case 1:
2076
+ if (tag !== 10) break;
2077
+ message.urls.push(reader.string());
2078
+ continue;
2079
+ }
2080
+ if ((tag & 7) === 4 || tag === 0) break;
2081
+ reader.skip(tag & 7);
2082
+ }
2083
+ return message;
2084
+ }
2085
+ };
2086
+ function createBaseUserBadgesAttributes() {
2087
+ return {
2088
+ badgeSceneType: 0,
2089
+ imageBadges: [],
2090
+ badges: [],
2091
+ privilegeLogExtra: void 0
2092
+ };
2093
+ }
2094
+ const UserBadgesAttributes = {
2095
+ encode(message, writer = new BinaryWriter()) {
2096
+ if (message.badgeSceneType !== 0) writer.uint32(24).int32(message.badgeSceneType);
2097
+ for (const v of message.imageBadges) UserImageBadge.encode(v, writer.uint32(162).fork()).join();
2098
+ for (const v of message.badges) UserBadge.encode(v, writer.uint32(170).fork()).join();
2099
+ if (message.privilegeLogExtra !== void 0) PrivilegeLogExtra.encode(message.privilegeLogExtra, writer.uint32(98).fork()).join();
2100
+ return writer;
2101
+ },
2102
+ decode(input, length) {
2103
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2104
+ const end = length === void 0 ? reader.len : reader.pos + length;
2105
+ const message = createBaseUserBadgesAttributes();
2106
+ while (reader.pos < end) {
2107
+ const tag = reader.uint32();
2108
+ switch (tag >>> 3) {
2109
+ case 3:
2110
+ if (tag !== 24) break;
2111
+ message.badgeSceneType = reader.int32();
2112
+ continue;
2113
+ case 20:
2114
+ if (tag !== 162) break;
2115
+ message.imageBadges.push(UserImageBadge.decode(reader, reader.uint32()));
2116
+ continue;
2117
+ case 21:
2118
+ if (tag !== 170) break;
2119
+ message.badges.push(UserBadge.decode(reader, reader.uint32()));
2120
+ continue;
2121
+ case 12:
2122
+ if (tag !== 98) break;
2123
+ message.privilegeLogExtra = PrivilegeLogExtra.decode(reader, reader.uint32());
2124
+ continue;
2125
+ }
2126
+ if ((tag & 7) === 4 || tag === 0) break;
2127
+ reader.skip(tag & 7);
2128
+ }
2129
+ return message;
2130
+ }
2131
+ };
2132
+ function createBasePrivilegeLogExtra() {
2133
+ return {
2134
+ privilegeId: "",
2135
+ level: ""
2136
+ };
2137
+ }
2138
+ const PrivilegeLogExtra = {
2139
+ encode(message, writer = new BinaryWriter()) {
2140
+ if (message.privilegeId !== "") writer.uint32(18).string(message.privilegeId);
2141
+ if (message.level !== "") writer.uint32(42).string(message.level);
2142
+ return writer;
2143
+ },
2144
+ decode(input, length) {
2145
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2146
+ const end = length === void 0 ? reader.len : reader.pos + length;
2147
+ const message = createBasePrivilegeLogExtra();
2148
+ while (reader.pos < end) {
2149
+ const tag = reader.uint32();
2150
+ switch (tag >>> 3) {
2151
+ case 2:
2152
+ if (tag !== 18) break;
2153
+ message.privilegeId = reader.string();
2154
+ continue;
2155
+ case 5:
2156
+ if (tag !== 42) break;
2157
+ message.level = reader.string();
2158
+ continue;
2159
+ }
2160
+ if ((tag & 7) === 4 || tag === 0) break;
2161
+ reader.skip(tag & 7);
2162
+ }
2163
+ return message;
2164
+ }
2165
+ };
2166
+ function createBaseUserBadge() {
2167
+ return {
2168
+ type: "",
2169
+ name: ""
2170
+ };
2171
+ }
2172
+ const UserBadge = {
2173
+ encode(message, writer = new BinaryWriter()) {
2174
+ if (message.type !== "") writer.uint32(18).string(message.type);
2175
+ if (message.name !== "") writer.uint32(26).string(message.name);
2176
+ return writer;
2177
+ },
2178
+ decode(input, length) {
2179
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2180
+ const end = length === void 0 ? reader.len : reader.pos + length;
2181
+ const message = createBaseUserBadge();
2182
+ while (reader.pos < end) {
2183
+ const tag = reader.uint32();
2184
+ switch (tag >>> 3) {
2185
+ case 2:
2186
+ if (tag !== 18) break;
2187
+ message.type = reader.string();
2188
+ continue;
2189
+ case 3:
2190
+ if (tag !== 26) break;
2191
+ message.name = reader.string();
2192
+ continue;
2193
+ }
2194
+ if ((tag & 7) === 4 || tag === 0) break;
2195
+ reader.skip(tag & 7);
2196
+ }
2197
+ return message;
2198
+ }
2199
+ };
2200
+ function createBaseUserImageBadge() {
2201
+ return {
2202
+ displayType: 0,
2203
+ image: void 0
2204
+ };
2205
+ }
2206
+ const UserImageBadge = {
2207
+ encode(message, writer = new BinaryWriter()) {
2208
+ if (message.displayType !== 0) writer.uint32(8).int32(message.displayType);
2209
+ if (message.image !== void 0) UserImageBadgeImage.encode(message.image, writer.uint32(18).fork()).join();
2210
+ return writer;
2211
+ },
2212
+ decode(input, length) {
2213
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2214
+ const end = length === void 0 ? reader.len : reader.pos + length;
2215
+ const message = createBaseUserImageBadge();
2216
+ while (reader.pos < end) {
2217
+ const tag = reader.uint32();
2218
+ switch (tag >>> 3) {
2219
+ case 1:
2220
+ if (tag !== 8) break;
2221
+ message.displayType = reader.int32();
2222
+ continue;
2223
+ case 2:
2224
+ if (tag !== 18) break;
2225
+ message.image = UserImageBadgeImage.decode(reader, reader.uint32());
2226
+ continue;
2227
+ }
2228
+ if ((tag & 7) === 4 || tag === 0) break;
2229
+ reader.skip(tag & 7);
2230
+ }
2231
+ return message;
2232
+ }
2233
+ };
2234
+ function createBaseUserImageBadgeImage() {
2235
+ return { url: "" };
2236
+ }
2237
+ const UserImageBadgeImage = {
2238
+ encode(message, writer = new BinaryWriter()) {
2239
+ if (message.url !== "") writer.uint32(10).string(message.url);
2240
+ return writer;
2241
+ },
2242
+ decode(input, length) {
2243
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2244
+ const end = length === void 0 ? reader.len : reader.pos + length;
2245
+ const message = createBaseUserImageBadgeImage();
2246
+ while (reader.pos < end) {
2247
+ const tag = reader.uint32();
2248
+ switch (tag >>> 3) {
2249
+ case 1:
2250
+ if (tag !== 10) break;
2251
+ message.url = reader.string();
2252
+ continue;
2253
+ }
2254
+ if ((tag & 7) === 4 || tag === 0) break;
2255
+ reader.skip(tag & 7);
2256
+ }
2257
+ return message;
2258
+ }
2259
+ };
2260
+ function createBaseWebcastWebsocketMessage() {
2261
+ return {
2262
+ id: "0",
2263
+ type: "",
2264
+ binary: Buffer.alloc(0)
2265
+ };
2266
+ }
2267
+ const WebcastWebsocketMessage = {
2268
+ encode(message, writer = new BinaryWriter()) {
2269
+ if (message.id !== "0") writer.uint32(16).uint64(message.id);
2270
+ if (message.type !== "") writer.uint32(58).string(message.type);
2271
+ if (message.binary.length !== 0) writer.uint32(66).bytes(message.binary);
2272
+ return writer;
2273
+ },
2274
+ decode(input, length) {
2275
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2276
+ const end = length === void 0 ? reader.len : reader.pos + length;
2277
+ const message = createBaseWebcastWebsocketMessage();
2278
+ while (reader.pos < end) {
2279
+ const tag = reader.uint32();
2280
+ switch (tag >>> 3) {
2281
+ case 2:
2282
+ if (tag !== 16) break;
2283
+ message.id = reader.uint64().toString();
2284
+ continue;
2285
+ case 7:
2286
+ if (tag !== 58) break;
2287
+ message.type = reader.string();
2288
+ continue;
2289
+ case 8:
2290
+ if (tag !== 66) break;
2291
+ message.binary = Buffer.from(reader.bytes());
2292
+ continue;
2293
+ }
2294
+ if ((tag & 7) === 4 || tag === 0) break;
2295
+ reader.skip(tag & 7);
2296
+ }
2297
+ return message;
2298
+ }
2299
+ };
2300
+ function createBaseWebcastWebsocketAck() {
2301
+ return {
2302
+ id: "0",
2303
+ type: ""
2304
+ };
2305
+ }
2306
+ const WebcastWebsocketAck = {
2307
+ encode(message, writer = new BinaryWriter()) {
2308
+ if (message.id !== "0") writer.uint32(16).uint64(message.id);
2309
+ if (message.type !== "") writer.uint32(58).string(message.type);
2310
+ return writer;
2311
+ },
2312
+ decode(input, length) {
2313
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2314
+ const end = length === void 0 ? reader.len : reader.pos + length;
2315
+ const message = createBaseWebcastWebsocketAck();
2316
+ while (reader.pos < end) {
2317
+ const tag = reader.uint32();
2318
+ switch (tag >>> 3) {
2319
+ case 2:
2320
+ if (tag !== 16) break;
2321
+ message.id = reader.uint64().toString();
2322
+ continue;
2323
+ case 7:
2324
+ if (tag !== 58) break;
2325
+ message.type = reader.string();
2326
+ continue;
2327
+ }
2328
+ if ((tag & 7) === 4 || tag === 0) break;
2329
+ reader.skip(tag & 7);
2330
+ }
2331
+ return message;
2332
+ }
2333
+ };
2334
+ function createBaseWebcastBarrageMessage() {
2335
+ return {
2336
+ event: void 0,
2337
+ msgType: 0,
2338
+ content: void 0
2339
+ };
2340
+ }
2341
+ const WebcastBarrageMessage = {
2342
+ encode(message, writer = new BinaryWriter()) {
2343
+ if (message.event !== void 0) WebcastMessageEvent.encode(message.event, writer.uint32(10).fork()).join();
2344
+ if (message.msgType !== 0) writer.uint32(24).int32(message.msgType);
2345
+ if (message.content !== void 0) WebcastBarrageMessage_Text.encode(message.content, writer.uint32(42).fork()).join();
2346
+ return writer;
2347
+ },
2348
+ decode(input, length) {
2349
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2350
+ const end = length === void 0 ? reader.len : reader.pos + length;
2351
+ const message = createBaseWebcastBarrageMessage();
2352
+ while (reader.pos < end) {
2353
+ const tag = reader.uint32();
2354
+ switch (tag >>> 3) {
2355
+ case 1:
2356
+ if (tag !== 10) break;
2357
+ message.event = WebcastMessageEvent.decode(reader, reader.uint32());
2358
+ continue;
2359
+ case 3:
2360
+ if (tag !== 24) break;
2361
+ message.msgType = reader.int32();
2362
+ continue;
2363
+ case 5:
2364
+ if (tag !== 42) break;
2365
+ message.content = WebcastBarrageMessage_Text.decode(reader, reader.uint32());
2366
+ continue;
2367
+ }
2368
+ if ((tag & 7) === 4 || tag === 0) break;
2369
+ reader.skip(tag & 7);
2370
+ }
2371
+ return message;
2372
+ }
2373
+ };
2374
+ function createBaseWebcastBarrageMessage_Text() {
2375
+ return {
2376
+ key: "",
2377
+ defaultPattern: "",
2378
+ pieces: []
2379
+ };
2380
+ }
2381
+ const WebcastBarrageMessage_Text = {
2382
+ encode(message, writer = new BinaryWriter()) {
2383
+ if (message.key !== "") writer.uint32(10).string(message.key);
2384
+ if (message.defaultPattern !== "") writer.uint32(18).string(message.defaultPattern);
2385
+ for (const v of message.pieces) WebcastBarrageMessage_TextPiece.encode(v, writer.uint32(34).fork()).join();
2386
+ return writer;
2387
+ },
2388
+ decode(input, length) {
2389
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2390
+ const end = length === void 0 ? reader.len : reader.pos + length;
2391
+ const message = createBaseWebcastBarrageMessage_Text();
2392
+ while (reader.pos < end) {
2393
+ const tag = reader.uint32();
2394
+ switch (tag >>> 3) {
2395
+ case 1:
2396
+ if (tag !== 10) break;
2397
+ message.key = reader.string();
2398
+ continue;
2399
+ case 2:
2400
+ if (tag !== 18) break;
2401
+ message.defaultPattern = reader.string();
2402
+ continue;
2403
+ case 4:
2404
+ if (tag !== 34) break;
2405
+ message.pieces.push(WebcastBarrageMessage_TextPiece.decode(reader, reader.uint32()));
2406
+ continue;
2407
+ }
2408
+ if ((tag & 7) === 4 || tag === 0) break;
2409
+ reader.skip(tag & 7);
2410
+ }
2411
+ return message;
2412
+ }
2413
+ };
2414
+ function createBaseWebcastBarrageMessage_TextPiece() {
2415
+ return {
2416
+ type: 0,
2417
+ stringValue: "",
2418
+ userValue: void 0
2419
+ };
2420
+ }
2421
+ const WebcastBarrageMessage_TextPiece = {
2422
+ encode(message, writer = new BinaryWriter()) {
2423
+ if (message.type !== 0) writer.uint32(8).int32(message.type);
2424
+ if (message.stringValue !== "") writer.uint32(90).string(message.stringValue);
2425
+ if (message.userValue !== void 0) WebcastBarrageMessage_TextPieceUser.encode(message.userValue, writer.uint32(170).fork()).join();
2426
+ return writer;
2427
+ },
2428
+ decode(input, length) {
2429
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2430
+ const end = length === void 0 ? reader.len : reader.pos + length;
2431
+ const message = createBaseWebcastBarrageMessage_TextPiece();
2432
+ while (reader.pos < end) {
2433
+ const tag = reader.uint32();
2434
+ switch (tag >>> 3) {
2435
+ case 1:
2436
+ if (tag !== 8) break;
2437
+ message.type = reader.int32();
2438
+ continue;
2439
+ case 11:
2440
+ if (tag !== 90) break;
2441
+ message.stringValue = reader.string();
2442
+ continue;
2443
+ case 21:
2444
+ if (tag !== 170) break;
2445
+ message.userValue = WebcastBarrageMessage_TextPieceUser.decode(reader, reader.uint32());
2446
+ continue;
2447
+ }
2448
+ if ((tag & 7) === 4 || tag === 0) break;
2449
+ reader.skip(tag & 7);
2450
+ }
2451
+ return message;
2452
+ }
2453
+ };
2454
+ function createBaseWebcastBarrageMessage_TextPieceUser() {
2455
+ return {
2456
+ user: void 0,
2457
+ withColon: false
2458
+ };
2459
+ }
2460
+ const WebcastBarrageMessage_TextPieceUser = {
2461
+ encode(message, writer = new BinaryWriter()) {
2462
+ if (message.user !== void 0) User.encode(message.user, writer.uint32(10).fork()).join();
2463
+ if (message.withColon !== false) writer.uint32(16).bool(message.withColon);
2464
+ return writer;
2465
+ },
2466
+ decode(input, length) {
2467
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2468
+ const end = length === void 0 ? reader.len : reader.pos + length;
2469
+ const message = createBaseWebcastBarrageMessage_TextPieceUser();
2470
+ while (reader.pos < end) {
2471
+ const tag = reader.uint32();
2472
+ switch (tag >>> 3) {
2473
+ case 1:
2474
+ if (tag !== 10) break;
2475
+ message.user = User.decode(reader, reader.uint32());
2476
+ continue;
2477
+ case 2:
2478
+ if (tag !== 16) break;
2479
+ message.withColon = reader.bool();
2480
+ continue;
2481
+ }
2482
+ if ((tag & 7) === 4 || tag === 0) break;
2483
+ reader.skip(tag & 7);
2484
+ }
2485
+ return message;
2486
+ }
2487
+ };
2488
+ //#endregion
2489
+ export { ControlAction, EmoteDetails, EmoteImage, EmoteUploadInfo, EmoteUploadInfo_UserEmoteUploadSource, FollowInfo, ImageModel, ImageModel_Content, LinkUser, Message, PrivilegeLogExtra, ProfilePicture, QuestionDetails, RankContainer, RankItem, SystemMessage, TopUser, TreasureBoxData, TreasureBoxUser, TreasureBoxUser2, TreasureBoxUser3, TreasureBoxUser4, User, UserBadge, UserBadgesAttributes, UserImageBadge, UserImageBadgeImage, WebcastBarrageMessage, WebcastBarrageMessage_Text, WebcastBarrageMessage_TextPiece, WebcastBarrageMessage_TextPieceUser, WebcastChatMessage, WebcastChatMessage_CommentQualityScore, WebcastChatMessage_CommentTag, WebcastChatMessage_UserIdentity, WebcastControlMessage, WebcastEmoteChatMessage, WebcastEnvelopeMessage, WebcastGiftMessage, WebcastGiftMessageGiftDetails, WebcastGiftMessageGiftExtra, WebcastGiftMessageGiftImage, WebcastHourlyRankMessage, WebcastInRoomBannerMessage, WebcastLikeMessage, WebcastLinkMicArmies, WebcastLinkMicArmiesGroup, WebcastLinkMicArmiesItems, WebcastLinkMicBattle, WebcastLinkMicBattleGroup, WebcastLinkMicBattleItems, WebcastLiveIntroMessage, WebcastMemberMessage, WebcastMessageEvent, WebcastMessageEventDetails, WebcastQuestionNewMessage, WebcastResponse, WebcastRoomUserSeqMessage, WebcastSocialMessage, WebcastSubEmote, WebcastSubNotifyMessage, WebcastWebsocketAck, WebcastWebsocketMessage, WebsocketParam, WeeklyRanking, protobufPackage };