moons-ta-client 1.2.3 → 1.3.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,2192 @@
1
+ import { WireType } from "@protobuf-ts/runtime";
2
+ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
3
+ import { reflectionMergePartial } from "@protobuf-ts/runtime";
4
+ import { MessageType } from "@protobuf-ts/runtime";
5
+ /**
6
+ * @generated from protobuf enum proto.replay.ReplayPlatform
7
+ */
8
+ export var ReplayPlatform;
9
+ (function (ReplayPlatform) {
10
+ /**
11
+ * @generated from protobuf enum value: REPLAY_PLATFORM_UNSPECIFIED = 0;
12
+ */
13
+ ReplayPlatform[ReplayPlatform["UNSPECIFIED"] = 0] = "UNSPECIFIED";
14
+ /**
15
+ * @generated from protobuf enum value: REPLAY_PLATFORM_STEAM = 1;
16
+ */
17
+ ReplayPlatform[ReplayPlatform["STEAM"] = 1] = "STEAM";
18
+ /**
19
+ * @generated from protobuf enum value: REPLAY_PLATFORM_OCULUS_PC = 2;
20
+ */
21
+ ReplayPlatform[ReplayPlatform["OCULUS_PC"] = 2] = "OCULUS_PC";
22
+ /**
23
+ * @generated from protobuf enum value: REPLAY_PLATFORM_META_QUEST = 3;
24
+ */
25
+ ReplayPlatform[ReplayPlatform["META_QUEST"] = 3] = "META_QUEST";
26
+ /**
27
+ * @generated from protobuf enum value: REPLAY_PLATFORM_DEV = 4;
28
+ */
29
+ ReplayPlatform[ReplayPlatform["DEV"] = 4] = "DEV";
30
+ })(ReplayPlatform = ReplayPlatform || (ReplayPlatform = {}));
31
+ /**
32
+ * @generated from protobuf enum proto.replay.ReplayNoteEventType
33
+ */
34
+ export var ReplayNoteEventType;
35
+ (function (ReplayNoteEventType) {
36
+ /**
37
+ * @generated from protobuf enum value: REPLAY_NOTE_EVENT_TYPE_UNSPECIFIED = 0;
38
+ */
39
+ ReplayNoteEventType[ReplayNoteEventType["UNSPECIFIED"] = 0] = "UNSPECIFIED";
40
+ /**
41
+ * @generated from protobuf enum value: REPLAY_NOTE_EVENT_TYPE_GOOD_CUT = 1;
42
+ */
43
+ ReplayNoteEventType[ReplayNoteEventType["GOOD_CUT"] = 1] = "GOOD_CUT";
44
+ /**
45
+ * @generated from protobuf enum value: REPLAY_NOTE_EVENT_TYPE_BAD_CUT = 2;
46
+ */
47
+ ReplayNoteEventType[ReplayNoteEventType["BAD_CUT"] = 2] = "BAD_CUT";
48
+ /**
49
+ * @generated from protobuf enum value: REPLAY_NOTE_EVENT_TYPE_MISS = 3;
50
+ */
51
+ ReplayNoteEventType[ReplayNoteEventType["MISS"] = 3] = "MISS";
52
+ /**
53
+ * @generated from protobuf enum value: REPLAY_NOTE_EVENT_TYPE_BOMB = 4;
54
+ */
55
+ ReplayNoteEventType[ReplayNoteEventType["BOMB"] = 4] = "BOMB";
56
+ })(ReplayNoteEventType = ReplayNoteEventType || (ReplayNoteEventType = {}));
57
+ /**
58
+ * @generated from protobuf enum proto.replay.ReplayCompletion
59
+ */
60
+ export var ReplayCompletion;
61
+ (function (ReplayCompletion) {
62
+ /**
63
+ * @generated from protobuf enum value: REPLAY_COMPLETION_UNSPECIFIED = 0;
64
+ */
65
+ ReplayCompletion[ReplayCompletion["UNSPECIFIED"] = 0] = "UNSPECIFIED";
66
+ /**
67
+ * @generated from protobuf enum value: REPLAY_COMPLETION_PASSED = 1;
68
+ */
69
+ ReplayCompletion[ReplayCompletion["PASSED"] = 1] = "PASSED";
70
+ /**
71
+ * @generated from protobuf enum value: REPLAY_COMPLETION_FAILED = 2;
72
+ */
73
+ ReplayCompletion[ReplayCompletion["FAILED"] = 2] = "FAILED";
74
+ /**
75
+ * @generated from protobuf enum value: REPLAY_COMPLETION_QUIT = 3;
76
+ */
77
+ ReplayCompletion[ReplayCompletion["QUIT"] = 3] = "QUIT";
78
+ /**
79
+ * @generated from protobuf enum value: REPLAY_COMPLETION_ABORTED = 4;
80
+ */
81
+ ReplayCompletion[ReplayCompletion["ABORTED"] = 4] = "ABORTED";
82
+ })(ReplayCompletion = ReplayCompletion || (ReplayCompletion = {}));
83
+ // @generated message type with reflection information, may provide speed optimized methods
84
+ class ReplayStreamPacket$Type extends MessageType {
85
+ constructor() {
86
+ super("proto.replay.ReplayStreamPacket", [
87
+ { no: 1, name: "stream_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
88
+ { no: 2, name: "connection_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
89
+ { no: 3, name: "player_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
90
+ { no: 4, name: "match_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
91
+ { no: 10, name: "start", kind: "message", oneof: "body", T: () => ReplayStreamStart },
92
+ { no: 11, name: "chunk", kind: "message", oneof: "body", T: () => ReplayChunk },
93
+ { no: 13, name: "end", kind: "message", oneof: "body", T: () => ReplayStreamEnd }
94
+ ]);
95
+ }
96
+ create(value) {
97
+ const message = globalThis.Object.create((this.messagePrototype));
98
+ message.streamId = "";
99
+ message.connectionId = "";
100
+ message.playerId = "";
101
+ message.matchId = "";
102
+ message.body = { oneofKind: undefined };
103
+ if (value !== undefined)
104
+ reflectionMergePartial(this, message, value);
105
+ return message;
106
+ }
107
+ internalBinaryRead(reader, length, options, target) {
108
+ let message = target ?? this.create(), end = reader.pos + length;
109
+ while (reader.pos < end) {
110
+ let [fieldNo, wireType] = reader.tag();
111
+ switch (fieldNo) {
112
+ case /* string stream_id */ 1:
113
+ message.streamId = reader.string();
114
+ break;
115
+ case /* string connection_id */ 2:
116
+ message.connectionId = reader.string();
117
+ break;
118
+ case /* string player_id */ 3:
119
+ message.playerId = reader.string();
120
+ break;
121
+ case /* string match_id */ 4:
122
+ message.matchId = reader.string();
123
+ break;
124
+ case /* proto.replay.ReplayStreamStart start */ 10:
125
+ message.body = {
126
+ oneofKind: "start",
127
+ start: ReplayStreamStart.internalBinaryRead(reader, reader.uint32(), options, message.body.start)
128
+ };
129
+ break;
130
+ case /* proto.replay.ReplayChunk chunk */ 11:
131
+ message.body = {
132
+ oneofKind: "chunk",
133
+ chunk: ReplayChunk.internalBinaryRead(reader, reader.uint32(), options, message.body.chunk)
134
+ };
135
+ break;
136
+ case /* proto.replay.ReplayStreamEnd end */ 13:
137
+ message.body = {
138
+ oneofKind: "end",
139
+ end: ReplayStreamEnd.internalBinaryRead(reader, reader.uint32(), options, message.body.end)
140
+ };
141
+ break;
142
+ default:
143
+ let u = options.readUnknownField;
144
+ if (u === "throw")
145
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
146
+ let d = reader.skip(wireType);
147
+ if (u !== false)
148
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
149
+ }
150
+ }
151
+ return message;
152
+ }
153
+ internalBinaryWrite(message, writer, options) {
154
+ /* string stream_id = 1; */
155
+ if (message.streamId !== "")
156
+ writer.tag(1, WireType.LengthDelimited).string(message.streamId);
157
+ /* string connection_id = 2; */
158
+ if (message.connectionId !== "")
159
+ writer.tag(2, WireType.LengthDelimited).string(message.connectionId);
160
+ /* string player_id = 3; */
161
+ if (message.playerId !== "")
162
+ writer.tag(3, WireType.LengthDelimited).string(message.playerId);
163
+ /* string match_id = 4; */
164
+ if (message.matchId !== "")
165
+ writer.tag(4, WireType.LengthDelimited).string(message.matchId);
166
+ /* proto.replay.ReplayStreamStart start = 10; */
167
+ if (message.body.oneofKind === "start")
168
+ ReplayStreamStart.internalBinaryWrite(message.body.start, writer.tag(10, WireType.LengthDelimited).fork(), options).join();
169
+ /* proto.replay.ReplayChunk chunk = 11; */
170
+ if (message.body.oneofKind === "chunk")
171
+ ReplayChunk.internalBinaryWrite(message.body.chunk, writer.tag(11, WireType.LengthDelimited).fork(), options).join();
172
+ /* proto.replay.ReplayStreamEnd end = 13; */
173
+ if (message.body.oneofKind === "end")
174
+ ReplayStreamEnd.internalBinaryWrite(message.body.end, writer.tag(13, WireType.LengthDelimited).fork(), options).join();
175
+ let u = options.writeUnknownFields;
176
+ if (u !== false)
177
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
178
+ return writer;
179
+ }
180
+ }
181
+ /**
182
+ * @generated MessageType for protobuf message proto.replay.ReplayStreamPacket
183
+ */
184
+ export const ReplayStreamPacket = new ReplayStreamPacket$Type();
185
+ // @generated message type with reflection information, may provide speed optimized methods
186
+ class ReplayStreamStart$Type extends MessageType {
187
+ constructor() {
188
+ super("proto.replay.ReplayStreamStart", [
189
+ { no: 1, name: "protocol_version", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
190
+ { no: 2, name: "player", kind: "message", T: () => PlayerIdentity },
191
+ { no: 3, name: "beatmap", kind: "message", T: () => BeatmapIdentity },
192
+ { no: 9, name: "client_start_time_unix_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ },
193
+ { no: 10, name: "server_start_time_unix_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ },
194
+ { no: 11, name: "game_session_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
195
+ { no: 13, name: "replay_metadata", kind: "message", T: () => StreamReplayMetadata }
196
+ ]);
197
+ }
198
+ create(value) {
199
+ const message = globalThis.Object.create((this.messagePrototype));
200
+ message.protocolVersion = 0;
201
+ message.clientStartTimeUnixMs = 0n;
202
+ message.serverStartTimeUnixMs = 0n;
203
+ message.gameSessionId = "";
204
+ if (value !== undefined)
205
+ reflectionMergePartial(this, message, value);
206
+ return message;
207
+ }
208
+ internalBinaryRead(reader, length, options, target) {
209
+ let message = target ?? this.create(), end = reader.pos + length;
210
+ while (reader.pos < end) {
211
+ let [fieldNo, wireType] = reader.tag();
212
+ switch (fieldNo) {
213
+ case /* uint32 protocol_version */ 1:
214
+ message.protocolVersion = reader.uint32();
215
+ break;
216
+ case /* proto.replay.PlayerIdentity player */ 2:
217
+ message.player = PlayerIdentity.internalBinaryRead(reader, reader.uint32(), options, message.player);
218
+ break;
219
+ case /* proto.replay.BeatmapIdentity beatmap */ 3:
220
+ message.beatmap = BeatmapIdentity.internalBinaryRead(reader, reader.uint32(), options, message.beatmap);
221
+ break;
222
+ case /* int64 client_start_time_unix_ms */ 9:
223
+ message.clientStartTimeUnixMs = reader.int64().toBigInt();
224
+ break;
225
+ case /* int64 server_start_time_unix_ms */ 10:
226
+ message.serverStartTimeUnixMs = reader.int64().toBigInt();
227
+ break;
228
+ case /* string game_session_id */ 11:
229
+ message.gameSessionId = reader.string();
230
+ break;
231
+ case /* proto.replay.StreamReplayMetadata replay_metadata */ 13:
232
+ message.replayMetadata = StreamReplayMetadata.internalBinaryRead(reader, reader.uint32(), options, message.replayMetadata);
233
+ break;
234
+ default:
235
+ let u = options.readUnknownField;
236
+ if (u === "throw")
237
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
238
+ let d = reader.skip(wireType);
239
+ if (u !== false)
240
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
241
+ }
242
+ }
243
+ return message;
244
+ }
245
+ internalBinaryWrite(message, writer, options) {
246
+ /* uint32 protocol_version = 1; */
247
+ if (message.protocolVersion !== 0)
248
+ writer.tag(1, WireType.Varint).uint32(message.protocolVersion);
249
+ /* proto.replay.PlayerIdentity player = 2; */
250
+ if (message.player)
251
+ PlayerIdentity.internalBinaryWrite(message.player, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
252
+ /* proto.replay.BeatmapIdentity beatmap = 3; */
253
+ if (message.beatmap)
254
+ BeatmapIdentity.internalBinaryWrite(message.beatmap, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
255
+ /* int64 client_start_time_unix_ms = 9; */
256
+ if (message.clientStartTimeUnixMs !== 0n)
257
+ writer.tag(9, WireType.Varint).int64(message.clientStartTimeUnixMs);
258
+ /* int64 server_start_time_unix_ms = 10; */
259
+ if (message.serverStartTimeUnixMs !== 0n)
260
+ writer.tag(10, WireType.Varint).int64(message.serverStartTimeUnixMs);
261
+ /* string game_session_id = 11; */
262
+ if (message.gameSessionId !== "")
263
+ writer.tag(11, WireType.LengthDelimited).string(message.gameSessionId);
264
+ /* proto.replay.StreamReplayMetadata replay_metadata = 13; */
265
+ if (message.replayMetadata)
266
+ StreamReplayMetadata.internalBinaryWrite(message.replayMetadata, writer.tag(13, WireType.LengthDelimited).fork(), options).join();
267
+ let u = options.writeUnknownFields;
268
+ if (u !== false)
269
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
270
+ return writer;
271
+ }
272
+ }
273
+ /**
274
+ * @generated MessageType for protobuf message proto.replay.ReplayStreamStart
275
+ */
276
+ export const ReplayStreamStart = new ReplayStreamStart$Type();
277
+ // @generated message type with reflection information, may provide speed optimized methods
278
+ class PlayerIdentity$Type extends MessageType {
279
+ constructor() {
280
+ super("proto.replay.PlayerIdentity", [
281
+ { no: 1, name: "player_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
282
+ { no: 2, name: "platform", kind: "enum", T: () => ["proto.replay.ReplayPlatform", ReplayPlatform, "REPLAY_PLATFORM_"] },
283
+ { no: 3, name: "game_version", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
284
+ { no: 4, name: "client_version", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
285
+ ]);
286
+ }
287
+ create(value) {
288
+ const message = globalThis.Object.create((this.messagePrototype));
289
+ message.playerId = "";
290
+ message.platform = 0;
291
+ message.gameVersion = "";
292
+ message.clientVersion = "";
293
+ if (value !== undefined)
294
+ reflectionMergePartial(this, message, value);
295
+ return message;
296
+ }
297
+ internalBinaryRead(reader, length, options, target) {
298
+ let message = target ?? this.create(), end = reader.pos + length;
299
+ while (reader.pos < end) {
300
+ let [fieldNo, wireType] = reader.tag();
301
+ switch (fieldNo) {
302
+ case /* string player_id */ 1:
303
+ message.playerId = reader.string();
304
+ break;
305
+ case /* proto.replay.ReplayPlatform platform */ 2:
306
+ message.platform = reader.int32();
307
+ break;
308
+ case /* string game_version */ 3:
309
+ message.gameVersion = reader.string();
310
+ break;
311
+ case /* string client_version */ 4:
312
+ message.clientVersion = reader.string();
313
+ break;
314
+ default:
315
+ let u = options.readUnknownField;
316
+ if (u === "throw")
317
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
318
+ let d = reader.skip(wireType);
319
+ if (u !== false)
320
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
321
+ }
322
+ }
323
+ return message;
324
+ }
325
+ internalBinaryWrite(message, writer, options) {
326
+ /* string player_id = 1; */
327
+ if (message.playerId !== "")
328
+ writer.tag(1, WireType.LengthDelimited).string(message.playerId);
329
+ /* proto.replay.ReplayPlatform platform = 2; */
330
+ if (message.platform !== 0)
331
+ writer.tag(2, WireType.Varint).int32(message.platform);
332
+ /* string game_version = 3; */
333
+ if (message.gameVersion !== "")
334
+ writer.tag(3, WireType.LengthDelimited).string(message.gameVersion);
335
+ /* string client_version = 4; */
336
+ if (message.clientVersion !== "")
337
+ writer.tag(4, WireType.LengthDelimited).string(message.clientVersion);
338
+ let u = options.writeUnknownFields;
339
+ if (u !== false)
340
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
341
+ return writer;
342
+ }
343
+ }
344
+ /**
345
+ * @generated MessageType for protobuf message proto.replay.PlayerIdentity
346
+ */
347
+ export const PlayerIdentity = new PlayerIdentity$Type();
348
+ // @generated message type with reflection information, may provide speed optimized methods
349
+ class BeatmapIdentity$Type extends MessageType {
350
+ constructor() {
351
+ super("proto.replay.BeatmapIdentity", [
352
+ { no: 1, name: "map_hash", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
353
+ { no: 2, name: "level_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
354
+ { no: 3, name: "difficulty", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
355
+ { no: 4, name: "difficulty_name", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
356
+ { no: 5, name: "characteristic", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
357
+ { no: 7, name: "modifiers", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
358
+ { no: 8, name: "max_score", kind: "scalar", T: 13 /*ScalarType.UINT32*/ }
359
+ ]);
360
+ }
361
+ create(value) {
362
+ const message = globalThis.Object.create((this.messagePrototype));
363
+ message.mapHash = "";
364
+ message.levelId = "";
365
+ message.difficulty = 0;
366
+ message.difficultyName = "";
367
+ message.characteristic = "";
368
+ message.modifiers = [];
369
+ message.maxScore = 0;
370
+ if (value !== undefined)
371
+ reflectionMergePartial(this, message, value);
372
+ return message;
373
+ }
374
+ internalBinaryRead(reader, length, options, target) {
375
+ let message = target ?? this.create(), end = reader.pos + length;
376
+ while (reader.pos < end) {
377
+ let [fieldNo, wireType] = reader.tag();
378
+ switch (fieldNo) {
379
+ case /* string map_hash */ 1:
380
+ message.mapHash = reader.string();
381
+ break;
382
+ case /* string level_id */ 2:
383
+ message.levelId = reader.string();
384
+ break;
385
+ case /* int32 difficulty */ 3:
386
+ message.difficulty = reader.int32();
387
+ break;
388
+ case /* string difficulty_name */ 4:
389
+ message.difficultyName = reader.string();
390
+ break;
391
+ case /* string characteristic */ 5:
392
+ message.characteristic = reader.string();
393
+ break;
394
+ case /* repeated string modifiers */ 7:
395
+ message.modifiers.push(reader.string());
396
+ break;
397
+ case /* uint32 max_score */ 8:
398
+ message.maxScore = reader.uint32();
399
+ break;
400
+ default:
401
+ let u = options.readUnknownField;
402
+ if (u === "throw")
403
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
404
+ let d = reader.skip(wireType);
405
+ if (u !== false)
406
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
407
+ }
408
+ }
409
+ return message;
410
+ }
411
+ internalBinaryWrite(message, writer, options) {
412
+ /* string map_hash = 1; */
413
+ if (message.mapHash !== "")
414
+ writer.tag(1, WireType.LengthDelimited).string(message.mapHash);
415
+ /* string level_id = 2; */
416
+ if (message.levelId !== "")
417
+ writer.tag(2, WireType.LengthDelimited).string(message.levelId);
418
+ /* int32 difficulty = 3; */
419
+ if (message.difficulty !== 0)
420
+ writer.tag(3, WireType.Varint).int32(message.difficulty);
421
+ /* string difficulty_name = 4; */
422
+ if (message.difficultyName !== "")
423
+ writer.tag(4, WireType.LengthDelimited).string(message.difficultyName);
424
+ /* string characteristic = 5; */
425
+ if (message.characteristic !== "")
426
+ writer.tag(5, WireType.LengthDelimited).string(message.characteristic);
427
+ /* repeated string modifiers = 7; */
428
+ for (let i = 0; i < message.modifiers.length; i++)
429
+ writer.tag(7, WireType.LengthDelimited).string(message.modifiers[i]);
430
+ /* uint32 max_score = 8; */
431
+ if (message.maxScore !== 0)
432
+ writer.tag(8, WireType.Varint).uint32(message.maxScore);
433
+ let u = options.writeUnknownFields;
434
+ if (u !== false)
435
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
436
+ return writer;
437
+ }
438
+ }
439
+ /**
440
+ * @generated MessageType for protobuf message proto.replay.BeatmapIdentity
441
+ */
442
+ export const BeatmapIdentity = new BeatmapIdentity$Type();
443
+ // @generated message type with reflection information, may provide speed optimized methods
444
+ class ReplayCursor$Type extends MessageType {
445
+ constructor() {
446
+ super("proto.replay.ReplayCursor", [
447
+ { no: 1, name: "sequence", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
448
+ { no: 2, name: "song_time_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ },
449
+ { no: 3, name: "server_time_unix_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ },
450
+ { no: 4, name: "client_time_unix_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }
451
+ ]);
452
+ }
453
+ create(value) {
454
+ const message = globalThis.Object.create((this.messagePrototype));
455
+ message.sequence = 0n;
456
+ message.songTimeMs = 0n;
457
+ message.serverTimeUnixMs = 0n;
458
+ message.clientTimeUnixMs = 0n;
459
+ if (value !== undefined)
460
+ reflectionMergePartial(this, message, value);
461
+ return message;
462
+ }
463
+ internalBinaryRead(reader, length, options, target) {
464
+ let message = target ?? this.create(), end = reader.pos + length;
465
+ while (reader.pos < end) {
466
+ let [fieldNo, wireType] = reader.tag();
467
+ switch (fieldNo) {
468
+ case /* uint64 sequence */ 1:
469
+ message.sequence = reader.uint64().toBigInt();
470
+ break;
471
+ case /* int64 song_time_ms */ 2:
472
+ message.songTimeMs = reader.int64().toBigInt();
473
+ break;
474
+ case /* int64 server_time_unix_ms */ 3:
475
+ message.serverTimeUnixMs = reader.int64().toBigInt();
476
+ break;
477
+ case /* int64 client_time_unix_ms */ 4:
478
+ message.clientTimeUnixMs = reader.int64().toBigInt();
479
+ break;
480
+ default:
481
+ let u = options.readUnknownField;
482
+ if (u === "throw")
483
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
484
+ let d = reader.skip(wireType);
485
+ if (u !== false)
486
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
487
+ }
488
+ }
489
+ return message;
490
+ }
491
+ internalBinaryWrite(message, writer, options) {
492
+ /* uint64 sequence = 1; */
493
+ if (message.sequence !== 0n)
494
+ writer.tag(1, WireType.Varint).uint64(message.sequence);
495
+ /* int64 song_time_ms = 2; */
496
+ if (message.songTimeMs !== 0n)
497
+ writer.tag(2, WireType.Varint).int64(message.songTimeMs);
498
+ /* int64 server_time_unix_ms = 3; */
499
+ if (message.serverTimeUnixMs !== 0n)
500
+ writer.tag(3, WireType.Varint).int64(message.serverTimeUnixMs);
501
+ /* int64 client_time_unix_ms = 4; */
502
+ if (message.clientTimeUnixMs !== 0n)
503
+ writer.tag(4, WireType.Varint).int64(message.clientTimeUnixMs);
504
+ let u = options.writeUnknownFields;
505
+ if (u !== false)
506
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
507
+ return writer;
508
+ }
509
+ }
510
+ /**
511
+ * @generated MessageType for protobuf message proto.replay.ReplayCursor
512
+ */
513
+ export const ReplayCursor = new ReplayCursor$Type();
514
+ // @generated message type with reflection information, may provide speed optimized methods
515
+ class ReplayChunk$Type extends MessageType {
516
+ constructor() {
517
+ super("proto.replay.ReplayChunk", [
518
+ { no: 1, name: "cursor", kind: "message", T: () => ReplayCursor },
519
+ { no: 2, name: "events", kind: "message", T: () => StreamReplayEventBatch },
520
+ { no: 3, name: "cumulative_event_counts", kind: "message", T: () => ReplayEventCounts }
521
+ ]);
522
+ }
523
+ create(value) {
524
+ const message = globalThis.Object.create((this.messagePrototype));
525
+ if (value !== undefined)
526
+ reflectionMergePartial(this, message, value);
527
+ return message;
528
+ }
529
+ internalBinaryRead(reader, length, options, target) {
530
+ let message = target ?? this.create(), end = reader.pos + length;
531
+ while (reader.pos < end) {
532
+ let [fieldNo, wireType] = reader.tag();
533
+ switch (fieldNo) {
534
+ case /* proto.replay.ReplayCursor cursor */ 1:
535
+ message.cursor = ReplayCursor.internalBinaryRead(reader, reader.uint32(), options, message.cursor);
536
+ break;
537
+ case /* proto.replay.StreamReplayEventBatch events */ 2:
538
+ message.events = StreamReplayEventBatch.internalBinaryRead(reader, reader.uint32(), options, message.events);
539
+ break;
540
+ case /* proto.replay.ReplayEventCounts cumulative_event_counts */ 3:
541
+ message.cumulativeEventCounts = ReplayEventCounts.internalBinaryRead(reader, reader.uint32(), options, message.cumulativeEventCounts);
542
+ break;
543
+ default:
544
+ let u = options.readUnknownField;
545
+ if (u === "throw")
546
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
547
+ let d = reader.skip(wireType);
548
+ if (u !== false)
549
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
550
+ }
551
+ }
552
+ return message;
553
+ }
554
+ internalBinaryWrite(message, writer, options) {
555
+ /* proto.replay.ReplayCursor cursor = 1; */
556
+ if (message.cursor)
557
+ ReplayCursor.internalBinaryWrite(message.cursor, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
558
+ /* proto.replay.StreamReplayEventBatch events = 2; */
559
+ if (message.events)
560
+ StreamReplayEventBatch.internalBinaryWrite(message.events, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
561
+ /* proto.replay.ReplayEventCounts cumulative_event_counts = 3; */
562
+ if (message.cumulativeEventCounts)
563
+ ReplayEventCounts.internalBinaryWrite(message.cumulativeEventCounts, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
564
+ let u = options.writeUnknownFields;
565
+ if (u !== false)
566
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
567
+ return writer;
568
+ }
569
+ }
570
+ /**
571
+ * @generated MessageType for protobuf message proto.replay.ReplayChunk
572
+ */
573
+ export const ReplayChunk = new ReplayChunk$Type();
574
+ // @generated message type with reflection information, may provide speed optimized methods
575
+ class ReplayStreamEnd$Type extends MessageType {
576
+ constructor() {
577
+ super("proto.replay.ReplayStreamEnd", [
578
+ { no: 1, name: "cursor", kind: "message", T: () => ReplayCursor },
579
+ { no: 2, name: "completion", kind: "enum", T: () => ["proto.replay.ReplayCompletion", ReplayCompletion, "REPLAY_COMPLETION_"] },
580
+ { no: 3, name: "score", kind: "message", T: () => ReplayScoreSummary },
581
+ { no: 5, name: "chunk_count", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
582
+ { no: 6, name: "cumulative_event_counts", kind: "message", T: () => ReplayEventCounts }
583
+ ]);
584
+ }
585
+ create(value) {
586
+ const message = globalThis.Object.create((this.messagePrototype));
587
+ message.completion = 0;
588
+ message.chunkCount = 0n;
589
+ if (value !== undefined)
590
+ reflectionMergePartial(this, message, value);
591
+ return message;
592
+ }
593
+ internalBinaryRead(reader, length, options, target) {
594
+ let message = target ?? this.create(), end = reader.pos + length;
595
+ while (reader.pos < end) {
596
+ let [fieldNo, wireType] = reader.tag();
597
+ switch (fieldNo) {
598
+ case /* proto.replay.ReplayCursor cursor */ 1:
599
+ message.cursor = ReplayCursor.internalBinaryRead(reader, reader.uint32(), options, message.cursor);
600
+ break;
601
+ case /* proto.replay.ReplayCompletion completion */ 2:
602
+ message.completion = reader.int32();
603
+ break;
604
+ case /* proto.replay.ReplayScoreSummary score */ 3:
605
+ message.score = ReplayScoreSummary.internalBinaryRead(reader, reader.uint32(), options, message.score);
606
+ break;
607
+ case /* uint64 chunk_count */ 5:
608
+ message.chunkCount = reader.uint64().toBigInt();
609
+ break;
610
+ case /* proto.replay.ReplayEventCounts cumulative_event_counts */ 6:
611
+ message.cumulativeEventCounts = ReplayEventCounts.internalBinaryRead(reader, reader.uint32(), options, message.cumulativeEventCounts);
612
+ break;
613
+ default:
614
+ let u = options.readUnknownField;
615
+ if (u === "throw")
616
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
617
+ let d = reader.skip(wireType);
618
+ if (u !== false)
619
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
620
+ }
621
+ }
622
+ return message;
623
+ }
624
+ internalBinaryWrite(message, writer, options) {
625
+ /* proto.replay.ReplayCursor cursor = 1; */
626
+ if (message.cursor)
627
+ ReplayCursor.internalBinaryWrite(message.cursor, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
628
+ /* proto.replay.ReplayCompletion completion = 2; */
629
+ if (message.completion !== 0)
630
+ writer.tag(2, WireType.Varint).int32(message.completion);
631
+ /* proto.replay.ReplayScoreSummary score = 3; */
632
+ if (message.score)
633
+ ReplayScoreSummary.internalBinaryWrite(message.score, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
634
+ /* uint64 chunk_count = 5; */
635
+ if (message.chunkCount !== 0n)
636
+ writer.tag(5, WireType.Varint).uint64(message.chunkCount);
637
+ /* proto.replay.ReplayEventCounts cumulative_event_counts = 6; */
638
+ if (message.cumulativeEventCounts)
639
+ ReplayEventCounts.internalBinaryWrite(message.cumulativeEventCounts, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
640
+ let u = options.writeUnknownFields;
641
+ if (u !== false)
642
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
643
+ return writer;
644
+ }
645
+ }
646
+ /**
647
+ * @generated MessageType for protobuf message proto.replay.ReplayStreamEnd
648
+ */
649
+ export const ReplayStreamEnd = new ReplayStreamEnd$Type();
650
+ // @generated message type with reflection information, may provide speed optimized methods
651
+ class StreamReplayMetadata$Type extends MessageType {
652
+ constructor() {
653
+ super("proto.replay.StreamReplayMetadata", [
654
+ { no: 1, name: "replay_version", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
655
+ { no: 2, name: "level_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
656
+ { no: 3, name: "difficulty", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
657
+ { no: 4, name: "characteristic", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
658
+ { no: 5, name: "environment", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
659
+ { no: 6, name: "modifiers", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
660
+ { no: 7, name: "note_spawn_offset", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
661
+ { no: 8, name: "left_handed", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
662
+ { no: 9, name: "initial_height", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
663
+ { no: 10, name: "room_rotation", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
664
+ { no: 11, name: "room_center", kind: "message", T: () => ReplayVector3 },
665
+ { no: 13, name: "game_version", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
666
+ { no: 14, name: "plugin_version", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
667
+ { no: 15, name: "platform", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
668
+ { no: 16, name: "song_speed", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
669
+ { no: 17, name: "jump_distance", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
670
+ { no: 18, name: "left_saber_color", kind: "message", T: () => ReplayColor },
671
+ { no: 19, name: "right_saber_color", kind: "message", T: () => ReplayColor },
672
+ { no: 20, name: "environment_override", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
673
+ { no: 21, name: "color_scheme_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
674
+ ]);
675
+ }
676
+ create(value) {
677
+ const message = globalThis.Object.create((this.messagePrototype));
678
+ message.replayVersion = "";
679
+ message.levelId = "";
680
+ message.difficulty = 0;
681
+ message.characteristic = "";
682
+ message.environment = "";
683
+ message.modifiers = [];
684
+ message.noteSpawnOffset = 0;
685
+ message.leftHanded = false;
686
+ message.initialHeight = 0;
687
+ message.roomRotation = 0;
688
+ message.gameVersion = "";
689
+ message.pluginVersion = "";
690
+ message.platform = "";
691
+ message.songSpeed = 0;
692
+ message.jumpDistance = 0;
693
+ message.environmentOverride = "";
694
+ message.colorSchemeId = "";
695
+ if (value !== undefined)
696
+ reflectionMergePartial(this, message, value);
697
+ return message;
698
+ }
699
+ internalBinaryRead(reader, length, options, target) {
700
+ let message = target ?? this.create(), end = reader.pos + length;
701
+ while (reader.pos < end) {
702
+ let [fieldNo, wireType] = reader.tag();
703
+ switch (fieldNo) {
704
+ case /* string replay_version */ 1:
705
+ message.replayVersion = reader.string();
706
+ break;
707
+ case /* string level_id */ 2:
708
+ message.levelId = reader.string();
709
+ break;
710
+ case /* int32 difficulty */ 3:
711
+ message.difficulty = reader.int32();
712
+ break;
713
+ case /* string characteristic */ 4:
714
+ message.characteristic = reader.string();
715
+ break;
716
+ case /* string environment */ 5:
717
+ message.environment = reader.string();
718
+ break;
719
+ case /* repeated string modifiers */ 6:
720
+ message.modifiers.push(reader.string());
721
+ break;
722
+ case /* float note_spawn_offset */ 7:
723
+ message.noteSpawnOffset = reader.float();
724
+ break;
725
+ case /* bool left_handed */ 8:
726
+ message.leftHanded = reader.bool();
727
+ break;
728
+ case /* float initial_height */ 9:
729
+ message.initialHeight = reader.float();
730
+ break;
731
+ case /* float room_rotation */ 10:
732
+ message.roomRotation = reader.float();
733
+ break;
734
+ case /* proto.replay.ReplayVector3 room_center */ 11:
735
+ message.roomCenter = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.roomCenter);
736
+ break;
737
+ case /* string game_version */ 13:
738
+ message.gameVersion = reader.string();
739
+ break;
740
+ case /* string plugin_version */ 14:
741
+ message.pluginVersion = reader.string();
742
+ break;
743
+ case /* string platform */ 15:
744
+ message.platform = reader.string();
745
+ break;
746
+ case /* float song_speed */ 16:
747
+ message.songSpeed = reader.float();
748
+ break;
749
+ case /* float jump_distance */ 17:
750
+ message.jumpDistance = reader.float();
751
+ break;
752
+ case /* proto.replay.ReplayColor left_saber_color */ 18:
753
+ message.leftSaberColor = ReplayColor.internalBinaryRead(reader, reader.uint32(), options, message.leftSaberColor);
754
+ break;
755
+ case /* proto.replay.ReplayColor right_saber_color */ 19:
756
+ message.rightSaberColor = ReplayColor.internalBinaryRead(reader, reader.uint32(), options, message.rightSaberColor);
757
+ break;
758
+ case /* string environment_override */ 20:
759
+ message.environmentOverride = reader.string();
760
+ break;
761
+ case /* string color_scheme_id */ 21:
762
+ message.colorSchemeId = reader.string();
763
+ break;
764
+ default:
765
+ let u = options.readUnknownField;
766
+ if (u === "throw")
767
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
768
+ let d = reader.skip(wireType);
769
+ if (u !== false)
770
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
771
+ }
772
+ }
773
+ return message;
774
+ }
775
+ internalBinaryWrite(message, writer, options) {
776
+ /* string replay_version = 1; */
777
+ if (message.replayVersion !== "")
778
+ writer.tag(1, WireType.LengthDelimited).string(message.replayVersion);
779
+ /* string level_id = 2; */
780
+ if (message.levelId !== "")
781
+ writer.tag(2, WireType.LengthDelimited).string(message.levelId);
782
+ /* int32 difficulty = 3; */
783
+ if (message.difficulty !== 0)
784
+ writer.tag(3, WireType.Varint).int32(message.difficulty);
785
+ /* string characteristic = 4; */
786
+ if (message.characteristic !== "")
787
+ writer.tag(4, WireType.LengthDelimited).string(message.characteristic);
788
+ /* string environment = 5; */
789
+ if (message.environment !== "")
790
+ writer.tag(5, WireType.LengthDelimited).string(message.environment);
791
+ /* repeated string modifiers = 6; */
792
+ for (let i = 0; i < message.modifiers.length; i++)
793
+ writer.tag(6, WireType.LengthDelimited).string(message.modifiers[i]);
794
+ /* float note_spawn_offset = 7; */
795
+ if (message.noteSpawnOffset !== 0)
796
+ writer.tag(7, WireType.Bit32).float(message.noteSpawnOffset);
797
+ /* bool left_handed = 8; */
798
+ if (message.leftHanded !== false)
799
+ writer.tag(8, WireType.Varint).bool(message.leftHanded);
800
+ /* float initial_height = 9; */
801
+ if (message.initialHeight !== 0)
802
+ writer.tag(9, WireType.Bit32).float(message.initialHeight);
803
+ /* float room_rotation = 10; */
804
+ if (message.roomRotation !== 0)
805
+ writer.tag(10, WireType.Bit32).float(message.roomRotation);
806
+ /* proto.replay.ReplayVector3 room_center = 11; */
807
+ if (message.roomCenter)
808
+ ReplayVector3.internalBinaryWrite(message.roomCenter, writer.tag(11, WireType.LengthDelimited).fork(), options).join();
809
+ /* string game_version = 13; */
810
+ if (message.gameVersion !== "")
811
+ writer.tag(13, WireType.LengthDelimited).string(message.gameVersion);
812
+ /* string plugin_version = 14; */
813
+ if (message.pluginVersion !== "")
814
+ writer.tag(14, WireType.LengthDelimited).string(message.pluginVersion);
815
+ /* string platform = 15; */
816
+ if (message.platform !== "")
817
+ writer.tag(15, WireType.LengthDelimited).string(message.platform);
818
+ /* float song_speed = 16; */
819
+ if (message.songSpeed !== 0)
820
+ writer.tag(16, WireType.Bit32).float(message.songSpeed);
821
+ /* float jump_distance = 17; */
822
+ if (message.jumpDistance !== 0)
823
+ writer.tag(17, WireType.Bit32).float(message.jumpDistance);
824
+ /* proto.replay.ReplayColor left_saber_color = 18; */
825
+ if (message.leftSaberColor)
826
+ ReplayColor.internalBinaryWrite(message.leftSaberColor, writer.tag(18, WireType.LengthDelimited).fork(), options).join();
827
+ /* proto.replay.ReplayColor right_saber_color = 19; */
828
+ if (message.rightSaberColor)
829
+ ReplayColor.internalBinaryWrite(message.rightSaberColor, writer.tag(19, WireType.LengthDelimited).fork(), options).join();
830
+ /* string environment_override = 20; */
831
+ if (message.environmentOverride !== "")
832
+ writer.tag(20, WireType.LengthDelimited).string(message.environmentOverride);
833
+ /* string color_scheme_id = 21; */
834
+ if (message.colorSchemeId !== "")
835
+ writer.tag(21, WireType.LengthDelimited).string(message.colorSchemeId);
836
+ let u = options.writeUnknownFields;
837
+ if (u !== false)
838
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
839
+ return writer;
840
+ }
841
+ }
842
+ /**
843
+ * @generated MessageType for protobuf message proto.replay.StreamReplayMetadata
844
+ */
845
+ export const StreamReplayMetadata = new StreamReplayMetadata$Type();
846
+ // @generated message type with reflection information, may provide speed optimized methods
847
+ class StreamReplayEventBatch$Type extends MessageType {
848
+ constructor() {
849
+ super("proto.replay.StreamReplayEventBatch", [
850
+ { no: 1, name: "pose_frames", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayPoseFrame },
851
+ { no: 2, name: "height_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayHeightEvent },
852
+ { no: 3, name: "note_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayNoteEvent },
853
+ { no: 4, name: "score_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayScoreEvent },
854
+ { no: 5, name: "combo_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayComboEvent },
855
+ { no: 6, name: "multiplier_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayMultiplierEvent },
856
+ { no: 7, name: "energy_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayEnergyEvent },
857
+ { no: 8, name: "min_time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
858
+ { no: 9, name: "max_time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
859
+ { no: 10, name: "pause_events", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => ReplayPauseEvent }
860
+ ]);
861
+ }
862
+ create(value) {
863
+ const message = globalThis.Object.create((this.messagePrototype));
864
+ message.poseFrames = [];
865
+ message.heightEvents = [];
866
+ message.noteEvents = [];
867
+ message.scoreEvents = [];
868
+ message.comboEvents = [];
869
+ message.multiplierEvents = [];
870
+ message.energyEvents = [];
871
+ message.minTimeSeconds = 0;
872
+ message.maxTimeSeconds = 0;
873
+ message.pauseEvents = [];
874
+ if (value !== undefined)
875
+ reflectionMergePartial(this, message, value);
876
+ return message;
877
+ }
878
+ internalBinaryRead(reader, length, options, target) {
879
+ let message = target ?? this.create(), end = reader.pos + length;
880
+ while (reader.pos < end) {
881
+ let [fieldNo, wireType] = reader.tag();
882
+ switch (fieldNo) {
883
+ case /* repeated proto.replay.ReplayPoseFrame pose_frames */ 1:
884
+ message.poseFrames.push(ReplayPoseFrame.internalBinaryRead(reader, reader.uint32(), options));
885
+ break;
886
+ case /* repeated proto.replay.ReplayHeightEvent height_events */ 2:
887
+ message.heightEvents.push(ReplayHeightEvent.internalBinaryRead(reader, reader.uint32(), options));
888
+ break;
889
+ case /* repeated proto.replay.ReplayNoteEvent note_events */ 3:
890
+ message.noteEvents.push(ReplayNoteEvent.internalBinaryRead(reader, reader.uint32(), options));
891
+ break;
892
+ case /* repeated proto.replay.ReplayScoreEvent score_events */ 4:
893
+ message.scoreEvents.push(ReplayScoreEvent.internalBinaryRead(reader, reader.uint32(), options));
894
+ break;
895
+ case /* repeated proto.replay.ReplayComboEvent combo_events */ 5:
896
+ message.comboEvents.push(ReplayComboEvent.internalBinaryRead(reader, reader.uint32(), options));
897
+ break;
898
+ case /* repeated proto.replay.ReplayMultiplierEvent multiplier_events */ 6:
899
+ message.multiplierEvents.push(ReplayMultiplierEvent.internalBinaryRead(reader, reader.uint32(), options));
900
+ break;
901
+ case /* repeated proto.replay.ReplayEnergyEvent energy_events */ 7:
902
+ message.energyEvents.push(ReplayEnergyEvent.internalBinaryRead(reader, reader.uint32(), options));
903
+ break;
904
+ case /* float min_time_seconds */ 8:
905
+ message.minTimeSeconds = reader.float();
906
+ break;
907
+ case /* float max_time_seconds */ 9:
908
+ message.maxTimeSeconds = reader.float();
909
+ break;
910
+ case /* repeated proto.replay.ReplayPauseEvent pause_events */ 10:
911
+ message.pauseEvents.push(ReplayPauseEvent.internalBinaryRead(reader, reader.uint32(), options));
912
+ break;
913
+ default:
914
+ let u = options.readUnknownField;
915
+ if (u === "throw")
916
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
917
+ let d = reader.skip(wireType);
918
+ if (u !== false)
919
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
920
+ }
921
+ }
922
+ return message;
923
+ }
924
+ internalBinaryWrite(message, writer, options) {
925
+ /* repeated proto.replay.ReplayPoseFrame pose_frames = 1; */
926
+ for (let i = 0; i < message.poseFrames.length; i++)
927
+ ReplayPoseFrame.internalBinaryWrite(message.poseFrames[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
928
+ /* repeated proto.replay.ReplayHeightEvent height_events = 2; */
929
+ for (let i = 0; i < message.heightEvents.length; i++)
930
+ ReplayHeightEvent.internalBinaryWrite(message.heightEvents[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join();
931
+ /* repeated proto.replay.ReplayNoteEvent note_events = 3; */
932
+ for (let i = 0; i < message.noteEvents.length; i++)
933
+ ReplayNoteEvent.internalBinaryWrite(message.noteEvents[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join();
934
+ /* repeated proto.replay.ReplayScoreEvent score_events = 4; */
935
+ for (let i = 0; i < message.scoreEvents.length; i++)
936
+ ReplayScoreEvent.internalBinaryWrite(message.scoreEvents[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join();
937
+ /* repeated proto.replay.ReplayComboEvent combo_events = 5; */
938
+ for (let i = 0; i < message.comboEvents.length; i++)
939
+ ReplayComboEvent.internalBinaryWrite(message.comboEvents[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
940
+ /* repeated proto.replay.ReplayMultiplierEvent multiplier_events = 6; */
941
+ for (let i = 0; i < message.multiplierEvents.length; i++)
942
+ ReplayMultiplierEvent.internalBinaryWrite(message.multiplierEvents[i], writer.tag(6, WireType.LengthDelimited).fork(), options).join();
943
+ /* repeated proto.replay.ReplayEnergyEvent energy_events = 7; */
944
+ for (let i = 0; i < message.energyEvents.length; i++)
945
+ ReplayEnergyEvent.internalBinaryWrite(message.energyEvents[i], writer.tag(7, WireType.LengthDelimited).fork(), options).join();
946
+ /* float min_time_seconds = 8; */
947
+ if (message.minTimeSeconds !== 0)
948
+ writer.tag(8, WireType.Bit32).float(message.minTimeSeconds);
949
+ /* float max_time_seconds = 9; */
950
+ if (message.maxTimeSeconds !== 0)
951
+ writer.tag(9, WireType.Bit32).float(message.maxTimeSeconds);
952
+ /* repeated proto.replay.ReplayPauseEvent pause_events = 10; */
953
+ for (let i = 0; i < message.pauseEvents.length; i++)
954
+ ReplayPauseEvent.internalBinaryWrite(message.pauseEvents[i], writer.tag(10, WireType.LengthDelimited).fork(), options).join();
955
+ let u = options.writeUnknownFields;
956
+ if (u !== false)
957
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
958
+ return writer;
959
+ }
960
+ }
961
+ /**
962
+ * @generated MessageType for protobuf message proto.replay.StreamReplayEventBatch
963
+ */
964
+ export const StreamReplayEventBatch = new StreamReplayEventBatch$Type();
965
+ // @generated message type with reflection information, may provide speed optimized methods
966
+ class ReplayEventCounts$Type extends MessageType {
967
+ constructor() {
968
+ super("proto.replay.ReplayEventCounts", [
969
+ { no: 1, name: "pose_frames", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
970
+ { no: 2, name: "height_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
971
+ { no: 3, name: "note_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
972
+ { no: 4, name: "score_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
973
+ { no: 5, name: "combo_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
974
+ { no: 6, name: "multiplier_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
975
+ { no: 7, name: "energy_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ },
976
+ { no: 8, name: "pause_events", kind: "scalar", T: 4 /*ScalarType.UINT64*/, L: 0 /*LongType.BIGINT*/ }
977
+ ]);
978
+ }
979
+ create(value) {
980
+ const message = globalThis.Object.create((this.messagePrototype));
981
+ message.poseFrames = 0n;
982
+ message.heightEvents = 0n;
983
+ message.noteEvents = 0n;
984
+ message.scoreEvents = 0n;
985
+ message.comboEvents = 0n;
986
+ message.multiplierEvents = 0n;
987
+ message.energyEvents = 0n;
988
+ message.pauseEvents = 0n;
989
+ if (value !== undefined)
990
+ reflectionMergePartial(this, message, value);
991
+ return message;
992
+ }
993
+ internalBinaryRead(reader, length, options, target) {
994
+ let message = target ?? this.create(), end = reader.pos + length;
995
+ while (reader.pos < end) {
996
+ let [fieldNo, wireType] = reader.tag();
997
+ switch (fieldNo) {
998
+ case /* uint64 pose_frames */ 1:
999
+ message.poseFrames = reader.uint64().toBigInt();
1000
+ break;
1001
+ case /* uint64 height_events */ 2:
1002
+ message.heightEvents = reader.uint64().toBigInt();
1003
+ break;
1004
+ case /* uint64 note_events */ 3:
1005
+ message.noteEvents = reader.uint64().toBigInt();
1006
+ break;
1007
+ case /* uint64 score_events */ 4:
1008
+ message.scoreEvents = reader.uint64().toBigInt();
1009
+ break;
1010
+ case /* uint64 combo_events */ 5:
1011
+ message.comboEvents = reader.uint64().toBigInt();
1012
+ break;
1013
+ case /* uint64 multiplier_events */ 6:
1014
+ message.multiplierEvents = reader.uint64().toBigInt();
1015
+ break;
1016
+ case /* uint64 energy_events */ 7:
1017
+ message.energyEvents = reader.uint64().toBigInt();
1018
+ break;
1019
+ case /* uint64 pause_events */ 8:
1020
+ message.pauseEvents = reader.uint64().toBigInt();
1021
+ break;
1022
+ default:
1023
+ let u = options.readUnknownField;
1024
+ if (u === "throw")
1025
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1026
+ let d = reader.skip(wireType);
1027
+ if (u !== false)
1028
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1029
+ }
1030
+ }
1031
+ return message;
1032
+ }
1033
+ internalBinaryWrite(message, writer, options) {
1034
+ /* uint64 pose_frames = 1; */
1035
+ if (message.poseFrames !== 0n)
1036
+ writer.tag(1, WireType.Varint).uint64(message.poseFrames);
1037
+ /* uint64 height_events = 2; */
1038
+ if (message.heightEvents !== 0n)
1039
+ writer.tag(2, WireType.Varint).uint64(message.heightEvents);
1040
+ /* uint64 note_events = 3; */
1041
+ if (message.noteEvents !== 0n)
1042
+ writer.tag(3, WireType.Varint).uint64(message.noteEvents);
1043
+ /* uint64 score_events = 4; */
1044
+ if (message.scoreEvents !== 0n)
1045
+ writer.tag(4, WireType.Varint).uint64(message.scoreEvents);
1046
+ /* uint64 combo_events = 5; */
1047
+ if (message.comboEvents !== 0n)
1048
+ writer.tag(5, WireType.Varint).uint64(message.comboEvents);
1049
+ /* uint64 multiplier_events = 6; */
1050
+ if (message.multiplierEvents !== 0n)
1051
+ writer.tag(6, WireType.Varint).uint64(message.multiplierEvents);
1052
+ /* uint64 energy_events = 7; */
1053
+ if (message.energyEvents !== 0n)
1054
+ writer.tag(7, WireType.Varint).uint64(message.energyEvents);
1055
+ /* uint64 pause_events = 8; */
1056
+ if (message.pauseEvents !== 0n)
1057
+ writer.tag(8, WireType.Varint).uint64(message.pauseEvents);
1058
+ let u = options.writeUnknownFields;
1059
+ if (u !== false)
1060
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1061
+ return writer;
1062
+ }
1063
+ }
1064
+ /**
1065
+ * @generated MessageType for protobuf message proto.replay.ReplayEventCounts
1066
+ */
1067
+ export const ReplayEventCounts = new ReplayEventCounts$Type();
1068
+ // @generated message type with reflection information, may provide speed optimized methods
1069
+ class ReplayPoseFrame$Type extends MessageType {
1070
+ constructor() {
1071
+ super("proto.replay.ReplayPoseFrame", [
1072
+ { no: 1, name: "head", kind: "message", T: () => ReplayPose },
1073
+ { no: 2, name: "left", kind: "message", T: () => ReplayPose },
1074
+ { no: 3, name: "right", kind: "message", T: () => ReplayPose },
1075
+ { no: 4, name: "fps", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1076
+ { no: 5, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1077
+ ]);
1078
+ }
1079
+ create(value) {
1080
+ const message = globalThis.Object.create((this.messagePrototype));
1081
+ message.fps = 0;
1082
+ message.timeSeconds = 0;
1083
+ if (value !== undefined)
1084
+ reflectionMergePartial(this, message, value);
1085
+ return message;
1086
+ }
1087
+ internalBinaryRead(reader, length, options, target) {
1088
+ let message = target ?? this.create(), end = reader.pos + length;
1089
+ while (reader.pos < end) {
1090
+ let [fieldNo, wireType] = reader.tag();
1091
+ switch (fieldNo) {
1092
+ case /* proto.replay.ReplayPose head */ 1:
1093
+ message.head = ReplayPose.internalBinaryRead(reader, reader.uint32(), options, message.head);
1094
+ break;
1095
+ case /* proto.replay.ReplayPose left */ 2:
1096
+ message.left = ReplayPose.internalBinaryRead(reader, reader.uint32(), options, message.left);
1097
+ break;
1098
+ case /* proto.replay.ReplayPose right */ 3:
1099
+ message.right = ReplayPose.internalBinaryRead(reader, reader.uint32(), options, message.right);
1100
+ break;
1101
+ case /* int32 fps */ 4:
1102
+ message.fps = reader.int32();
1103
+ break;
1104
+ case /* float time_seconds */ 5:
1105
+ message.timeSeconds = reader.float();
1106
+ break;
1107
+ default:
1108
+ let u = options.readUnknownField;
1109
+ if (u === "throw")
1110
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1111
+ let d = reader.skip(wireType);
1112
+ if (u !== false)
1113
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1114
+ }
1115
+ }
1116
+ return message;
1117
+ }
1118
+ internalBinaryWrite(message, writer, options) {
1119
+ /* proto.replay.ReplayPose head = 1; */
1120
+ if (message.head)
1121
+ ReplayPose.internalBinaryWrite(message.head, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
1122
+ /* proto.replay.ReplayPose left = 2; */
1123
+ if (message.left)
1124
+ ReplayPose.internalBinaryWrite(message.left, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
1125
+ /* proto.replay.ReplayPose right = 3; */
1126
+ if (message.right)
1127
+ ReplayPose.internalBinaryWrite(message.right, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
1128
+ /* int32 fps = 4; */
1129
+ if (message.fps !== 0)
1130
+ writer.tag(4, WireType.Varint).int32(message.fps);
1131
+ /* float time_seconds = 5; */
1132
+ if (message.timeSeconds !== 0)
1133
+ writer.tag(5, WireType.Bit32).float(message.timeSeconds);
1134
+ let u = options.writeUnknownFields;
1135
+ if (u !== false)
1136
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1137
+ return writer;
1138
+ }
1139
+ }
1140
+ /**
1141
+ * @generated MessageType for protobuf message proto.replay.ReplayPoseFrame
1142
+ */
1143
+ export const ReplayPoseFrame = new ReplayPoseFrame$Type();
1144
+ // @generated message type with reflection information, may provide speed optimized methods
1145
+ class ReplayPose$Type extends MessageType {
1146
+ constructor() {
1147
+ super("proto.replay.ReplayPose", [
1148
+ { no: 1, name: "position", kind: "message", T: () => ReplayVector3 },
1149
+ { no: 2, name: "rotation", kind: "message", T: () => ReplayQuaternion }
1150
+ ]);
1151
+ }
1152
+ create(value) {
1153
+ const message = globalThis.Object.create((this.messagePrototype));
1154
+ if (value !== undefined)
1155
+ reflectionMergePartial(this, message, value);
1156
+ return message;
1157
+ }
1158
+ internalBinaryRead(reader, length, options, target) {
1159
+ let message = target ?? this.create(), end = reader.pos + length;
1160
+ while (reader.pos < end) {
1161
+ let [fieldNo, wireType] = reader.tag();
1162
+ switch (fieldNo) {
1163
+ case /* proto.replay.ReplayVector3 position */ 1:
1164
+ message.position = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.position);
1165
+ break;
1166
+ case /* proto.replay.ReplayQuaternion rotation */ 2:
1167
+ message.rotation = ReplayQuaternion.internalBinaryRead(reader, reader.uint32(), options, message.rotation);
1168
+ break;
1169
+ default:
1170
+ let u = options.readUnknownField;
1171
+ if (u === "throw")
1172
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1173
+ let d = reader.skip(wireType);
1174
+ if (u !== false)
1175
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1176
+ }
1177
+ }
1178
+ return message;
1179
+ }
1180
+ internalBinaryWrite(message, writer, options) {
1181
+ /* proto.replay.ReplayVector3 position = 1; */
1182
+ if (message.position)
1183
+ ReplayVector3.internalBinaryWrite(message.position, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
1184
+ /* proto.replay.ReplayQuaternion rotation = 2; */
1185
+ if (message.rotation)
1186
+ ReplayQuaternion.internalBinaryWrite(message.rotation, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
1187
+ let u = options.writeUnknownFields;
1188
+ if (u !== false)
1189
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1190
+ return writer;
1191
+ }
1192
+ }
1193
+ /**
1194
+ * @generated MessageType for protobuf message proto.replay.ReplayPose
1195
+ */
1196
+ export const ReplayPose = new ReplayPose$Type();
1197
+ // @generated message type with reflection information, may provide speed optimized methods
1198
+ class ReplayVector3$Type extends MessageType {
1199
+ constructor() {
1200
+ super("proto.replay.ReplayVector3", [
1201
+ { no: 1, name: "x", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1202
+ { no: 2, name: "y", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1203
+ { no: 3, name: "z", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1204
+ ]);
1205
+ }
1206
+ create(value) {
1207
+ const message = globalThis.Object.create((this.messagePrototype));
1208
+ message.x = 0;
1209
+ message.y = 0;
1210
+ message.z = 0;
1211
+ if (value !== undefined)
1212
+ reflectionMergePartial(this, message, value);
1213
+ return message;
1214
+ }
1215
+ internalBinaryRead(reader, length, options, target) {
1216
+ let message = target ?? this.create(), end = reader.pos + length;
1217
+ while (reader.pos < end) {
1218
+ let [fieldNo, wireType] = reader.tag();
1219
+ switch (fieldNo) {
1220
+ case /* float x */ 1:
1221
+ message.x = reader.float();
1222
+ break;
1223
+ case /* float y */ 2:
1224
+ message.y = reader.float();
1225
+ break;
1226
+ case /* float z */ 3:
1227
+ message.z = reader.float();
1228
+ break;
1229
+ default:
1230
+ let u = options.readUnknownField;
1231
+ if (u === "throw")
1232
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1233
+ let d = reader.skip(wireType);
1234
+ if (u !== false)
1235
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1236
+ }
1237
+ }
1238
+ return message;
1239
+ }
1240
+ internalBinaryWrite(message, writer, options) {
1241
+ /* float x = 1; */
1242
+ if (message.x !== 0)
1243
+ writer.tag(1, WireType.Bit32).float(message.x);
1244
+ /* float y = 2; */
1245
+ if (message.y !== 0)
1246
+ writer.tag(2, WireType.Bit32).float(message.y);
1247
+ /* float z = 3; */
1248
+ if (message.z !== 0)
1249
+ writer.tag(3, WireType.Bit32).float(message.z);
1250
+ let u = options.writeUnknownFields;
1251
+ if (u !== false)
1252
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1253
+ return writer;
1254
+ }
1255
+ }
1256
+ /**
1257
+ * @generated MessageType for protobuf message proto.replay.ReplayVector3
1258
+ */
1259
+ export const ReplayVector3 = new ReplayVector3$Type();
1260
+ // @generated message type with reflection information, may provide speed optimized methods
1261
+ class ReplayQuaternion$Type extends MessageType {
1262
+ constructor() {
1263
+ super("proto.replay.ReplayQuaternion", [
1264
+ { no: 1, name: "x", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1265
+ { no: 2, name: "y", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1266
+ { no: 3, name: "z", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1267
+ { no: 4, name: "w", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1268
+ ]);
1269
+ }
1270
+ create(value) {
1271
+ const message = globalThis.Object.create((this.messagePrototype));
1272
+ message.x = 0;
1273
+ message.y = 0;
1274
+ message.z = 0;
1275
+ message.w = 0;
1276
+ if (value !== undefined)
1277
+ reflectionMergePartial(this, message, value);
1278
+ return message;
1279
+ }
1280
+ internalBinaryRead(reader, length, options, target) {
1281
+ let message = target ?? this.create(), end = reader.pos + length;
1282
+ while (reader.pos < end) {
1283
+ let [fieldNo, wireType] = reader.tag();
1284
+ switch (fieldNo) {
1285
+ case /* float x */ 1:
1286
+ message.x = reader.float();
1287
+ break;
1288
+ case /* float y */ 2:
1289
+ message.y = reader.float();
1290
+ break;
1291
+ case /* float z */ 3:
1292
+ message.z = reader.float();
1293
+ break;
1294
+ case /* float w */ 4:
1295
+ message.w = reader.float();
1296
+ break;
1297
+ default:
1298
+ let u = options.readUnknownField;
1299
+ if (u === "throw")
1300
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1301
+ let d = reader.skip(wireType);
1302
+ if (u !== false)
1303
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1304
+ }
1305
+ }
1306
+ return message;
1307
+ }
1308
+ internalBinaryWrite(message, writer, options) {
1309
+ /* float x = 1; */
1310
+ if (message.x !== 0)
1311
+ writer.tag(1, WireType.Bit32).float(message.x);
1312
+ /* float y = 2; */
1313
+ if (message.y !== 0)
1314
+ writer.tag(2, WireType.Bit32).float(message.y);
1315
+ /* float z = 3; */
1316
+ if (message.z !== 0)
1317
+ writer.tag(3, WireType.Bit32).float(message.z);
1318
+ /* float w = 4; */
1319
+ if (message.w !== 0)
1320
+ writer.tag(4, WireType.Bit32).float(message.w);
1321
+ let u = options.writeUnknownFields;
1322
+ if (u !== false)
1323
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1324
+ return writer;
1325
+ }
1326
+ }
1327
+ /**
1328
+ * @generated MessageType for protobuf message proto.replay.ReplayQuaternion
1329
+ */
1330
+ export const ReplayQuaternion = new ReplayQuaternion$Type();
1331
+ // @generated message type with reflection information, may provide speed optimized methods
1332
+ class ReplayColor$Type extends MessageType {
1333
+ constructor() {
1334
+ super("proto.replay.ReplayColor", [
1335
+ { no: 1, name: "r", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1336
+ { no: 2, name: "g", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1337
+ { no: 3, name: "b", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1338
+ { no: 4, name: "a", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1339
+ ]);
1340
+ }
1341
+ create(value) {
1342
+ const message = globalThis.Object.create((this.messagePrototype));
1343
+ message.r = 0;
1344
+ message.g = 0;
1345
+ message.b = 0;
1346
+ message.a = 0;
1347
+ if (value !== undefined)
1348
+ reflectionMergePartial(this, message, value);
1349
+ return message;
1350
+ }
1351
+ internalBinaryRead(reader, length, options, target) {
1352
+ let message = target ?? this.create(), end = reader.pos + length;
1353
+ while (reader.pos < end) {
1354
+ let [fieldNo, wireType] = reader.tag();
1355
+ switch (fieldNo) {
1356
+ case /* float r */ 1:
1357
+ message.r = reader.float();
1358
+ break;
1359
+ case /* float g */ 2:
1360
+ message.g = reader.float();
1361
+ break;
1362
+ case /* float b */ 3:
1363
+ message.b = reader.float();
1364
+ break;
1365
+ case /* float a */ 4:
1366
+ message.a = reader.float();
1367
+ break;
1368
+ default:
1369
+ let u = options.readUnknownField;
1370
+ if (u === "throw")
1371
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1372
+ let d = reader.skip(wireType);
1373
+ if (u !== false)
1374
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1375
+ }
1376
+ }
1377
+ return message;
1378
+ }
1379
+ internalBinaryWrite(message, writer, options) {
1380
+ /* float r = 1; */
1381
+ if (message.r !== 0)
1382
+ writer.tag(1, WireType.Bit32).float(message.r);
1383
+ /* float g = 2; */
1384
+ if (message.g !== 0)
1385
+ writer.tag(2, WireType.Bit32).float(message.g);
1386
+ /* float b = 3; */
1387
+ if (message.b !== 0)
1388
+ writer.tag(3, WireType.Bit32).float(message.b);
1389
+ /* float a = 4; */
1390
+ if (message.a !== 0)
1391
+ writer.tag(4, WireType.Bit32).float(message.a);
1392
+ let u = options.writeUnknownFields;
1393
+ if (u !== false)
1394
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1395
+ return writer;
1396
+ }
1397
+ }
1398
+ /**
1399
+ * @generated MessageType for protobuf message proto.replay.ReplayColor
1400
+ */
1401
+ export const ReplayColor = new ReplayColor$Type();
1402
+ // @generated message type with reflection information, may provide speed optimized methods
1403
+ class ReplayHeightEvent$Type extends MessageType {
1404
+ constructor() {
1405
+ super("proto.replay.ReplayHeightEvent", [
1406
+ { no: 1, name: "height", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1407
+ { no: 2, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1408
+ ]);
1409
+ }
1410
+ create(value) {
1411
+ const message = globalThis.Object.create((this.messagePrototype));
1412
+ message.height = 0;
1413
+ message.timeSeconds = 0;
1414
+ if (value !== undefined)
1415
+ reflectionMergePartial(this, message, value);
1416
+ return message;
1417
+ }
1418
+ internalBinaryRead(reader, length, options, target) {
1419
+ let message = target ?? this.create(), end = reader.pos + length;
1420
+ while (reader.pos < end) {
1421
+ let [fieldNo, wireType] = reader.tag();
1422
+ switch (fieldNo) {
1423
+ case /* float height */ 1:
1424
+ message.height = reader.float();
1425
+ break;
1426
+ case /* float time_seconds */ 2:
1427
+ message.timeSeconds = reader.float();
1428
+ break;
1429
+ default:
1430
+ let u = options.readUnknownField;
1431
+ if (u === "throw")
1432
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1433
+ let d = reader.skip(wireType);
1434
+ if (u !== false)
1435
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1436
+ }
1437
+ }
1438
+ return message;
1439
+ }
1440
+ internalBinaryWrite(message, writer, options) {
1441
+ /* float height = 1; */
1442
+ if (message.height !== 0)
1443
+ writer.tag(1, WireType.Bit32).float(message.height);
1444
+ /* float time_seconds = 2; */
1445
+ if (message.timeSeconds !== 0)
1446
+ writer.tag(2, WireType.Bit32).float(message.timeSeconds);
1447
+ let u = options.writeUnknownFields;
1448
+ if (u !== false)
1449
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1450
+ return writer;
1451
+ }
1452
+ }
1453
+ /**
1454
+ * @generated MessageType for protobuf message proto.replay.ReplayHeightEvent
1455
+ */
1456
+ export const ReplayHeightEvent = new ReplayHeightEvent$Type();
1457
+ // @generated message type with reflection information, may provide speed optimized methods
1458
+ class ReplayScoreEvent$Type extends MessageType {
1459
+ constructor() {
1460
+ super("proto.replay.ReplayScoreEvent", [
1461
+ { no: 1, name: "score", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1462
+ { no: 2, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1463
+ { no: 3, name: "immediate_max_possible_score", kind: "scalar", T: 5 /*ScalarType.INT32*/ }
1464
+ ]);
1465
+ }
1466
+ create(value) {
1467
+ const message = globalThis.Object.create((this.messagePrototype));
1468
+ message.score = 0;
1469
+ message.timeSeconds = 0;
1470
+ message.immediateMaxPossibleScore = 0;
1471
+ if (value !== undefined)
1472
+ reflectionMergePartial(this, message, value);
1473
+ return message;
1474
+ }
1475
+ internalBinaryRead(reader, length, options, target) {
1476
+ let message = target ?? this.create(), end = reader.pos + length;
1477
+ while (reader.pos < end) {
1478
+ let [fieldNo, wireType] = reader.tag();
1479
+ switch (fieldNo) {
1480
+ case /* int32 score */ 1:
1481
+ message.score = reader.int32();
1482
+ break;
1483
+ case /* float time_seconds */ 2:
1484
+ message.timeSeconds = reader.float();
1485
+ break;
1486
+ case /* int32 immediate_max_possible_score */ 3:
1487
+ message.immediateMaxPossibleScore = reader.int32();
1488
+ break;
1489
+ default:
1490
+ let u = options.readUnknownField;
1491
+ if (u === "throw")
1492
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1493
+ let d = reader.skip(wireType);
1494
+ if (u !== false)
1495
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1496
+ }
1497
+ }
1498
+ return message;
1499
+ }
1500
+ internalBinaryWrite(message, writer, options) {
1501
+ /* int32 score = 1; */
1502
+ if (message.score !== 0)
1503
+ writer.tag(1, WireType.Varint).int32(message.score);
1504
+ /* float time_seconds = 2; */
1505
+ if (message.timeSeconds !== 0)
1506
+ writer.tag(2, WireType.Bit32).float(message.timeSeconds);
1507
+ /* int32 immediate_max_possible_score = 3; */
1508
+ if (message.immediateMaxPossibleScore !== 0)
1509
+ writer.tag(3, WireType.Varint).int32(message.immediateMaxPossibleScore);
1510
+ let u = options.writeUnknownFields;
1511
+ if (u !== false)
1512
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1513
+ return writer;
1514
+ }
1515
+ }
1516
+ /**
1517
+ * @generated MessageType for protobuf message proto.replay.ReplayScoreEvent
1518
+ */
1519
+ export const ReplayScoreEvent = new ReplayScoreEvent$Type();
1520
+ // @generated message type with reflection information, may provide speed optimized methods
1521
+ class ReplayComboEvent$Type extends MessageType {
1522
+ constructor() {
1523
+ super("proto.replay.ReplayComboEvent", [
1524
+ { no: 1, name: "combo", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1525
+ { no: 2, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1526
+ ]);
1527
+ }
1528
+ create(value) {
1529
+ const message = globalThis.Object.create((this.messagePrototype));
1530
+ message.combo = 0;
1531
+ message.timeSeconds = 0;
1532
+ if (value !== undefined)
1533
+ reflectionMergePartial(this, message, value);
1534
+ return message;
1535
+ }
1536
+ internalBinaryRead(reader, length, options, target) {
1537
+ let message = target ?? this.create(), end = reader.pos + length;
1538
+ while (reader.pos < end) {
1539
+ let [fieldNo, wireType] = reader.tag();
1540
+ switch (fieldNo) {
1541
+ case /* int32 combo */ 1:
1542
+ message.combo = reader.int32();
1543
+ break;
1544
+ case /* float time_seconds */ 2:
1545
+ message.timeSeconds = reader.float();
1546
+ break;
1547
+ default:
1548
+ let u = options.readUnknownField;
1549
+ if (u === "throw")
1550
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1551
+ let d = reader.skip(wireType);
1552
+ if (u !== false)
1553
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1554
+ }
1555
+ }
1556
+ return message;
1557
+ }
1558
+ internalBinaryWrite(message, writer, options) {
1559
+ /* int32 combo = 1; */
1560
+ if (message.combo !== 0)
1561
+ writer.tag(1, WireType.Varint).int32(message.combo);
1562
+ /* float time_seconds = 2; */
1563
+ if (message.timeSeconds !== 0)
1564
+ writer.tag(2, WireType.Bit32).float(message.timeSeconds);
1565
+ let u = options.writeUnknownFields;
1566
+ if (u !== false)
1567
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1568
+ return writer;
1569
+ }
1570
+ }
1571
+ /**
1572
+ * @generated MessageType for protobuf message proto.replay.ReplayComboEvent
1573
+ */
1574
+ export const ReplayComboEvent = new ReplayComboEvent$Type();
1575
+ // @generated message type with reflection information, may provide speed optimized methods
1576
+ class ReplayMultiplierEvent$Type extends MessageType {
1577
+ constructor() {
1578
+ super("proto.replay.ReplayMultiplierEvent", [
1579
+ { no: 1, name: "multiplier", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1580
+ { no: 2, name: "next_multiplier_progress", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1581
+ { no: 3, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1582
+ ]);
1583
+ }
1584
+ create(value) {
1585
+ const message = globalThis.Object.create((this.messagePrototype));
1586
+ message.multiplier = 0;
1587
+ message.nextMultiplierProgress = 0;
1588
+ message.timeSeconds = 0;
1589
+ if (value !== undefined)
1590
+ reflectionMergePartial(this, message, value);
1591
+ return message;
1592
+ }
1593
+ internalBinaryRead(reader, length, options, target) {
1594
+ let message = target ?? this.create(), end = reader.pos + length;
1595
+ while (reader.pos < end) {
1596
+ let [fieldNo, wireType] = reader.tag();
1597
+ switch (fieldNo) {
1598
+ case /* int32 multiplier */ 1:
1599
+ message.multiplier = reader.int32();
1600
+ break;
1601
+ case /* float next_multiplier_progress */ 2:
1602
+ message.nextMultiplierProgress = reader.float();
1603
+ break;
1604
+ case /* float time_seconds */ 3:
1605
+ message.timeSeconds = reader.float();
1606
+ break;
1607
+ default:
1608
+ let u = options.readUnknownField;
1609
+ if (u === "throw")
1610
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1611
+ let d = reader.skip(wireType);
1612
+ if (u !== false)
1613
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1614
+ }
1615
+ }
1616
+ return message;
1617
+ }
1618
+ internalBinaryWrite(message, writer, options) {
1619
+ /* int32 multiplier = 1; */
1620
+ if (message.multiplier !== 0)
1621
+ writer.tag(1, WireType.Varint).int32(message.multiplier);
1622
+ /* float next_multiplier_progress = 2; */
1623
+ if (message.nextMultiplierProgress !== 0)
1624
+ writer.tag(2, WireType.Bit32).float(message.nextMultiplierProgress);
1625
+ /* float time_seconds = 3; */
1626
+ if (message.timeSeconds !== 0)
1627
+ writer.tag(3, WireType.Bit32).float(message.timeSeconds);
1628
+ let u = options.writeUnknownFields;
1629
+ if (u !== false)
1630
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1631
+ return writer;
1632
+ }
1633
+ }
1634
+ /**
1635
+ * @generated MessageType for protobuf message proto.replay.ReplayMultiplierEvent
1636
+ */
1637
+ export const ReplayMultiplierEvent = new ReplayMultiplierEvent$Type();
1638
+ // @generated message type with reflection information, may provide speed optimized methods
1639
+ class ReplayEnergyEvent$Type extends MessageType {
1640
+ constructor() {
1641
+ super("proto.replay.ReplayEnergyEvent", [
1642
+ { no: 1, name: "energy", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1643
+ { no: 2, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1644
+ ]);
1645
+ }
1646
+ create(value) {
1647
+ const message = globalThis.Object.create((this.messagePrototype));
1648
+ message.energy = 0;
1649
+ message.timeSeconds = 0;
1650
+ if (value !== undefined)
1651
+ reflectionMergePartial(this, message, value);
1652
+ return message;
1653
+ }
1654
+ internalBinaryRead(reader, length, options, target) {
1655
+ let message = target ?? this.create(), end = reader.pos + length;
1656
+ while (reader.pos < end) {
1657
+ let [fieldNo, wireType] = reader.tag();
1658
+ switch (fieldNo) {
1659
+ case /* float energy */ 1:
1660
+ message.energy = reader.float();
1661
+ break;
1662
+ case /* float time_seconds */ 2:
1663
+ message.timeSeconds = reader.float();
1664
+ break;
1665
+ default:
1666
+ let u = options.readUnknownField;
1667
+ if (u === "throw")
1668
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1669
+ let d = reader.skip(wireType);
1670
+ if (u !== false)
1671
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1672
+ }
1673
+ }
1674
+ return message;
1675
+ }
1676
+ internalBinaryWrite(message, writer, options) {
1677
+ /* float energy = 1; */
1678
+ if (message.energy !== 0)
1679
+ writer.tag(1, WireType.Bit32).float(message.energy);
1680
+ /* float time_seconds = 2; */
1681
+ if (message.timeSeconds !== 0)
1682
+ writer.tag(2, WireType.Bit32).float(message.timeSeconds);
1683
+ let u = options.writeUnknownFields;
1684
+ if (u !== false)
1685
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1686
+ return writer;
1687
+ }
1688
+ }
1689
+ /**
1690
+ * @generated MessageType for protobuf message proto.replay.ReplayEnergyEvent
1691
+ */
1692
+ export const ReplayEnergyEvent = new ReplayEnergyEvent$Type();
1693
+ // @generated message type with reflection information, may provide speed optimized methods
1694
+ class ReplayPauseEvent$Type extends MessageType {
1695
+ constructor() {
1696
+ super("proto.replay.ReplayPauseEvent", [
1697
+ { no: 1, name: "paused", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
1698
+ { no: 2, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1699
+ { no: 3, name: "client_time_unix_ms", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }
1700
+ ]);
1701
+ }
1702
+ create(value) {
1703
+ const message = globalThis.Object.create((this.messagePrototype));
1704
+ message.paused = false;
1705
+ message.timeSeconds = 0;
1706
+ message.clientTimeUnixMs = 0n;
1707
+ if (value !== undefined)
1708
+ reflectionMergePartial(this, message, value);
1709
+ return message;
1710
+ }
1711
+ internalBinaryRead(reader, length, options, target) {
1712
+ let message = target ?? this.create(), end = reader.pos + length;
1713
+ while (reader.pos < end) {
1714
+ let [fieldNo, wireType] = reader.tag();
1715
+ switch (fieldNo) {
1716
+ case /* bool paused */ 1:
1717
+ message.paused = reader.bool();
1718
+ break;
1719
+ case /* float time_seconds */ 2:
1720
+ message.timeSeconds = reader.float();
1721
+ break;
1722
+ case /* int64 client_time_unix_ms */ 3:
1723
+ message.clientTimeUnixMs = reader.int64().toBigInt();
1724
+ break;
1725
+ default:
1726
+ let u = options.readUnknownField;
1727
+ if (u === "throw")
1728
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1729
+ let d = reader.skip(wireType);
1730
+ if (u !== false)
1731
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1732
+ }
1733
+ }
1734
+ return message;
1735
+ }
1736
+ internalBinaryWrite(message, writer, options) {
1737
+ /* bool paused = 1; */
1738
+ if (message.paused !== false)
1739
+ writer.tag(1, WireType.Varint).bool(message.paused);
1740
+ /* float time_seconds = 2; */
1741
+ if (message.timeSeconds !== 0)
1742
+ writer.tag(2, WireType.Bit32).float(message.timeSeconds);
1743
+ /* int64 client_time_unix_ms = 3; */
1744
+ if (message.clientTimeUnixMs !== 0n)
1745
+ writer.tag(3, WireType.Varint).int64(message.clientTimeUnixMs);
1746
+ let u = options.writeUnknownFields;
1747
+ if (u !== false)
1748
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1749
+ return writer;
1750
+ }
1751
+ }
1752
+ /**
1753
+ * @generated MessageType for protobuf message proto.replay.ReplayPauseEvent
1754
+ */
1755
+ export const ReplayPauseEvent = new ReplayPauseEvent$Type();
1756
+ // @generated message type with reflection information, may provide speed optimized methods
1757
+ class ReplayNoteEvent$Type extends MessageType {
1758
+ constructor() {
1759
+ super("proto.replay.ReplayNoteEvent", [
1760
+ { no: 1, name: "note_id", kind: "message", T: () => ReplayNoteId },
1761
+ { no: 2, name: "event_type", kind: "enum", T: () => ["proto.replay.ReplayNoteEventType", ReplayNoteEventType, "REPLAY_NOTE_EVENT_TYPE_"] },
1762
+ { no: 3, name: "cut_point", kind: "message", T: () => ReplayVector3 },
1763
+ { no: 4, name: "cut_normal", kind: "message", T: () => ReplayVector3 },
1764
+ { no: 5, name: "saber_direction", kind: "message", T: () => ReplayVector3 },
1765
+ { no: 6, name: "saber_type", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1766
+ { no: 7, name: "direction_ok", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
1767
+ { no: 8, name: "saber_speed", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1768
+ { no: 9, name: "cut_angle", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1769
+ { no: 10, name: "cut_distance_to_center", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1770
+ { no: 11, name: "cut_direction_deviation", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1771
+ { no: 12, name: "before_cut_rating", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1772
+ { no: 13, name: "after_cut_rating", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1773
+ { no: 14, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1774
+ { no: 15, name: "unity_timescale", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1775
+ { no: 16, name: "time_sync_timescale", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1776
+ { no: 17, name: "time_deviation", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1777
+ { no: 18, name: "world_rotation", kind: "message", T: () => ReplayQuaternion },
1778
+ { no: 19, name: "inverse_world_rotation", kind: "message", T: () => ReplayQuaternion },
1779
+ { no: 20, name: "note_rotation", kind: "message", T: () => ReplayQuaternion },
1780
+ { no: 21, name: "note_position", kind: "message", T: () => ReplayVector3 }
1781
+ ]);
1782
+ }
1783
+ create(value) {
1784
+ const message = globalThis.Object.create((this.messagePrototype));
1785
+ message.eventType = 0;
1786
+ message.saberType = 0;
1787
+ message.directionOk = false;
1788
+ message.saberSpeed = 0;
1789
+ message.cutAngle = 0;
1790
+ message.cutDistanceToCenter = 0;
1791
+ message.cutDirectionDeviation = 0;
1792
+ message.beforeCutRating = 0;
1793
+ message.afterCutRating = 0;
1794
+ message.timeSeconds = 0;
1795
+ message.unityTimescale = 0;
1796
+ message.timeSyncTimescale = 0;
1797
+ message.timeDeviation = 0;
1798
+ if (value !== undefined)
1799
+ reflectionMergePartial(this, message, value);
1800
+ return message;
1801
+ }
1802
+ internalBinaryRead(reader, length, options, target) {
1803
+ let message = target ?? this.create(), end = reader.pos + length;
1804
+ while (reader.pos < end) {
1805
+ let [fieldNo, wireType] = reader.tag();
1806
+ switch (fieldNo) {
1807
+ case /* proto.replay.ReplayNoteId note_id */ 1:
1808
+ message.noteId = ReplayNoteId.internalBinaryRead(reader, reader.uint32(), options, message.noteId);
1809
+ break;
1810
+ case /* proto.replay.ReplayNoteEventType event_type */ 2:
1811
+ message.eventType = reader.int32();
1812
+ break;
1813
+ case /* proto.replay.ReplayVector3 cut_point */ 3:
1814
+ message.cutPoint = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.cutPoint);
1815
+ break;
1816
+ case /* proto.replay.ReplayVector3 cut_normal */ 4:
1817
+ message.cutNormal = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.cutNormal);
1818
+ break;
1819
+ case /* proto.replay.ReplayVector3 saber_direction */ 5:
1820
+ message.saberDirection = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.saberDirection);
1821
+ break;
1822
+ case /* int32 saber_type */ 6:
1823
+ message.saberType = reader.int32();
1824
+ break;
1825
+ case /* bool direction_ok */ 7:
1826
+ message.directionOk = reader.bool();
1827
+ break;
1828
+ case /* float saber_speed */ 8:
1829
+ message.saberSpeed = reader.float();
1830
+ break;
1831
+ case /* float cut_angle */ 9:
1832
+ message.cutAngle = reader.float();
1833
+ break;
1834
+ case /* float cut_distance_to_center */ 10:
1835
+ message.cutDistanceToCenter = reader.float();
1836
+ break;
1837
+ case /* float cut_direction_deviation */ 11:
1838
+ message.cutDirectionDeviation = reader.float();
1839
+ break;
1840
+ case /* float before_cut_rating */ 12:
1841
+ message.beforeCutRating = reader.float();
1842
+ break;
1843
+ case /* float after_cut_rating */ 13:
1844
+ message.afterCutRating = reader.float();
1845
+ break;
1846
+ case /* float time_seconds */ 14:
1847
+ message.timeSeconds = reader.float();
1848
+ break;
1849
+ case /* float unity_timescale */ 15:
1850
+ message.unityTimescale = reader.float();
1851
+ break;
1852
+ case /* float time_sync_timescale */ 16:
1853
+ message.timeSyncTimescale = reader.float();
1854
+ break;
1855
+ case /* float time_deviation */ 17:
1856
+ message.timeDeviation = reader.float();
1857
+ break;
1858
+ case /* proto.replay.ReplayQuaternion world_rotation */ 18:
1859
+ message.worldRotation = ReplayQuaternion.internalBinaryRead(reader, reader.uint32(), options, message.worldRotation);
1860
+ break;
1861
+ case /* proto.replay.ReplayQuaternion inverse_world_rotation */ 19:
1862
+ message.inverseWorldRotation = ReplayQuaternion.internalBinaryRead(reader, reader.uint32(), options, message.inverseWorldRotation);
1863
+ break;
1864
+ case /* proto.replay.ReplayQuaternion note_rotation */ 20:
1865
+ message.noteRotation = ReplayQuaternion.internalBinaryRead(reader, reader.uint32(), options, message.noteRotation);
1866
+ break;
1867
+ case /* proto.replay.ReplayVector3 note_position */ 21:
1868
+ message.notePosition = ReplayVector3.internalBinaryRead(reader, reader.uint32(), options, message.notePosition);
1869
+ break;
1870
+ default:
1871
+ let u = options.readUnknownField;
1872
+ if (u === "throw")
1873
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
1874
+ let d = reader.skip(wireType);
1875
+ if (u !== false)
1876
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
1877
+ }
1878
+ }
1879
+ return message;
1880
+ }
1881
+ internalBinaryWrite(message, writer, options) {
1882
+ /* proto.replay.ReplayNoteId note_id = 1; */
1883
+ if (message.noteId)
1884
+ ReplayNoteId.internalBinaryWrite(message.noteId, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
1885
+ /* proto.replay.ReplayNoteEventType event_type = 2; */
1886
+ if (message.eventType !== 0)
1887
+ writer.tag(2, WireType.Varint).int32(message.eventType);
1888
+ /* proto.replay.ReplayVector3 cut_point = 3; */
1889
+ if (message.cutPoint)
1890
+ ReplayVector3.internalBinaryWrite(message.cutPoint, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
1891
+ /* proto.replay.ReplayVector3 cut_normal = 4; */
1892
+ if (message.cutNormal)
1893
+ ReplayVector3.internalBinaryWrite(message.cutNormal, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
1894
+ /* proto.replay.ReplayVector3 saber_direction = 5; */
1895
+ if (message.saberDirection)
1896
+ ReplayVector3.internalBinaryWrite(message.saberDirection, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
1897
+ /* int32 saber_type = 6; */
1898
+ if (message.saberType !== 0)
1899
+ writer.tag(6, WireType.Varint).int32(message.saberType);
1900
+ /* bool direction_ok = 7; */
1901
+ if (message.directionOk !== false)
1902
+ writer.tag(7, WireType.Varint).bool(message.directionOk);
1903
+ /* float saber_speed = 8; */
1904
+ if (message.saberSpeed !== 0)
1905
+ writer.tag(8, WireType.Bit32).float(message.saberSpeed);
1906
+ /* float cut_angle = 9; */
1907
+ if (message.cutAngle !== 0)
1908
+ writer.tag(9, WireType.Bit32).float(message.cutAngle);
1909
+ /* float cut_distance_to_center = 10; */
1910
+ if (message.cutDistanceToCenter !== 0)
1911
+ writer.tag(10, WireType.Bit32).float(message.cutDistanceToCenter);
1912
+ /* float cut_direction_deviation = 11; */
1913
+ if (message.cutDirectionDeviation !== 0)
1914
+ writer.tag(11, WireType.Bit32).float(message.cutDirectionDeviation);
1915
+ /* float before_cut_rating = 12; */
1916
+ if (message.beforeCutRating !== 0)
1917
+ writer.tag(12, WireType.Bit32).float(message.beforeCutRating);
1918
+ /* float after_cut_rating = 13; */
1919
+ if (message.afterCutRating !== 0)
1920
+ writer.tag(13, WireType.Bit32).float(message.afterCutRating);
1921
+ /* float time_seconds = 14; */
1922
+ if (message.timeSeconds !== 0)
1923
+ writer.tag(14, WireType.Bit32).float(message.timeSeconds);
1924
+ /* float unity_timescale = 15; */
1925
+ if (message.unityTimescale !== 0)
1926
+ writer.tag(15, WireType.Bit32).float(message.unityTimescale);
1927
+ /* float time_sync_timescale = 16; */
1928
+ if (message.timeSyncTimescale !== 0)
1929
+ writer.tag(16, WireType.Bit32).float(message.timeSyncTimescale);
1930
+ /* float time_deviation = 17; */
1931
+ if (message.timeDeviation !== 0)
1932
+ writer.tag(17, WireType.Bit32).float(message.timeDeviation);
1933
+ /* proto.replay.ReplayQuaternion world_rotation = 18; */
1934
+ if (message.worldRotation)
1935
+ ReplayQuaternion.internalBinaryWrite(message.worldRotation, writer.tag(18, WireType.LengthDelimited).fork(), options).join();
1936
+ /* proto.replay.ReplayQuaternion inverse_world_rotation = 19; */
1937
+ if (message.inverseWorldRotation)
1938
+ ReplayQuaternion.internalBinaryWrite(message.inverseWorldRotation, writer.tag(19, WireType.LengthDelimited).fork(), options).join();
1939
+ /* proto.replay.ReplayQuaternion note_rotation = 20; */
1940
+ if (message.noteRotation)
1941
+ ReplayQuaternion.internalBinaryWrite(message.noteRotation, writer.tag(20, WireType.LengthDelimited).fork(), options).join();
1942
+ /* proto.replay.ReplayVector3 note_position = 21; */
1943
+ if (message.notePosition)
1944
+ ReplayVector3.internalBinaryWrite(message.notePosition, writer.tag(21, WireType.LengthDelimited).fork(), options).join();
1945
+ let u = options.writeUnknownFields;
1946
+ if (u !== false)
1947
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
1948
+ return writer;
1949
+ }
1950
+ }
1951
+ /**
1952
+ * @generated MessageType for protobuf message proto.replay.ReplayNoteEvent
1953
+ */
1954
+ export const ReplayNoteEvent = new ReplayNoteEvent$Type();
1955
+ // @generated message type with reflection information, may provide speed optimized methods
1956
+ class ReplayNoteId$Type extends MessageType {
1957
+ constructor() {
1958
+ super("proto.replay.ReplayNoteId", [
1959
+ { no: 1, name: "time_seconds", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ },
1960
+ { no: 2, name: "line_layer", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1961
+ { no: 3, name: "line_index", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1962
+ { no: 4, name: "color_type", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1963
+ { no: 5, name: "cut_direction", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1964
+ { no: 6, name: "gameplay_type", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1965
+ { no: 7, name: "scoring_type", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
1966
+ { no: 8, name: "cut_direction_angle_offset", kind: "scalar", T: 2 /*ScalarType.FLOAT*/ }
1967
+ ]);
1968
+ }
1969
+ create(value) {
1970
+ const message = globalThis.Object.create((this.messagePrototype));
1971
+ message.timeSeconds = 0;
1972
+ message.lineLayer = 0;
1973
+ message.lineIndex = 0;
1974
+ message.colorType = 0;
1975
+ message.cutDirection = 0;
1976
+ message.gameplayType = 0;
1977
+ message.scoringType = 0;
1978
+ message.cutDirectionAngleOffset = 0;
1979
+ if (value !== undefined)
1980
+ reflectionMergePartial(this, message, value);
1981
+ return message;
1982
+ }
1983
+ internalBinaryRead(reader, length, options, target) {
1984
+ let message = target ?? this.create(), end = reader.pos + length;
1985
+ while (reader.pos < end) {
1986
+ let [fieldNo, wireType] = reader.tag();
1987
+ switch (fieldNo) {
1988
+ case /* float time_seconds */ 1:
1989
+ message.timeSeconds = reader.float();
1990
+ break;
1991
+ case /* int32 line_layer */ 2:
1992
+ message.lineLayer = reader.int32();
1993
+ break;
1994
+ case /* int32 line_index */ 3:
1995
+ message.lineIndex = reader.int32();
1996
+ break;
1997
+ case /* int32 color_type */ 4:
1998
+ message.colorType = reader.int32();
1999
+ break;
2000
+ case /* int32 cut_direction */ 5:
2001
+ message.cutDirection = reader.int32();
2002
+ break;
2003
+ case /* int32 gameplay_type */ 6:
2004
+ message.gameplayType = reader.int32();
2005
+ break;
2006
+ case /* int32 scoring_type */ 7:
2007
+ message.scoringType = reader.int32();
2008
+ break;
2009
+ case /* float cut_direction_angle_offset */ 8:
2010
+ message.cutDirectionAngleOffset = reader.float();
2011
+ break;
2012
+ default:
2013
+ let u = options.readUnknownField;
2014
+ if (u === "throw")
2015
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
2016
+ let d = reader.skip(wireType);
2017
+ if (u !== false)
2018
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
2019
+ }
2020
+ }
2021
+ return message;
2022
+ }
2023
+ internalBinaryWrite(message, writer, options) {
2024
+ /* float time_seconds = 1; */
2025
+ if (message.timeSeconds !== 0)
2026
+ writer.tag(1, WireType.Bit32).float(message.timeSeconds);
2027
+ /* int32 line_layer = 2; */
2028
+ if (message.lineLayer !== 0)
2029
+ writer.tag(2, WireType.Varint).int32(message.lineLayer);
2030
+ /* int32 line_index = 3; */
2031
+ if (message.lineIndex !== 0)
2032
+ writer.tag(3, WireType.Varint).int32(message.lineIndex);
2033
+ /* int32 color_type = 4; */
2034
+ if (message.colorType !== 0)
2035
+ writer.tag(4, WireType.Varint).int32(message.colorType);
2036
+ /* int32 cut_direction = 5; */
2037
+ if (message.cutDirection !== 0)
2038
+ writer.tag(5, WireType.Varint).int32(message.cutDirection);
2039
+ /* int32 gameplay_type = 6; */
2040
+ if (message.gameplayType !== 0)
2041
+ writer.tag(6, WireType.Varint).int32(message.gameplayType);
2042
+ /* int32 scoring_type = 7; */
2043
+ if (message.scoringType !== 0)
2044
+ writer.tag(7, WireType.Varint).int32(message.scoringType);
2045
+ /* float cut_direction_angle_offset = 8; */
2046
+ if (message.cutDirectionAngleOffset !== 0)
2047
+ writer.tag(8, WireType.Bit32).float(message.cutDirectionAngleOffset);
2048
+ let u = options.writeUnknownFields;
2049
+ if (u !== false)
2050
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
2051
+ return writer;
2052
+ }
2053
+ }
2054
+ /**
2055
+ * @generated MessageType for protobuf message proto.replay.ReplayNoteId
2056
+ */
2057
+ export const ReplayNoteId = new ReplayNoteId$Type();
2058
+ // @generated message type with reflection information, may provide speed optimized methods
2059
+ class ReplayScoreSummary$Type extends MessageType {
2060
+ constructor() {
2061
+ super("proto.replay.ReplayScoreSummary", [
2062
+ { no: 1, name: "score", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2063
+ { no: 2, name: "modified_score", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2064
+ { no: 3, name: "max_score", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2065
+ { no: 4, name: "accuracy", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
2066
+ { no: 5, name: "combo", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2067
+ { no: 6, name: "max_combo", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2068
+ { no: 7, name: "full_combo", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
2069
+ { no: 8, name: "good_cuts", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2070
+ { no: 9, name: "bad_cuts", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2071
+ { no: 10, name: "missed_notes", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2072
+ { no: 11, name: "bomb_hits", kind: "scalar", T: 13 /*ScalarType.UINT32*/ },
2073
+ { no: 12, name: "wall_hits", kind: "scalar", T: 13 /*ScalarType.UINT32*/ }
2074
+ ]);
2075
+ }
2076
+ create(value) {
2077
+ const message = globalThis.Object.create((this.messagePrototype));
2078
+ message.score = 0;
2079
+ message.modifiedScore = 0;
2080
+ message.maxScore = 0;
2081
+ message.accuracy = 0;
2082
+ message.combo = 0;
2083
+ message.maxCombo = 0;
2084
+ message.fullCombo = false;
2085
+ message.goodCuts = 0;
2086
+ message.badCuts = 0;
2087
+ message.missedNotes = 0;
2088
+ message.bombHits = 0;
2089
+ message.wallHits = 0;
2090
+ if (value !== undefined)
2091
+ reflectionMergePartial(this, message, value);
2092
+ return message;
2093
+ }
2094
+ internalBinaryRead(reader, length, options, target) {
2095
+ let message = target ?? this.create(), end = reader.pos + length;
2096
+ while (reader.pos < end) {
2097
+ let [fieldNo, wireType] = reader.tag();
2098
+ switch (fieldNo) {
2099
+ case /* uint32 score */ 1:
2100
+ message.score = reader.uint32();
2101
+ break;
2102
+ case /* uint32 modified_score */ 2:
2103
+ message.modifiedScore = reader.uint32();
2104
+ break;
2105
+ case /* uint32 max_score */ 3:
2106
+ message.maxScore = reader.uint32();
2107
+ break;
2108
+ case /* double accuracy */ 4:
2109
+ message.accuracy = reader.double();
2110
+ break;
2111
+ case /* uint32 combo */ 5:
2112
+ message.combo = reader.uint32();
2113
+ break;
2114
+ case /* uint32 max_combo */ 6:
2115
+ message.maxCombo = reader.uint32();
2116
+ break;
2117
+ case /* bool full_combo */ 7:
2118
+ message.fullCombo = reader.bool();
2119
+ break;
2120
+ case /* uint32 good_cuts */ 8:
2121
+ message.goodCuts = reader.uint32();
2122
+ break;
2123
+ case /* uint32 bad_cuts */ 9:
2124
+ message.badCuts = reader.uint32();
2125
+ break;
2126
+ case /* uint32 missed_notes */ 10:
2127
+ message.missedNotes = reader.uint32();
2128
+ break;
2129
+ case /* uint32 bomb_hits */ 11:
2130
+ message.bombHits = reader.uint32();
2131
+ break;
2132
+ case /* uint32 wall_hits */ 12:
2133
+ message.wallHits = reader.uint32();
2134
+ break;
2135
+ default:
2136
+ let u = options.readUnknownField;
2137
+ if (u === "throw")
2138
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
2139
+ let d = reader.skip(wireType);
2140
+ if (u !== false)
2141
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
2142
+ }
2143
+ }
2144
+ return message;
2145
+ }
2146
+ internalBinaryWrite(message, writer, options) {
2147
+ /* uint32 score = 1; */
2148
+ if (message.score !== 0)
2149
+ writer.tag(1, WireType.Varint).uint32(message.score);
2150
+ /* uint32 modified_score = 2; */
2151
+ if (message.modifiedScore !== 0)
2152
+ writer.tag(2, WireType.Varint).uint32(message.modifiedScore);
2153
+ /* uint32 max_score = 3; */
2154
+ if (message.maxScore !== 0)
2155
+ writer.tag(3, WireType.Varint).uint32(message.maxScore);
2156
+ /* double accuracy = 4; */
2157
+ if (message.accuracy !== 0)
2158
+ writer.tag(4, WireType.Bit64).double(message.accuracy);
2159
+ /* uint32 combo = 5; */
2160
+ if (message.combo !== 0)
2161
+ writer.tag(5, WireType.Varint).uint32(message.combo);
2162
+ /* uint32 max_combo = 6; */
2163
+ if (message.maxCombo !== 0)
2164
+ writer.tag(6, WireType.Varint).uint32(message.maxCombo);
2165
+ /* bool full_combo = 7; */
2166
+ if (message.fullCombo !== false)
2167
+ writer.tag(7, WireType.Varint).bool(message.fullCombo);
2168
+ /* uint32 good_cuts = 8; */
2169
+ if (message.goodCuts !== 0)
2170
+ writer.tag(8, WireType.Varint).uint32(message.goodCuts);
2171
+ /* uint32 bad_cuts = 9; */
2172
+ if (message.badCuts !== 0)
2173
+ writer.tag(9, WireType.Varint).uint32(message.badCuts);
2174
+ /* uint32 missed_notes = 10; */
2175
+ if (message.missedNotes !== 0)
2176
+ writer.tag(10, WireType.Varint).uint32(message.missedNotes);
2177
+ /* uint32 bomb_hits = 11; */
2178
+ if (message.bombHits !== 0)
2179
+ writer.tag(11, WireType.Varint).uint32(message.bombHits);
2180
+ /* uint32 wall_hits = 12; */
2181
+ if (message.wallHits !== 0)
2182
+ writer.tag(12, WireType.Varint).uint32(message.wallHits);
2183
+ let u = options.writeUnknownFields;
2184
+ if (u !== false)
2185
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
2186
+ return writer;
2187
+ }
2188
+ }
2189
+ /**
2190
+ * @generated MessageType for protobuf message proto.replay.ReplayScoreSummary
2191
+ */
2192
+ export const ReplayScoreSummary = new ReplayScoreSummary$Type();