game_client_logic_deb 1.3.47

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.
Files changed (28) hide show
  1. package/88b0986a7186d029-atomicfu-js-ir.js +202 -0
  2. package/88b0986a7186d029-atomicfu-js-ir.js.map +1 -0
  3. package/Kaverit-kaverit-js-ir.js +383 -0
  4. package/Kaverit-kaverit-js-ir.js.map +1 -0
  5. package/Kodein-kodein-di-js-ir.js +2793 -0
  6. package/Kodein-kodein-di-js-ir.js.map +1 -0
  7. package/Kotlin-DateTime-library-kotlinx-datetime-js-ir.js +167 -0
  8. package/Kotlin-DateTime-library-kotlinx-datetime-js-ir.js.map +1 -0
  9. package/Logic_Debertz-core.js +3214 -0
  10. package/Logic_Debertz-core.js.map +1 -0
  11. package/Logic_Debertz-engine.js +21765 -0
  12. package/Logic_Debertz-engine.js.map +1 -0
  13. package/Logic_Debertz-game_client_logic_deb.d.ts +592 -0
  14. package/Logic_Debertz-game_client_logic_deb.js +13899 -0
  15. package/Logic_Debertz-game_client_logic_deb.js.map +1 -0
  16. package/kotlin-kotlin-stdlib-js-ir.js +13032 -0
  17. package/kotlin-kotlin-stdlib-js-ir.js.map +1 -0
  18. package/kotlin-kotlinx-atomicfu-runtime-js-ir.js +15 -0
  19. package/kotlin-kotlinx-atomicfu-runtime-js-ir.js.map +1 -0
  20. package/kotlinx-serialization-kotlinx-serialization-core-js-ir.js +3622 -0
  21. package/kotlinx-serialization-kotlinx-serialization-core-js-ir.js.map +1 -0
  22. package/kotlinx-serialization-kotlinx-serialization-json-js-ir.js +293 -0
  23. package/kotlinx-serialization-kotlinx-serialization-json-js-ir.js.map +1 -0
  24. package/kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js +10834 -0
  25. package/kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js.map +1 -0
  26. package/package.json +6 -0
  27. package/uuid-js-ir.js +202 -0
  28. package/uuid-js-ir.js.map +1 -0
@@ -0,0 +1,3214 @@
1
+ (function (root, factory) {
2
+ if (typeof define === 'function' && define.amd)
3
+ define(['exports', './kotlin-kotlin-stdlib-js-ir.js', './kotlinx-serialization-kotlinx-serialization-core-js-ir.js', './kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js', './Kodein-kodein-di-js-ir.js'], factory);
4
+ else if (typeof exports === 'object')
5
+ factory(module.exports, require('./kotlin-kotlin-stdlib-js-ir.js'), require('./kotlinx-serialization-kotlinx-serialization-core-js-ir.js'), require('./kotlinx.coroutines-kotlinx-coroutines-core-js-ir.js'), require('./Kodein-kodein-di-js-ir.js'));
6
+ else {
7
+ if (typeof this['kotlin-kotlin-stdlib-js-ir'] === 'undefined') {
8
+ throw new Error("Error loading module 'Logic_Debertz-core'. Its dependency 'kotlin-kotlin-stdlib-js-ir' was not found. Please, check whether 'kotlin-kotlin-stdlib-js-ir' is loaded prior to 'Logic_Debertz-core'.");
9
+ }
10
+ if (typeof this['kotlinx-serialization-kotlinx-serialization-core-js-ir'] === 'undefined') {
11
+ throw new Error("Error loading module 'Logic_Debertz-core'. Its dependency 'kotlinx-serialization-kotlinx-serialization-core-js-ir' was not found. Please, check whether 'kotlinx-serialization-kotlinx-serialization-core-js-ir' is loaded prior to 'Logic_Debertz-core'.");
12
+ }
13
+ if (typeof this['kotlinx.coroutines-kotlinx-coroutines-core-js-ir'] === 'undefined') {
14
+ throw new Error("Error loading module 'Logic_Debertz-core'. Its dependency 'kotlinx.coroutines-kotlinx-coroutines-core-js-ir' was not found. Please, check whether 'kotlinx.coroutines-kotlinx-coroutines-core-js-ir' is loaded prior to 'Logic_Debertz-core'.");
15
+ }
16
+ if (typeof this['Kodein-kodein-di-js-ir'] === 'undefined') {
17
+ throw new Error("Error loading module 'Logic_Debertz-core'. Its dependency 'Kodein-kodein-di-js-ir' was not found. Please, check whether 'Kodein-kodein-di-js-ir' is loaded prior to 'Logic_Debertz-core'.");
18
+ }
19
+ root['Logic_Debertz-core'] = factory(typeof this['Logic_Debertz-core'] === 'undefined' ? {} : this['Logic_Debertz-core'], this['kotlin-kotlin-stdlib-js-ir'], this['kotlinx-serialization-kotlinx-serialization-core-js-ir'], this['kotlinx.coroutines-kotlinx-coroutines-core-js-ir'], this['Kodein-kodein-di-js-ir']);
20
+ }
21
+ }(this, function (_, kotlin_kotlin, kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core, kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core, kotlin_org_kodein_di_kodein_di) {
22
+ 'use strict';
23
+ //region block: imports
24
+ var imul = Math.imul;
25
+ var objectMeta = kotlin_kotlin.$_$.w6;
26
+ var Unit_getInstance = kotlin_kotlin.$_$.p2;
27
+ var ObjectSerializer_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.a;
28
+ var LazyThreadSafetyMode_PUBLICATION_getInstance = kotlin_kotlin.$_$.f;
29
+ var lazy = kotlin_kotlin.$_$.b9;
30
+ var SerializerFactory = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.s;
31
+ var getKClass = kotlin_kotlin.$_$.e;
32
+ var SealedClassSerializer_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.b;
33
+ var classMeta = kotlin_kotlin.$_$.j6;
34
+ var PluginGeneratedSerialDescriptor = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.r;
35
+ var StringSerializer_getInstance = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.h;
36
+ var typeParametersSerializers = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.o;
37
+ var GeneratedSerializer = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.p;
38
+ var getStringHashCode = kotlin_kotlin.$_$.o6;
39
+ var THROW_CCE = kotlin_kotlin.$_$.k8;
40
+ var get_nullable = kotlin_org_jetbrains_kotlinx_kotlinx_serialization_core.$_$.i;
41
+ var interfaceMeta = kotlin_kotlin.$_$.q6;
42
+ var Exception = kotlin_kotlin.$_$.c8;
43
+ var Exception_init_$Init$ = kotlin_kotlin.$_$.a1;
44
+ var captureStack = kotlin_kotlin.$_$.f6;
45
+ var toString = kotlin_kotlin.$_$.h9;
46
+ var hashCode = kotlin_kotlin.$_$.p6;
47
+ var equals = kotlin_kotlin.$_$.l6;
48
+ var ArrayList_init_$Create$ = kotlin_kotlin.$_$.l;
49
+ var THROW_ISE = kotlin_kotlin.$_$.l8;
50
+ var Enum = kotlin_kotlin.$_$.a8;
51
+ var Long = kotlin_kotlin.$_$.f8;
52
+ var toString_0 = kotlin_kotlin.$_$.z6;
53
+ var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.c1;
54
+ var Comparator = kotlin_kotlin.$_$.z7;
55
+ var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.e1;
56
+ var noWhenBranchMatchedException = kotlin_kotlin.$_$.d9;
57
+ var AbstractCoroutineContextElement = kotlin_kotlin.$_$.m5;
58
+ var Key_getInstance = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.g;
59
+ var get = kotlin_kotlin.$_$.t5;
60
+ var fold = kotlin_kotlin.$_$.s5;
61
+ var minusKey = kotlin_kotlin.$_$.u5;
62
+ var plus = kotlin_kotlin.$_$.x5;
63
+ var CoroutineExceptionHandler = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.o;
64
+ var Job$default = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.e;
65
+ var Dispatchers_getInstance = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.h;
66
+ var CoroutineScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.p;
67
+ var launch$default = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.f;
68
+ var Module_init_$Create$ = kotlin_org_kodein_di_kodein_di.$_$.a;
69
+ var MutableStateFlow = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.k;
70
+ var getKClassFromExpression = kotlin_kotlin.$_$.d;
71
+ var split$default = kotlin_kotlin.$_$.i;
72
+ var first = kotlin_kotlin.$_$.a4;
73
+ var isObject = kotlin_kotlin.$_$.s6;
74
+ var checkIndexOverflow = kotlin_kotlin.$_$.k3;
75
+ var single = kotlin_kotlin.$_$.t4;
76
+ var get_lastIndex = kotlin_kotlin.$_$.f4;
77
+ var toMutableList = kotlin_kotlin.$_$.d5;
78
+ var printStackTrace = kotlin_kotlin.$_$.e9;
79
+ var isBlank = kotlin_kotlin.$_$.p7;
80
+ var stackTraceToString = kotlin_kotlin.$_$.f9;
81
+ //endregion
82
+ //region block: pre-declaration
83
+ GameErrorReason.prototype = Object.create(TerminationGameReason.prototype);
84
+ GameErrorReason.prototype.constructor = GameErrorReason;
85
+ GameFinishedReason.prototype = Object.create(TerminationGameReason.prototype);
86
+ GameFinishedReason.prototype.constructor = GameFinishedReason;
87
+ PlayerExitReason.prototype = Object.create(TerminationGameReason.prototype);
88
+ PlayerExitReason.prototype.constructor = PlayerExitReason;
89
+ PlayerLostConnectionReason.prototype = Object.create(TerminationGameReason.prototype);
90
+ PlayerLostConnectionReason.prototype.constructor = PlayerLostConnectionReason;
91
+ PlayerTimeoutReason.prototype = Object.create(TerminationGameReason.prototype);
92
+ PlayerTimeoutReason.prototype.constructor = PlayerTimeoutReason;
93
+ ProcessingReason.prototype = Object.create(TerminationGameReason.prototype);
94
+ ProcessingReason.prototype.constructor = ProcessingReason;
95
+ WaitingForConnectionReason.prototype = Object.create(TerminationGameReason.prototype);
96
+ WaitingForConnectionReason.prototype.constructor = WaitingForConnectionReason;
97
+ MechanicException.prototype = Object.create(Exception.prototype);
98
+ MechanicException.prototype.constructor = MechanicException;
99
+ PlayerConnectionState.prototype = Object.create(Enum.prototype);
100
+ PlayerConnectionState.prototype.constructor = PlayerConnectionState;
101
+ PlayerWaitingState.prototype = Object.create(Enum.prototype);
102
+ PlayerWaitingState.prototype.constructor = PlayerWaitingState;
103
+ RulesSetType.prototype = Object.create(Enum.prototype);
104
+ RulesSetType.prototype.constructor = RulesSetType;
105
+ CardName.prototype = Object.create(Enum.prototype);
106
+ CardName.prototype.constructor = CardName;
107
+ Suit.prototype = Object.create(Enum.prototype);
108
+ Suit.prototype.constructor = Suit;
109
+ _no_name_provided__qut3iv.prototype = Object.create(AbstractCoroutineContextElement.prototype);
110
+ _no_name_provided__qut3iv.prototype.constructor = _no_name_provided__qut3iv;
111
+ function launchWorker$default(context, block, $mask0, $handler) {
112
+ if (!(($mask0 & 1) === 0))
113
+ context = this.j23();
114
+ return $handler == null ? this.m23(context, block) : $handler(context, block);
115
+ }
116
+ function launchStore$default(context, block, $mask0, $handler) {
117
+ if (!(($mask0 & 1) === 0))
118
+ context = this.j23();
119
+ return $handler == null ? this.k23(context, block) : $handler(context, block);
120
+ }
121
+ function get_actionTag() {
122
+ return toString_0(getKClassFromExpression(this));
123
+ }
124
+ function canHandle(action) {
125
+ return true;
126
+ }
127
+ function canHandle_0(action) {
128
+ return true;
129
+ }
130
+ INIT.prototype = Object.create(StoreLifecycleAction.prototype);
131
+ INIT.prototype.constructor = INIT;
132
+ REPLACE.prototype = Object.create(StoreLifecycleAction.prototype);
133
+ REPLACE.prototype.constructor = REPLACE;
134
+ function ignoreBuffer() {
135
+ return false;
136
+ }
137
+ function ignoreExpectant() {
138
+ return false;
139
+ }
140
+ function d$default(tag, message, $mask0, $handler) {
141
+ if (!(($mask0 & 1) === 0))
142
+ tag = null;
143
+ var tmp;
144
+ if ($handler == null) {
145
+ this.d24(tag, message);
146
+ tmp = Unit_getInstance();
147
+ } else {
148
+ tmp = $handler(tag, message);
149
+ }
150
+ return tmp;
151
+ }
152
+ function e$default(tag, message, exception, $mask0, $handler) {
153
+ if (!(($mask0 & 1) === 0))
154
+ tag = null;
155
+ if (!(($mask0 & 2) === 0))
156
+ message = null;
157
+ if (!(($mask0 & 4) === 0))
158
+ exception = null;
159
+ var tmp;
160
+ if ($handler == null) {
161
+ this.e23(tag, message, exception);
162
+ tmp = Unit_getInstance();
163
+ } else {
164
+ tmp = $handler(tag, message, exception);
165
+ }
166
+ return tmp;
167
+ }
168
+ function w$default(tag, message, $mask0, $handler) {
169
+ if (!(($mask0 & 1) === 0))
170
+ tag = null;
171
+ var tmp;
172
+ if ($handler == null) {
173
+ this.g24(tag, message);
174
+ tmp = Unit_getInstance();
175
+ } else {
176
+ tmp = $handler(tag, message);
177
+ }
178
+ return tmp;
179
+ }
180
+ Category.prototype = Object.create(Enum.prototype);
181
+ Category.prototype.constructor = Category;
182
+ function e$default_0(tag, message, exception, payload, $mask0, $handler) {
183
+ if (!(($mask0 & 1) === 0))
184
+ tag = null;
185
+ if (!(($mask0 & 2) === 0))
186
+ message = null;
187
+ if (!(($mask0 & 4) === 0))
188
+ exception = null;
189
+ var tmp;
190
+ if ($handler == null) {
191
+ this.z24(tag, message, exception, payload);
192
+ tmp = Unit_getInstance();
193
+ } else {
194
+ tmp = $handler(tag, message, exception, payload);
195
+ }
196
+ return tmp;
197
+ }
198
+ //endregion
199
+ function GameEngineConfig() {
200
+ GameEngineConfig_instance = this;
201
+ this.z1y_1 = '1.3.47';
202
+ }
203
+ GameEngineConfig.prototype.a1z = function () {
204
+ return this.z1y_1;
205
+ };
206
+ GameEngineConfig.$metadata$ = objectMeta('GameEngineConfig');
207
+ Object.defineProperty(GameEngineConfig.prototype, 'version', {
208
+ configurable: true,
209
+ get: GameEngineConfig.prototype.a1z
210
+ });
211
+ var GameEngineConfig_instance;
212
+ function GameEngineConfig_getInstance() {
213
+ if (GameEngineConfig_instance == null)
214
+ new GameEngineConfig();
215
+ return GameEngineConfig_instance;
216
+ }
217
+ function RestartGameReason$$cachedSerializer$delegate$_anonymous__9ra4fb() {
218
+ var tmp = RestartGameReason_getInstance();
219
+ var tmp$ret$2;
220
+ // Inline function 'kotlin.arrayOf' call
221
+ var tmp$ret$1;
222
+ // Inline function 'kotlin.js.unsafeCast' call
223
+ var tmp$ret$0;
224
+ // Inline function 'kotlin.js.asDynamic' call
225
+ tmp$ret$0 = [];
226
+ tmp$ret$1 = tmp$ret$0;
227
+ tmp$ret$2 = tmp$ret$1;
228
+ return ObjectSerializer_init_$Create$('NEW_PARTY', tmp, tmp$ret$2);
229
+ }
230
+ function RestartGameReason() {
231
+ RestartGameReason_instance = this;
232
+ var tmp = this;
233
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
234
+ tmp.b1z_1 = lazy(tmp_0, RestartGameReason$$cachedSerializer$delegate$_anonymous__9ra4fb);
235
+ }
236
+ RestartGameReason.prototype.toString = function () {
237
+ return 'RestartGameReason';
238
+ };
239
+ RestartGameReason.prototype.c1z = function () {
240
+ return this.b1z_1.z1();
241
+ };
242
+ RestartGameReason.prototype.q1n = function (typeParamsSerializers) {
243
+ return this.c1z();
244
+ };
245
+ RestartGameReason.$metadata$ = objectMeta('RestartGameReason', [SerializerFactory], undefined, {0: RestartGameReason_getInstance});
246
+ var RestartGameReason_instance;
247
+ function RestartGameReason_getInstance() {
248
+ if (RestartGameReason_instance == null)
249
+ new RestartGameReason();
250
+ return RestartGameReason_instance;
251
+ }
252
+ function TerminationGameReason$Companion$$cachedSerializer$delegate$_anonymous__honqx0() {
253
+ var tmp = getKClass(TerminationGameReason);
254
+ var tmp$ret$2;
255
+ // Inline function 'kotlin.arrayOf' call
256
+ var tmp0_arrayOf = [getKClass(GameErrorReason), getKClass(GameFinishedReason), getKClass(PlayerExitReason), getKClass(PlayerLostConnectionReason), getKClass(PlayerTimeoutReason), getKClass(ProcessingReason), getKClass(WaitingForConnectionReason)];
257
+ var tmp$ret$1;
258
+ // Inline function 'kotlin.js.unsafeCast' call
259
+ var tmp$ret$0;
260
+ // Inline function 'kotlin.js.asDynamic' call
261
+ tmp$ret$0 = tmp0_arrayOf;
262
+ tmp$ret$1 = tmp$ret$0;
263
+ tmp$ret$2 = tmp$ret$1;
264
+ var tmp_0 = tmp$ret$2;
265
+ var tmp$ret$17;
266
+ // Inline function 'kotlin.arrayOf' call
267
+ var tmp_1 = GameErrorReason_getInstance();
268
+ var tmp$ret$5;
269
+ // Inline function 'kotlin.arrayOf' call
270
+ var tmp$ret$4;
271
+ // Inline function 'kotlin.js.unsafeCast' call
272
+ var tmp$ret$3;
273
+ // Inline function 'kotlin.js.asDynamic' call
274
+ tmp$ret$3 = [];
275
+ tmp$ret$4 = tmp$ret$3;
276
+ tmp$ret$5 = tmp$ret$4;
277
+ var tmp_2 = ObjectSerializer_init_$Create$('GAME_ERROR_TYPE', tmp_1, tmp$ret$5);
278
+ var tmp_3 = GameFinishedReason_getInstance();
279
+ var tmp$ret$8;
280
+ // Inline function 'kotlin.arrayOf' call
281
+ var tmp$ret$7;
282
+ // Inline function 'kotlin.js.unsafeCast' call
283
+ var tmp$ret$6;
284
+ // Inline function 'kotlin.js.asDynamic' call
285
+ tmp$ret$6 = [];
286
+ tmp$ret$7 = tmp$ret$6;
287
+ tmp$ret$8 = tmp$ret$7;
288
+ var tmp_4 = ObjectSerializer_init_$Create$('GAME_FINISHED_TYPE', tmp_3, tmp$ret$8);
289
+ var tmp_5 = $serializer_getInstance();
290
+ var tmp_6 = $serializer_getInstance_0();
291
+ var tmp_7 = $serializer_getInstance_1();
292
+ var tmp_8 = ProcessingReason_getInstance();
293
+ var tmp$ret$11;
294
+ // Inline function 'kotlin.arrayOf' call
295
+ var tmp$ret$10;
296
+ // Inline function 'kotlin.js.unsafeCast' call
297
+ var tmp$ret$9;
298
+ // Inline function 'kotlin.js.asDynamic' call
299
+ tmp$ret$9 = [];
300
+ tmp$ret$10 = tmp$ret$9;
301
+ tmp$ret$11 = tmp$ret$10;
302
+ var tmp_9 = ObjectSerializer_init_$Create$('PROCESSING_TYPE', tmp_8, tmp$ret$11);
303
+ var tmp_10 = WaitingForConnectionReason_getInstance();
304
+ var tmp$ret$14;
305
+ // Inline function 'kotlin.arrayOf' call
306
+ var tmp$ret$13;
307
+ // Inline function 'kotlin.js.unsafeCast' call
308
+ var tmp$ret$12;
309
+ // Inline function 'kotlin.js.asDynamic' call
310
+ tmp$ret$12 = [];
311
+ tmp$ret$13 = tmp$ret$12;
312
+ tmp$ret$14 = tmp$ret$13;
313
+ var tmp1_arrayOf = [tmp_2, tmp_4, tmp_5, tmp_6, tmp_7, tmp_9, ObjectSerializer_init_$Create$('WAITING_FOR_CONNECTION_TYPE', tmp_10, tmp$ret$14)];
314
+ var tmp$ret$16;
315
+ // Inline function 'kotlin.js.unsafeCast' call
316
+ var tmp$ret$15;
317
+ // Inline function 'kotlin.js.asDynamic' call
318
+ tmp$ret$15 = tmp1_arrayOf;
319
+ tmp$ret$16 = tmp$ret$15;
320
+ tmp$ret$17 = tmp$ret$16;
321
+ var tmp_11 = tmp$ret$17;
322
+ var tmp$ret$20;
323
+ // Inline function 'kotlin.arrayOf' call
324
+ var tmp$ret$19;
325
+ // Inline function 'kotlin.js.unsafeCast' call
326
+ var tmp$ret$18;
327
+ // Inline function 'kotlin.js.asDynamic' call
328
+ tmp$ret$18 = [];
329
+ tmp$ret$19 = tmp$ret$18;
330
+ tmp$ret$20 = tmp$ret$19;
331
+ return SealedClassSerializer_init_$Create$('com.logic.data.models.TerminationGameReason', tmp, tmp_0, tmp_11, tmp$ret$20);
332
+ }
333
+ function Companion() {
334
+ Companion_instance = this;
335
+ var tmp = this;
336
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
337
+ tmp.d1z_1 = lazy(tmp_0, TerminationGameReason$Companion$$cachedSerializer$delegate$_anonymous__honqx0);
338
+ }
339
+ Companion.prototype.serializer = function () {
340
+ return this.d1z_1.z1();
341
+ };
342
+ Companion.prototype.q1n = function (typeParamsSerializers) {
343
+ return this.serializer();
344
+ };
345
+ Companion.$metadata$ = objectMeta('Companion', [SerializerFactory]);
346
+ var Companion_instance;
347
+ function Companion_getInstance() {
348
+ if (Companion_instance == null)
349
+ new Companion();
350
+ return Companion_instance;
351
+ }
352
+ function TerminationGameReason_init_$Init$(seen1, serializationConstructorMarker, $this) {
353
+ return $this;
354
+ }
355
+ function TerminationGameReason_init_$Create$(seen1, serializationConstructorMarker) {
356
+ return TerminationGameReason_init_$Init$(seen1, serializationConstructorMarker, Object.create(TerminationGameReason.prototype));
357
+ }
358
+ function TerminationGameReason() {
359
+ Companion_getInstance();
360
+ }
361
+ TerminationGameReason.$metadata$ = classMeta('TerminationGameReason', undefined, undefined, {0: Companion_getInstance});
362
+ function GameErrorReason$$cachedSerializer$delegate$_anonymous__p2u5b0() {
363
+ var tmp = GameErrorReason_getInstance();
364
+ var tmp$ret$2;
365
+ // Inline function 'kotlin.arrayOf' call
366
+ var tmp$ret$1;
367
+ // Inline function 'kotlin.js.unsafeCast' call
368
+ var tmp$ret$0;
369
+ // Inline function 'kotlin.js.asDynamic' call
370
+ tmp$ret$0 = [];
371
+ tmp$ret$1 = tmp$ret$0;
372
+ tmp$ret$2 = tmp$ret$1;
373
+ return ObjectSerializer_init_$Create$('GAME_ERROR_TYPE', tmp, tmp$ret$2);
374
+ }
375
+ function GameErrorReason() {
376
+ GameErrorReason_instance = this;
377
+ TerminationGameReason.call(this);
378
+ var tmp = this;
379
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
380
+ tmp.e1z_1 = lazy(tmp_0, GameErrorReason$$cachedSerializer$delegate$_anonymous__p2u5b0);
381
+ }
382
+ GameErrorReason.prototype.toString = function () {
383
+ return 'GameErrorReason';
384
+ };
385
+ GameErrorReason.prototype.c1z = function () {
386
+ return this.e1z_1.z1();
387
+ };
388
+ GameErrorReason.prototype.q1n = function (typeParamsSerializers) {
389
+ return this.c1z();
390
+ };
391
+ GameErrorReason.$metadata$ = objectMeta('GameErrorReason', [SerializerFactory], undefined, {0: GameErrorReason_getInstance}, undefined, TerminationGameReason.prototype);
392
+ var GameErrorReason_instance;
393
+ function GameErrorReason_getInstance() {
394
+ if (GameErrorReason_instance == null)
395
+ new GameErrorReason();
396
+ return GameErrorReason_instance;
397
+ }
398
+ function GameFinishedReason$$cachedSerializer$delegate$_anonymous__474t2i() {
399
+ var tmp = GameFinishedReason_getInstance();
400
+ var tmp$ret$2;
401
+ // Inline function 'kotlin.arrayOf' call
402
+ var tmp$ret$1;
403
+ // Inline function 'kotlin.js.unsafeCast' call
404
+ var tmp$ret$0;
405
+ // Inline function 'kotlin.js.asDynamic' call
406
+ tmp$ret$0 = [];
407
+ tmp$ret$1 = tmp$ret$0;
408
+ tmp$ret$2 = tmp$ret$1;
409
+ return ObjectSerializer_init_$Create$('GAME_FINISHED_TYPE', tmp, tmp$ret$2);
410
+ }
411
+ function GameFinishedReason() {
412
+ GameFinishedReason_instance = this;
413
+ TerminationGameReason.call(this);
414
+ var tmp = this;
415
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
416
+ tmp.f1z_1 = lazy(tmp_0, GameFinishedReason$$cachedSerializer$delegate$_anonymous__474t2i);
417
+ }
418
+ GameFinishedReason.prototype.toString = function () {
419
+ return 'GameFinishedReason';
420
+ };
421
+ GameFinishedReason.prototype.c1z = function () {
422
+ return this.f1z_1.z1();
423
+ };
424
+ GameFinishedReason.prototype.q1n = function (typeParamsSerializers) {
425
+ return this.c1z();
426
+ };
427
+ GameFinishedReason.$metadata$ = objectMeta('GameFinishedReason', [SerializerFactory], undefined, {0: GameFinishedReason_getInstance}, undefined, TerminationGameReason.prototype);
428
+ var GameFinishedReason_instance;
429
+ function GameFinishedReason_getInstance() {
430
+ if (GameFinishedReason_instance == null)
431
+ new GameFinishedReason();
432
+ return GameFinishedReason_instance;
433
+ }
434
+ function Companion_0() {
435
+ Companion_instance_0 = this;
436
+ }
437
+ Companion_0.$metadata$ = objectMeta('Companion');
438
+ var Companion_instance_0;
439
+ function Companion_getInstance_0() {
440
+ if (Companion_instance_0 == null)
441
+ new Companion_0();
442
+ return Companion_instance_0;
443
+ }
444
+ function $serializer() {
445
+ $serializer_instance = this;
446
+ var tmp0_serialDesc = new PluginGeneratedSerialDescriptor('PLAYER_EXIT', this, 1);
447
+ tmp0_serialDesc.q1m('playerId', false);
448
+ this.g1z_1 = tmp0_serialDesc;
449
+ }
450
+ $serializer.prototype.x1h = function () {
451
+ return this.g1z_1;
452
+ };
453
+ $serializer.prototype.g1n = function () {
454
+ var tmp$ret$2;
455
+ // Inline function 'kotlin.arrayOf' call
456
+ var tmp0_arrayOf = [StringSerializer_getInstance()];
457
+ var tmp$ret$1;
458
+ // Inline function 'kotlin.js.unsafeCast' call
459
+ var tmp$ret$0;
460
+ // Inline function 'kotlin.js.asDynamic' call
461
+ tmp$ret$0 = tmp0_arrayOf;
462
+ tmp$ret$1 = tmp$ret$0;
463
+ tmp$ret$2 = tmp$ret$1;
464
+ return tmp$ret$2;
465
+ };
466
+ $serializer.$metadata$ = objectMeta('$serializer', [GeneratedSerializer]);
467
+ var $serializer_instance;
468
+ function $serializer_getInstance() {
469
+ if ($serializer_instance == null)
470
+ new $serializer();
471
+ return $serializer_instance;
472
+ }
473
+ function PlayerExitReason(playerId) {
474
+ Companion_getInstance_0();
475
+ TerminationGameReason.call(this);
476
+ this.h1z_1 = playerId;
477
+ }
478
+ PlayerExitReason.prototype.i1z = function () {
479
+ return this.h1z_1;
480
+ };
481
+ PlayerExitReason.prototype.toString = function () {
482
+ return 'PlayerExitReason(playerId=' + this.h1z_1 + ')';
483
+ };
484
+ PlayerExitReason.prototype.hashCode = function () {
485
+ return getStringHashCode(this.h1z_1);
486
+ };
487
+ PlayerExitReason.prototype.equals = function (other) {
488
+ if (this === other)
489
+ return true;
490
+ if (!(other instanceof PlayerExitReason))
491
+ return false;
492
+ var tmp0_other_with_cast = other instanceof PlayerExitReason ? other : THROW_CCE();
493
+ if (!(this.h1z_1 === tmp0_other_with_cast.h1z_1))
494
+ return false;
495
+ return true;
496
+ };
497
+ PlayerExitReason.$metadata$ = classMeta('PlayerExitReason', [FinishPlayerReason], undefined, {0: $serializer_getInstance}, undefined, TerminationGameReason.prototype);
498
+ function Companion_1() {
499
+ Companion_instance_1 = this;
500
+ }
501
+ Companion_1.$metadata$ = objectMeta('Companion');
502
+ var Companion_instance_1;
503
+ function Companion_getInstance_1() {
504
+ if (Companion_instance_1 == null)
505
+ new Companion_1();
506
+ return Companion_instance_1;
507
+ }
508
+ function $serializer_0() {
509
+ $serializer_instance_0 = this;
510
+ var tmp0_serialDesc = new PluginGeneratedSerialDescriptor('PLAYER_LOST_CONNECTION', this, 2);
511
+ tmp0_serialDesc.q1m('playerId', false);
512
+ tmp0_serialDesc.q1m('tag', false);
513
+ this.j1z_1 = tmp0_serialDesc;
514
+ }
515
+ $serializer_0.prototype.x1h = function () {
516
+ return this.j1z_1;
517
+ };
518
+ $serializer_0.prototype.g1n = function () {
519
+ var tmp$ret$2;
520
+ // Inline function 'kotlin.arrayOf' call
521
+ var tmp0_arrayOf = [StringSerializer_getInstance(), get_nullable(StringSerializer_getInstance())];
522
+ var tmp$ret$1;
523
+ // Inline function 'kotlin.js.unsafeCast' call
524
+ var tmp$ret$0;
525
+ // Inline function 'kotlin.js.asDynamic' call
526
+ tmp$ret$0 = tmp0_arrayOf;
527
+ tmp$ret$1 = tmp$ret$0;
528
+ tmp$ret$2 = tmp$ret$1;
529
+ return tmp$ret$2;
530
+ };
531
+ $serializer_0.$metadata$ = objectMeta('$serializer', [GeneratedSerializer]);
532
+ var $serializer_instance_0;
533
+ function $serializer_getInstance_0() {
534
+ if ($serializer_instance_0 == null)
535
+ new $serializer_0();
536
+ return $serializer_instance_0;
537
+ }
538
+ function PlayerLostConnectionReason(playerId, tag) {
539
+ Companion_getInstance_1();
540
+ TerminationGameReason.call(this);
541
+ this.k1z_1 = playerId;
542
+ this.l1z_1 = tag;
543
+ }
544
+ PlayerLostConnectionReason.prototype.i1z = function () {
545
+ return this.k1z_1;
546
+ };
547
+ PlayerLostConnectionReason.prototype.toString = function () {
548
+ return 'PlayerLostConnectionReason(playerId=' + this.k1z_1 + ', tag=' + this.l1z_1 + ')';
549
+ };
550
+ PlayerLostConnectionReason.prototype.hashCode = function () {
551
+ var result = getStringHashCode(this.k1z_1);
552
+ result = imul(result, 31) + (this.l1z_1 == null ? 0 : getStringHashCode(this.l1z_1)) | 0;
553
+ return result;
554
+ };
555
+ PlayerLostConnectionReason.prototype.equals = function (other) {
556
+ if (this === other)
557
+ return true;
558
+ if (!(other instanceof PlayerLostConnectionReason))
559
+ return false;
560
+ var tmp0_other_with_cast = other instanceof PlayerLostConnectionReason ? other : THROW_CCE();
561
+ if (!(this.k1z_1 === tmp0_other_with_cast.k1z_1))
562
+ return false;
563
+ if (!(this.l1z_1 == tmp0_other_with_cast.l1z_1))
564
+ return false;
565
+ return true;
566
+ };
567
+ PlayerLostConnectionReason.$metadata$ = classMeta('PlayerLostConnectionReason', [FinishPlayerReason], undefined, {0: $serializer_getInstance_0}, undefined, TerminationGameReason.prototype);
568
+ function Companion_2() {
569
+ Companion_instance_2 = this;
570
+ }
571
+ Companion_2.$metadata$ = objectMeta('Companion');
572
+ var Companion_instance_2;
573
+ function Companion_getInstance_2() {
574
+ if (Companion_instance_2 == null)
575
+ new Companion_2();
576
+ return Companion_instance_2;
577
+ }
578
+ function $serializer_1() {
579
+ $serializer_instance_1 = this;
580
+ var tmp0_serialDesc = new PluginGeneratedSerialDescriptor('PLAYER_TIMEOUT', this, 2);
581
+ tmp0_serialDesc.q1m('playerId', false);
582
+ tmp0_serialDesc.q1m('tag', false);
583
+ this.m1z_1 = tmp0_serialDesc;
584
+ }
585
+ $serializer_1.prototype.x1h = function () {
586
+ return this.m1z_1;
587
+ };
588
+ $serializer_1.prototype.g1n = function () {
589
+ var tmp$ret$2;
590
+ // Inline function 'kotlin.arrayOf' call
591
+ var tmp0_arrayOf = [StringSerializer_getInstance(), get_nullable(StringSerializer_getInstance())];
592
+ var tmp$ret$1;
593
+ // Inline function 'kotlin.js.unsafeCast' call
594
+ var tmp$ret$0;
595
+ // Inline function 'kotlin.js.asDynamic' call
596
+ tmp$ret$0 = tmp0_arrayOf;
597
+ tmp$ret$1 = tmp$ret$0;
598
+ tmp$ret$2 = tmp$ret$1;
599
+ return tmp$ret$2;
600
+ };
601
+ $serializer_1.$metadata$ = objectMeta('$serializer', [GeneratedSerializer]);
602
+ var $serializer_instance_1;
603
+ function $serializer_getInstance_1() {
604
+ if ($serializer_instance_1 == null)
605
+ new $serializer_1();
606
+ return $serializer_instance_1;
607
+ }
608
+ function PlayerTimeoutReason(playerId, tag) {
609
+ Companion_getInstance_2();
610
+ TerminationGameReason.call(this);
611
+ this.n1z_1 = playerId;
612
+ this.o1z_1 = tag;
613
+ }
614
+ PlayerTimeoutReason.prototype.i1z = function () {
615
+ return this.n1z_1;
616
+ };
617
+ PlayerTimeoutReason.prototype.toString = function () {
618
+ return 'PlayerTimeoutReason(playerId=' + this.n1z_1 + ', tag=' + this.o1z_1 + ')';
619
+ };
620
+ PlayerTimeoutReason.prototype.hashCode = function () {
621
+ var result = getStringHashCode(this.n1z_1);
622
+ result = imul(result, 31) + (this.o1z_1 == null ? 0 : getStringHashCode(this.o1z_1)) | 0;
623
+ return result;
624
+ };
625
+ PlayerTimeoutReason.prototype.equals = function (other) {
626
+ if (this === other)
627
+ return true;
628
+ if (!(other instanceof PlayerTimeoutReason))
629
+ return false;
630
+ var tmp0_other_with_cast = other instanceof PlayerTimeoutReason ? other : THROW_CCE();
631
+ if (!(this.n1z_1 === tmp0_other_with_cast.n1z_1))
632
+ return false;
633
+ if (!(this.o1z_1 == tmp0_other_with_cast.o1z_1))
634
+ return false;
635
+ return true;
636
+ };
637
+ PlayerTimeoutReason.$metadata$ = classMeta('PlayerTimeoutReason', [FinishPlayerReason], undefined, {0: $serializer_getInstance_1}, undefined, TerminationGameReason.prototype);
638
+ function ProcessingReason$$cachedSerializer$delegate$_anonymous__b7cvvd() {
639
+ var tmp = ProcessingReason_getInstance();
640
+ var tmp$ret$2;
641
+ // Inline function 'kotlin.arrayOf' call
642
+ var tmp$ret$1;
643
+ // Inline function 'kotlin.js.unsafeCast' call
644
+ var tmp$ret$0;
645
+ // Inline function 'kotlin.js.asDynamic' call
646
+ tmp$ret$0 = [];
647
+ tmp$ret$1 = tmp$ret$0;
648
+ tmp$ret$2 = tmp$ret$1;
649
+ return ObjectSerializer_init_$Create$('PROCESSING_TYPE', tmp, tmp$ret$2);
650
+ }
651
+ function ProcessingReason() {
652
+ ProcessingReason_instance = this;
653
+ TerminationGameReason.call(this);
654
+ var tmp = this;
655
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
656
+ tmp.p1z_1 = lazy(tmp_0, ProcessingReason$$cachedSerializer$delegate$_anonymous__b7cvvd);
657
+ }
658
+ ProcessingReason.prototype.toString = function () {
659
+ return 'ProcessingReason';
660
+ };
661
+ ProcessingReason.prototype.c1z = function () {
662
+ return this.p1z_1.z1();
663
+ };
664
+ ProcessingReason.prototype.q1n = function (typeParamsSerializers) {
665
+ return this.c1z();
666
+ };
667
+ ProcessingReason.$metadata$ = objectMeta('ProcessingReason', [SerializerFactory], undefined, {0: ProcessingReason_getInstance}, undefined, TerminationGameReason.prototype);
668
+ var ProcessingReason_instance;
669
+ function ProcessingReason_getInstance() {
670
+ if (ProcessingReason_instance == null)
671
+ new ProcessingReason();
672
+ return ProcessingReason_instance;
673
+ }
674
+ function WaitingForConnectionReason$$cachedSerializer$delegate$_anonymous__dbld0g() {
675
+ var tmp = WaitingForConnectionReason_getInstance();
676
+ var tmp$ret$2;
677
+ // Inline function 'kotlin.arrayOf' call
678
+ var tmp$ret$1;
679
+ // Inline function 'kotlin.js.unsafeCast' call
680
+ var tmp$ret$0;
681
+ // Inline function 'kotlin.js.asDynamic' call
682
+ tmp$ret$0 = [];
683
+ tmp$ret$1 = tmp$ret$0;
684
+ tmp$ret$2 = tmp$ret$1;
685
+ return ObjectSerializer_init_$Create$('WAITING_FOR_CONNECTION_TYPE', tmp, tmp$ret$2);
686
+ }
687
+ function WaitingForConnectionReason() {
688
+ WaitingForConnectionReason_instance = this;
689
+ TerminationGameReason.call(this);
690
+ var tmp = this;
691
+ var tmp_0 = LazyThreadSafetyMode_PUBLICATION_getInstance();
692
+ tmp.q1z_1 = lazy(tmp_0, WaitingForConnectionReason$$cachedSerializer$delegate$_anonymous__dbld0g);
693
+ }
694
+ WaitingForConnectionReason.prototype.toString = function () {
695
+ return 'WaitingForConnectionReason';
696
+ };
697
+ WaitingForConnectionReason.prototype.c1z = function () {
698
+ return this.q1z_1.z1();
699
+ };
700
+ WaitingForConnectionReason.prototype.q1n = function (typeParamsSerializers) {
701
+ return this.c1z();
702
+ };
703
+ WaitingForConnectionReason.$metadata$ = objectMeta('WaitingForConnectionReason', [SerializerFactory], undefined, {0: WaitingForConnectionReason_getInstance}, undefined, TerminationGameReason.prototype);
704
+ var WaitingForConnectionReason_instance;
705
+ function WaitingForConnectionReason_getInstance() {
706
+ if (WaitingForConnectionReason_instance == null)
707
+ new WaitingForConnectionReason();
708
+ return WaitingForConnectionReason_instance;
709
+ }
710
+ function FinishPlayerReason() {
711
+ }
712
+ FinishPlayerReason.$metadata$ = interfaceMeta('FinishPlayerReason');
713
+ function MechanicException(message) {
714
+ Exception_init_$Init$(message, this);
715
+ captureStack(this, MechanicException);
716
+ }
717
+ MechanicException.$metadata$ = classMeta('MechanicException', undefined, undefined, undefined, undefined, Exception.prototype);
718
+ function GameUserInfo_init_$Init$(playerId, name, avatarUrl, payload, $mask0, $marker, $this) {
719
+ if (!(($mask0 & 8) === 0))
720
+ payload = null;
721
+ GameUserInfo.call($this, playerId, name, avatarUrl, payload);
722
+ return $this;
723
+ }
724
+ function GameUserInfo_init_$Create$(playerId, name, avatarUrl, payload, $mask0, $marker) {
725
+ return GameUserInfo_init_$Init$(playerId, name, avatarUrl, payload, $mask0, $marker, Object.create(GameUserInfo.prototype));
726
+ }
727
+ function GameUserInfo(playerId, name, avatarUrl, payload) {
728
+ var payload_0 = payload === void 1 ? null : payload;
729
+ this.r1z_1 = playerId;
730
+ this.s1z_1 = name;
731
+ this.t1z_1 = avatarUrl;
732
+ this.u1z_1 = payload_0;
733
+ }
734
+ GameUserInfo.prototype.i1z = function () {
735
+ return this.r1z_1;
736
+ };
737
+ GameUserInfo.prototype.c5 = function () {
738
+ return this.s1z_1;
739
+ };
740
+ GameUserInfo.prototype.v1z = function () {
741
+ return this.t1z_1;
742
+ };
743
+ GameUserInfo.prototype.w1z = function () {
744
+ return this.u1z_1;
745
+ };
746
+ GameUserInfo.prototype.component1 = function () {
747
+ return this.r1z_1;
748
+ };
749
+ GameUserInfo.prototype.component2 = function () {
750
+ return this.s1z_1;
751
+ };
752
+ GameUserInfo.prototype.component3 = function () {
753
+ return this.t1z_1;
754
+ };
755
+ GameUserInfo.prototype.component4 = function () {
756
+ return this.u1z_1;
757
+ };
758
+ GameUserInfo.prototype.copy = function (playerId, name, avatarUrl, payload) {
759
+ return this.x1z(playerId === void 1 ? this.r1z_1 : playerId, name === void 1 ? this.s1z_1 : name, avatarUrl === void 1 ? this.t1z_1 : avatarUrl, payload === void 1 ? this.u1z_1 : payload);
760
+ };
761
+ GameUserInfo.prototype.x1z = function (playerId, name, avatarUrl, payload) {
762
+ return new GameUserInfo(playerId, name, avatarUrl, payload);
763
+ };
764
+ GameUserInfo.prototype.y1z = function (playerId, name, avatarUrl, payload, $mask0, $handler) {
765
+ if (!(($mask0 & 1) === 0))
766
+ playerId = this.r1z_1;
767
+ if (!(($mask0 & 2) === 0))
768
+ name = this.s1z_1;
769
+ if (!(($mask0 & 4) === 0))
770
+ avatarUrl = this.t1z_1;
771
+ if (!(($mask0 & 8) === 0))
772
+ payload = this.u1z_1;
773
+ return this.x1z(playerId, name, avatarUrl, payload);
774
+ };
775
+ GameUserInfo.prototype.toString = function () {
776
+ return 'GameUserInfo(playerId=' + this.r1z_1 + ', name=' + this.s1z_1 + ', avatarUrl=' + this.t1z_1 + ', payload=' + toString(this.u1z_1) + ')';
777
+ };
778
+ GameUserInfo.prototype.hashCode = function () {
779
+ var result = getStringHashCode(this.r1z_1);
780
+ result = imul(result, 31) + getStringHashCode(this.s1z_1) | 0;
781
+ result = imul(result, 31) + getStringHashCode(this.t1z_1) | 0;
782
+ result = imul(result, 31) + (this.u1z_1 == null ? 0 : hashCode(this.u1z_1)) | 0;
783
+ return result;
784
+ };
785
+ GameUserInfo.prototype.equals = function (other) {
786
+ if (this === other)
787
+ return true;
788
+ if (!(other instanceof GameUserInfo))
789
+ return false;
790
+ var tmp0_other_with_cast = other instanceof GameUserInfo ? other : THROW_CCE();
791
+ if (!(this.r1z_1 === tmp0_other_with_cast.r1z_1))
792
+ return false;
793
+ if (!(this.s1z_1 === tmp0_other_with_cast.s1z_1))
794
+ return false;
795
+ if (!(this.t1z_1 === tmp0_other_with_cast.t1z_1))
796
+ return false;
797
+ if (!equals(this.u1z_1, tmp0_other_with_cast.u1z_1))
798
+ return false;
799
+ return true;
800
+ };
801
+ GameUserInfo.$metadata$ = classMeta('GameUserInfo', [PlayerIdContract]);
802
+ Object.defineProperty(GameUserInfo.prototype, 'playerId', {
803
+ configurable: true,
804
+ get: function () {
805
+ return this.i1z();
806
+ }
807
+ });
808
+ Object.defineProperty(GameUserInfo.prototype, 'name', {
809
+ configurable: true,
810
+ get: GameUserInfo.prototype.c5
811
+ });
812
+ Object.defineProperty(GameUserInfo.prototype, 'avatarUrl', {
813
+ configurable: true,
814
+ get: GameUserInfo.prototype.v1z
815
+ });
816
+ Object.defineProperty(GameUserInfo.prototype, 'payload', {
817
+ configurable: true,
818
+ get: GameUserInfo.prototype.w1z
819
+ });
820
+ function get_byIdPlayerPredicate() {
821
+ init_properties_Player_kt_txblev();
822
+ return byIdPlayerPredicate;
823
+ }
824
+ var byIdPlayerPredicate;
825
+ function get_playerTurnPredicate() {
826
+ init_properties_Player_kt_txblev();
827
+ return playerTurnPredicate;
828
+ }
829
+ var playerTurnPredicate;
830
+ function PlayerIdContract() {
831
+ }
832
+ PlayerIdContract.$metadata$ = interfaceMeta('PlayerIdContract');
833
+ function getPlayer(_this__u8e3s4, id) {
834
+ init_properties_Player_kt_txblev();
835
+ var tmp$ret$0;
836
+ $l$block_0: {
837
+ // Inline function 'kotlin.collections.singleOrNull' call
838
+ var tmp0_singleOrNull = get_byIdPlayerPredicate()(id);
839
+ var single = null;
840
+ var found = false;
841
+ var tmp0_iterator = _this__u8e3s4.f();
842
+ while (tmp0_iterator.g()) {
843
+ var element = tmp0_iterator.h();
844
+ if (tmp0_singleOrNull(element)) {
845
+ if (found) {
846
+ tmp$ret$0 = null;
847
+ break $l$block_0;
848
+ }
849
+ single = element;
850
+ found = true;
851
+ }
852
+ }
853
+ if (!found) {
854
+ tmp$ret$0 = null;
855
+ break $l$block_0;
856
+ }
857
+ tmp$ret$0 = single;
858
+ }
859
+ var player = tmp$ret$0;
860
+ if (!(player == null)) {
861
+ return player;
862
+ }
863
+ throw new MechanicException("Can't find player by id:" + id + ', in ' + _this__u8e3s4);
864
+ }
865
+ function getPlayerIndex(_this__u8e3s4, playerId) {
866
+ init_properties_Player_kt_txblev();
867
+ return findItemIndex(_this__u8e3s4, get_byIdPlayerPredicate()(playerId));
868
+ }
869
+ function Player() {
870
+ }
871
+ Player.$metadata$ = interfaceMeta('Player', [PlayerIdContract]);
872
+ function nextToPlayerId(_this__u8e3s4, playerId) {
873
+ init_properties_Player_kt_txblev();
874
+ return nextTo_0(_this__u8e3s4, get_byIdPlayerPredicate()(playerId));
875
+ }
876
+ function filterByPlayerId(_this__u8e3s4, id) {
877
+ init_properties_Player_kt_txblev();
878
+ var tmp$ret$1;
879
+ // Inline function 'kotlin.collections.filter' call
880
+ var tmp0_filter = get_byIdPlayerPredicate()(id);
881
+ var tmp$ret$0;
882
+ // Inline function 'kotlin.collections.filterTo' call
883
+ var tmp0_filterTo = ArrayList_init_$Create$();
884
+ var tmp0_iterator = _this__u8e3s4.f();
885
+ while (tmp0_iterator.g()) {
886
+ var element = tmp0_iterator.h();
887
+ if (tmp0_filter(element)) {
888
+ tmp0_filterTo.a(element);
889
+ }
890
+ }
891
+ tmp$ret$0 = tmp0_filterTo;
892
+ tmp$ret$1 = tmp$ret$0;
893
+ return tmp$ret$1;
894
+ }
895
+ function filterPlayerTurn(_this__u8e3s4) {
896
+ init_properties_Player_kt_txblev();
897
+ var tmp$ret$1;
898
+ // Inline function 'kotlin.collections.filter' call
899
+ var tmp0_filter = get_playerTurnPredicate();
900
+ var tmp$ret$0;
901
+ // Inline function 'kotlin.collections.filterTo' call
902
+ var tmp0_filterTo = ArrayList_init_$Create$();
903
+ var tmp0_iterator = _this__u8e3s4.f();
904
+ while (tmp0_iterator.g()) {
905
+ var element = tmp0_iterator.h();
906
+ if (tmp0_filter(element)) {
907
+ tmp0_filterTo.a(element);
908
+ }
909
+ }
910
+ tmp$ret$0 = tmp0_filterTo;
911
+ tmp$ret$1 = tmp$ret$0;
912
+ return tmp$ret$1;
913
+ }
914
+ function byIdPlayerPredicate$lambda(id) {
915
+ init_properties_Player_kt_txblev();
916
+ return byIdPlayerPredicate$lambda$lambda(id);
917
+ }
918
+ function byIdPlayerPredicate$lambda$lambda($id) {
919
+ return function (p1) {
920
+ return p1.playerId === $id;
921
+ };
922
+ }
923
+ function playerTurnPredicate$lambda(p1) {
924
+ init_properties_Player_kt_txblev();
925
+ return p1.hl().f20() ? true : p1.hl().e20();
926
+ }
927
+ var properties_initialized_Player_kt_56shkt;
928
+ function init_properties_Player_kt_txblev() {
929
+ if (properties_initialized_Player_kt_56shkt) {
930
+ } else {
931
+ properties_initialized_Player_kt_56shkt = true;
932
+ byIdPlayerPredicate = byIdPlayerPredicate$lambda;
933
+ playerTurnPredicate = playerTurnPredicate$lambda;
934
+ }
935
+ }
936
+ var PlayerConnectionState_LIVE_instance;
937
+ var PlayerConnectionState_TIMEOUT_instance;
938
+ var PlayerConnectionState_LOST_CONNECTION_instance;
939
+ var PlayerConnectionState_LEFT_instance;
940
+ var PlayerConnectionState_DISCONNECTING_instance;
941
+ var PlayerConnectionState_DELETED_instance;
942
+ function values() {
943
+ return [PlayerConnectionState_LIVE_getInstance(), PlayerConnectionState_TIMEOUT_getInstance(), PlayerConnectionState_LOST_CONNECTION_getInstance(), PlayerConnectionState_LEFT_getInstance(), PlayerConnectionState_DISCONNECTING_getInstance(), PlayerConnectionState_DELETED_getInstance()];
944
+ }
945
+ function valueOf(value) {
946
+ switch (value) {
947
+ case 'LIVE':
948
+ return PlayerConnectionState_LIVE_getInstance();
949
+ case 'TIMEOUT':
950
+ return PlayerConnectionState_TIMEOUT_getInstance();
951
+ case 'LOST_CONNECTION':
952
+ return PlayerConnectionState_LOST_CONNECTION_getInstance();
953
+ case 'LEFT':
954
+ return PlayerConnectionState_LEFT_getInstance();
955
+ case 'DISCONNECTING':
956
+ return PlayerConnectionState_DISCONNECTING_getInstance();
957
+ case 'DELETED':
958
+ return PlayerConnectionState_DELETED_getInstance();
959
+ default:
960
+ PlayerConnectionState_initEntries();
961
+ THROW_ISE();
962
+ break;
963
+ }
964
+ }
965
+ var PlayerConnectionState_entriesInitialized;
966
+ function PlayerConnectionState_initEntries() {
967
+ if (PlayerConnectionState_entriesInitialized)
968
+ return Unit_getInstance();
969
+ PlayerConnectionState_entriesInitialized = true;
970
+ PlayerConnectionState_LIVE_instance = new PlayerConnectionState('LIVE', 0);
971
+ PlayerConnectionState_TIMEOUT_instance = new PlayerConnectionState('TIMEOUT', 1);
972
+ PlayerConnectionState_LOST_CONNECTION_instance = new PlayerConnectionState('LOST_CONNECTION', 2);
973
+ PlayerConnectionState_LEFT_instance = new PlayerConnectionState('LEFT', 3);
974
+ PlayerConnectionState_DISCONNECTING_instance = new PlayerConnectionState('DISCONNECTING', 4);
975
+ PlayerConnectionState_DELETED_instance = new PlayerConnectionState('DELETED', 5);
976
+ }
977
+ function PlayerConnectionState(name, ordinal) {
978
+ Enum.call(this, name, ordinal);
979
+ }
980
+ PlayerConnectionState.prototype.i20 = function () {
981
+ return this.equals(PlayerConnectionState_LIVE_getInstance());
982
+ };
983
+ PlayerConnectionState.prototype.j20 = function () {
984
+ return this.equals(PlayerConnectionState_TIMEOUT_getInstance());
985
+ };
986
+ PlayerConnectionState.prototype.k20 = function () {
987
+ return this.equals(PlayerConnectionState_LOST_CONNECTION_getInstance());
988
+ };
989
+ PlayerConnectionState.prototype.l20 = function () {
990
+ return this.equals(PlayerConnectionState_LEFT_getInstance());
991
+ };
992
+ PlayerConnectionState.prototype.m20 = function () {
993
+ return this.equals(PlayerConnectionState_DELETED_getInstance());
994
+ };
995
+ PlayerConnectionState.prototype.n20 = function () {
996
+ return this.equals(PlayerConnectionState_DISCONNECTING_getInstance());
997
+ };
998
+ PlayerConnectionState.prototype.o20 = function () {
999
+ return ((this.isTimeOut ? true : this.isLostConnection) ? true : this.isLeft) ? true : this.isDeleted;
1000
+ };
1001
+ PlayerConnectionState.prototype.p20 = function () {
1002
+ return (this.isTimeOut ? true : this.isLostConnection) ? true : this.isLeft;
1003
+ };
1004
+ PlayerConnectionState.$metadata$ = classMeta('PlayerConnectionState', undefined, undefined, undefined, undefined, Enum.prototype);
1005
+ Object.defineProperty(PlayerConnectionState.prototype, 'isLive', {
1006
+ configurable: true,
1007
+ get: PlayerConnectionState.prototype.i20
1008
+ });
1009
+ Object.defineProperty(PlayerConnectionState.prototype, 'isTimeOut', {
1010
+ configurable: true,
1011
+ get: PlayerConnectionState.prototype.j20
1012
+ });
1013
+ Object.defineProperty(PlayerConnectionState.prototype, 'isLostConnection', {
1014
+ configurable: true,
1015
+ get: PlayerConnectionState.prototype.k20
1016
+ });
1017
+ Object.defineProperty(PlayerConnectionState.prototype, 'isLeft', {
1018
+ configurable: true,
1019
+ get: PlayerConnectionState.prototype.l20
1020
+ });
1021
+ Object.defineProperty(PlayerConnectionState.prototype, 'isDeleted', {
1022
+ configurable: true,
1023
+ get: PlayerConnectionState.prototype.m20
1024
+ });
1025
+ Object.defineProperty(PlayerConnectionState.prototype, 'isDisconnecting', {
1026
+ configurable: true,
1027
+ get: PlayerConnectionState.prototype.n20
1028
+ });
1029
+ Object.defineProperty(PlayerConnectionState.prototype, 'isNotAlive', {
1030
+ configurable: true,
1031
+ get: PlayerConnectionState.prototype.o20
1032
+ });
1033
+ Object.defineProperty(PlayerConnectionState.prototype, 'isPossibleToBeLive', {
1034
+ configurable: true,
1035
+ get: PlayerConnectionState.prototype.p20
1036
+ });
1037
+ Object.defineProperty(PlayerConnectionState.prototype, 'name', {
1038
+ configurable: true,
1039
+ get: PlayerConnectionState.prototype.c5
1040
+ });
1041
+ Object.defineProperty(PlayerConnectionState.prototype, 'ordinal', {
1042
+ configurable: true,
1043
+ get: PlayerConnectionState.prototype.wh
1044
+ });
1045
+ function PlayerConnectionState_LIVE_getInstance() {
1046
+ PlayerConnectionState_initEntries();
1047
+ return PlayerConnectionState_LIVE_instance;
1048
+ }
1049
+ function PlayerConnectionState_TIMEOUT_getInstance() {
1050
+ PlayerConnectionState_initEntries();
1051
+ return PlayerConnectionState_TIMEOUT_instance;
1052
+ }
1053
+ function PlayerConnectionState_LOST_CONNECTION_getInstance() {
1054
+ PlayerConnectionState_initEntries();
1055
+ return PlayerConnectionState_LOST_CONNECTION_instance;
1056
+ }
1057
+ function PlayerConnectionState_LEFT_getInstance() {
1058
+ PlayerConnectionState_initEntries();
1059
+ return PlayerConnectionState_LEFT_instance;
1060
+ }
1061
+ function PlayerConnectionState_DISCONNECTING_getInstance() {
1062
+ PlayerConnectionState_initEntries();
1063
+ return PlayerConnectionState_DISCONNECTING_instance;
1064
+ }
1065
+ function PlayerConnectionState_DELETED_getInstance() {
1066
+ PlayerConnectionState_initEntries();
1067
+ return PlayerConnectionState_DELETED_instance;
1068
+ }
1069
+ var PlayerWaitingState_IDLE_instance;
1070
+ var PlayerWaitingState_IN_PROGRESS_instance;
1071
+ var PlayerWaitingState_IN_PROGRESS_ATTENTION_MODE_instance;
1072
+ var PlayerWaitingState_entriesInitialized;
1073
+ function PlayerWaitingState_initEntries() {
1074
+ if (PlayerWaitingState_entriesInitialized)
1075
+ return Unit_getInstance();
1076
+ PlayerWaitingState_entriesInitialized = true;
1077
+ PlayerWaitingState_IDLE_instance = new PlayerWaitingState('IDLE', 0);
1078
+ PlayerWaitingState_IN_PROGRESS_instance = new PlayerWaitingState('IN_PROGRESS', 1);
1079
+ PlayerWaitingState_IN_PROGRESS_ATTENTION_MODE_instance = new PlayerWaitingState('IN_PROGRESS_ATTENTION_MODE', 2);
1080
+ }
1081
+ function PlayerWaitingState(name, ordinal) {
1082
+ Enum.call(this, name, ordinal);
1083
+ }
1084
+ PlayerWaitingState.prototype.f20 = function () {
1085
+ return this.equals(PlayerWaitingState_IN_PROGRESS_getInstance()) ? true : this.e20();
1086
+ };
1087
+ PlayerWaitingState.prototype.e20 = function () {
1088
+ return this.equals(PlayerWaitingState_IN_PROGRESS_ATTENTION_MODE_getInstance());
1089
+ };
1090
+ PlayerWaitingState.$metadata$ = classMeta('PlayerWaitingState', undefined, undefined, undefined, undefined, Enum.prototype);
1091
+ function Companion_3() {
1092
+ Companion_instance_3 = this;
1093
+ }
1094
+ Companion_3.prototype.s20 = function (connectionState) {
1095
+ var tmp0_state = PlayerWaitingState_IDLE_getInstance();
1096
+ return new PlayerState(new Long(0, 0), tmp0_state, false, connectionState, null);
1097
+ };
1098
+ Companion_3.prototype.t20 = function (_this__u8e3s4, startFromTime, tag) {
1099
+ var tmp = PlayerWaitingState_IN_PROGRESS_getInstance();
1100
+ return _this__u8e3s4.u20(startFromTime, tmp, false, null, tag, 12, null);
1101
+ };
1102
+ Companion_3.$metadata$ = objectMeta('Companion');
1103
+ var Companion_instance_3;
1104
+ function Companion_getInstance_3() {
1105
+ if (Companion_instance_3 == null)
1106
+ new Companion_3();
1107
+ return Companion_instance_3;
1108
+ }
1109
+ function PlayerWaitingState_IDLE_getInstance() {
1110
+ PlayerWaitingState_initEntries();
1111
+ return PlayerWaitingState_IDLE_instance;
1112
+ }
1113
+ function PlayerWaitingState_IN_PROGRESS_getInstance() {
1114
+ PlayerWaitingState_initEntries();
1115
+ return PlayerWaitingState_IN_PROGRESS_instance;
1116
+ }
1117
+ function PlayerWaitingState_IN_PROGRESS_ATTENTION_MODE_getInstance() {
1118
+ PlayerWaitingState_initEntries();
1119
+ return PlayerWaitingState_IN_PROGRESS_ATTENTION_MODE_instance;
1120
+ }
1121
+ function PlayerState(startFromTime, state, ready, connectionState, tag) {
1122
+ Companion_getInstance_3();
1123
+ this.z1z_1 = startFromTime;
1124
+ this.a20_1 = state;
1125
+ this.b20_1 = ready;
1126
+ this.c20_1 = connectionState;
1127
+ this.d20_1 = tag;
1128
+ }
1129
+ PlayerState.prototype.v20 = function () {
1130
+ return this.b20_1;
1131
+ };
1132
+ PlayerState.prototype.w20 = function () {
1133
+ return this.c20_1;
1134
+ };
1135
+ PlayerState.prototype.x20 = function () {
1136
+ var tmp$ret$2;
1137
+ // Inline function 'kotlin.requireNotNull' call
1138
+ var tmp0_requireNotNull = this.d20_1;
1139
+ // Inline function 'kotlin.contracts.contract' call
1140
+ var tmp$ret$1;
1141
+ $l$block: {
1142
+ // Inline function 'kotlin.requireNotNull' call
1143
+ // Inline function 'kotlin.contracts.contract' call
1144
+ if (tmp0_requireNotNull == null) {
1145
+ var tmp$ret$0;
1146
+ // Inline function 'kotlin.requireNotNull.<anonymous>' call
1147
+ tmp$ret$0 = 'Required value was null.';
1148
+ var message = tmp$ret$0;
1149
+ throw IllegalArgumentException_init_$Create$(toString_0(message));
1150
+ } else {
1151
+ tmp$ret$1 = tmp0_requireNotNull;
1152
+ break $l$block;
1153
+ }
1154
+ }
1155
+ tmp$ret$2 = tmp$ret$1;
1156
+ return tmp$ret$2;
1157
+ };
1158
+ PlayerState.prototype.y20 = function () {
1159
+ var tmp0_elvis_lhs = this.d20_1;
1160
+ return tmp0_elvis_lhs == null ? '' : tmp0_elvis_lhs;
1161
+ };
1162
+ PlayerState.prototype.f20 = function () {
1163
+ return this.a20_1.f20();
1164
+ };
1165
+ PlayerState.prototype.e20 = function () {
1166
+ return this.a20_1.e20();
1167
+ };
1168
+ PlayerState.prototype.z20 = function (startFromTime, state, ready, connectionState, tag) {
1169
+ return new PlayerState(startFromTime, state, ready, connectionState, tag);
1170
+ };
1171
+ PlayerState.prototype.u20 = function (startFromTime, state, ready, connectionState, tag, $mask0, $handler) {
1172
+ if (!(($mask0 & 1) === 0))
1173
+ startFromTime = this.z1z_1;
1174
+ if (!(($mask0 & 2) === 0))
1175
+ state = this.a20_1;
1176
+ if (!(($mask0 & 4) === 0))
1177
+ ready = this.b20_1;
1178
+ if (!(($mask0 & 8) === 0))
1179
+ connectionState = this.c20_1;
1180
+ if (!(($mask0 & 16) === 0))
1181
+ tag = this.d20_1;
1182
+ return this.z20(startFromTime, state, ready, connectionState, tag);
1183
+ };
1184
+ PlayerState.prototype.toString = function () {
1185
+ return 'PlayerState(startFromTime=' + toString_0(this.z1z_1) + ', state=' + this.a20_1 + ', ready=' + this.b20_1 + ', connectionState=' + this.c20_1 + ', tag=' + this.d20_1 + ')';
1186
+ };
1187
+ PlayerState.prototype.hashCode = function () {
1188
+ var result = this.z1z_1.hashCode();
1189
+ result = imul(result, 31) + this.a20_1.hashCode() | 0;
1190
+ result = imul(result, 31) + (this.b20_1 | 0) | 0;
1191
+ result = imul(result, 31) + this.c20_1.hashCode() | 0;
1192
+ result = imul(result, 31) + (this.d20_1 == null ? 0 : getStringHashCode(this.d20_1)) | 0;
1193
+ return result;
1194
+ };
1195
+ PlayerState.prototype.equals = function (other) {
1196
+ if (this === other)
1197
+ return true;
1198
+ if (!(other instanceof PlayerState))
1199
+ return false;
1200
+ var tmp0_other_with_cast = other instanceof PlayerState ? other : THROW_CCE();
1201
+ if (!this.z1z_1.equals(tmp0_other_with_cast.z1z_1))
1202
+ return false;
1203
+ if (!this.a20_1.equals(tmp0_other_with_cast.a20_1))
1204
+ return false;
1205
+ if (!(this.b20_1 === tmp0_other_with_cast.b20_1))
1206
+ return false;
1207
+ if (!this.c20_1.equals(tmp0_other_with_cast.c20_1))
1208
+ return false;
1209
+ if (!(this.d20_1 == tmp0_other_with_cast.d20_1))
1210
+ return false;
1211
+ return true;
1212
+ };
1213
+ PlayerState.$metadata$ = classMeta('PlayerState');
1214
+ function Team(playerIds) {
1215
+ this.a21_1 = playerIds;
1216
+ }
1217
+ Team.prototype.toString = function () {
1218
+ return 'Team(playerIds=' + this.a21_1 + ')';
1219
+ };
1220
+ Team.prototype.hashCode = function () {
1221
+ return hashCode(this.a21_1);
1222
+ };
1223
+ Team.prototype.equals = function (other) {
1224
+ if (this === other)
1225
+ return true;
1226
+ if (!(other instanceof Team))
1227
+ return false;
1228
+ var tmp0_other_with_cast = other instanceof Team ? other : THROW_CCE();
1229
+ if (!equals(this.a21_1, tmp0_other_with_cast.a21_1))
1230
+ return false;
1231
+ return true;
1232
+ };
1233
+ Team.$metadata$ = classMeta('Team');
1234
+ function Companion_4() {
1235
+ Companion_instance_4 = this;
1236
+ }
1237
+ Companion_4.prototype.kharkiv = function () {
1238
+ return new Rules(true, true, true, false, true, true, true, false, false, false, true, 50, true, false, true, false);
1239
+ };
1240
+ Companion_4.prototype.klabor = function () {
1241
+ return new Rules(true, false, true, true, true, false, true, false, false, true, true, 100, true, true, false, false);
1242
+ };
1243
+ Companion_4.prototype.debertzCommon = function () {
1244
+ return new Rules(true, false, false, true, true, true, false, false, true, false, false, 0, false, true, false, false);
1245
+ };
1246
+ Companion_4.prototype.moscow = function () {
1247
+ return new Rules(true, false, false, true, true, true, false, true, true, false, false, 0, false, true, false, false);
1248
+ };
1249
+ Companion_4.prototype.belot = function () {
1250
+ return new Rules(true, true, false, true, true, true, false, true, true, false, false, 50, false, true, false, false);
1251
+ };
1252
+ Companion_4.prototype.custom = function () {
1253
+ return new Rules(false, false, false, true, true, true, false, false, false, false, false, 50, false, false, false, false);
1254
+ };
1255
+ Companion_4.$metadata$ = objectMeta('Companion');
1256
+ var Companion_instance_4;
1257
+ function Companion_getInstance_4() {
1258
+ if (Companion_instance_4 == null)
1259
+ new Companion_4();
1260
+ return Companion_instance_4;
1261
+ }
1262
+ function Rules(needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand) {
1263
+ Companion_getInstance_4();
1264
+ this.b21_1 = needToPutHigherTrump;
1265
+ this.c21_1 = distributePoints;
1266
+ this.d21_1 = protectBella;
1267
+ this.e21_1 = enableFourSevensCombination;
1268
+ this.f21_1 = enableTrumpSevenCombination;
1269
+ this.g21_1 = enableTrumpSevenCombinationAfterDistribution;
1270
+ this.h21_1 = playerWhoChooseSuitGoFirst;
1271
+ this.i21_1 = winnerShuffleCards;
1272
+ this.j21_1 = playWithoutLiabilities;
1273
+ this.k21_1 = trumpCardGoToPlayerWhoShuffleCards;
1274
+ this.l21_1 = enableFineIfNoBribes;
1275
+ this.m21_1 = fineIfNoBribes;
1276
+ this.n21_1 = enableFineAfterThirdByte;
1277
+ this.o21_1 = checkTrumpCombination;
1278
+ this.p21_1 = checkOnlyTrumpDebertz;
1279
+ this.q21_1 = tenCardsInHand;
1280
+ }
1281
+ Rules.prototype.r21 = function () {
1282
+ return this.b21_1;
1283
+ };
1284
+ Rules.prototype.s21 = function () {
1285
+ return this.c21_1;
1286
+ };
1287
+ Rules.prototype.t21 = function () {
1288
+ return this.d21_1;
1289
+ };
1290
+ Rules.prototype.u21 = function () {
1291
+ return this.e21_1;
1292
+ };
1293
+ Rules.prototype.v21 = function () {
1294
+ return this.f21_1;
1295
+ };
1296
+ Rules.prototype.w21 = function () {
1297
+ return this.g21_1;
1298
+ };
1299
+ Rules.prototype.x21 = function () {
1300
+ return this.h21_1;
1301
+ };
1302
+ Rules.prototype.y21 = function () {
1303
+ return this.i21_1;
1304
+ };
1305
+ Rules.prototype.z21 = function () {
1306
+ return this.j21_1;
1307
+ };
1308
+ Rules.prototype.a22 = function () {
1309
+ return this.k21_1;
1310
+ };
1311
+ Rules.prototype.b22 = function () {
1312
+ return this.l21_1;
1313
+ };
1314
+ Rules.prototype.c22 = function () {
1315
+ return this.m21_1;
1316
+ };
1317
+ Rules.prototype.d22 = function () {
1318
+ return this.n21_1;
1319
+ };
1320
+ Rules.prototype.e22 = function () {
1321
+ return this.o21_1;
1322
+ };
1323
+ Rules.prototype.f22 = function () {
1324
+ return this.p21_1;
1325
+ };
1326
+ Rules.prototype.g22 = function () {
1327
+ return this.q21_1;
1328
+ };
1329
+ Rules.prototype.component1 = function () {
1330
+ return this.b21_1;
1331
+ };
1332
+ Rules.prototype.component2 = function () {
1333
+ return this.c21_1;
1334
+ };
1335
+ Rules.prototype.component3 = function () {
1336
+ return this.d21_1;
1337
+ };
1338
+ Rules.prototype.component4 = function () {
1339
+ return this.e21_1;
1340
+ };
1341
+ Rules.prototype.component5 = function () {
1342
+ return this.f21_1;
1343
+ };
1344
+ Rules.prototype.component6 = function () {
1345
+ return this.g21_1;
1346
+ };
1347
+ Rules.prototype.component7 = function () {
1348
+ return this.h21_1;
1349
+ };
1350
+ Rules.prototype.component8 = function () {
1351
+ return this.i21_1;
1352
+ };
1353
+ Rules.prototype.component9 = function () {
1354
+ return this.j21_1;
1355
+ };
1356
+ Rules.prototype.component10 = function () {
1357
+ return this.k21_1;
1358
+ };
1359
+ Rules.prototype.component11 = function () {
1360
+ return this.l21_1;
1361
+ };
1362
+ Rules.prototype.component12 = function () {
1363
+ return this.m21_1;
1364
+ };
1365
+ Rules.prototype.component13 = function () {
1366
+ return this.n21_1;
1367
+ };
1368
+ Rules.prototype.component14 = function () {
1369
+ return this.o21_1;
1370
+ };
1371
+ Rules.prototype.component15 = function () {
1372
+ return this.p21_1;
1373
+ };
1374
+ Rules.prototype.component16 = function () {
1375
+ return this.q21_1;
1376
+ };
1377
+ Rules.prototype.copy = function (needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand) {
1378
+ return this.h22(needToPutHigherTrump === void 1 ? this.b21_1 : needToPutHigherTrump, distributePoints === void 1 ? this.c21_1 : distributePoints, protectBella === void 1 ? this.d21_1 : protectBella, enableFourSevensCombination === void 1 ? this.e21_1 : enableFourSevensCombination, enableTrumpSevenCombination === void 1 ? this.f21_1 : enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution === void 1 ? this.g21_1 : enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst === void 1 ? this.h21_1 : playerWhoChooseSuitGoFirst, winnerShuffleCards === void 1 ? this.i21_1 : winnerShuffleCards, playWithoutLiabilities === void 1 ? this.j21_1 : playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards === void 1 ? this.k21_1 : trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes === void 1 ? this.l21_1 : enableFineIfNoBribes, fineIfNoBribes === void 1 ? this.m21_1 : fineIfNoBribes, enableFineAfterThirdByte === void 1 ? this.n21_1 : enableFineAfterThirdByte, checkTrumpCombination === void 1 ? this.o21_1 : checkTrumpCombination, checkOnlyTrumpDebertz === void 1 ? this.p21_1 : checkOnlyTrumpDebertz, tenCardsInHand === void 1 ? this.q21_1 : tenCardsInHand);
1379
+ };
1380
+ Rules.prototype.h22 = function (needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand) {
1381
+ return new Rules(needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand);
1382
+ };
1383
+ Rules.prototype.i22 = function (needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand, $mask0, $handler) {
1384
+ if (!(($mask0 & 1) === 0))
1385
+ needToPutHigherTrump = this.b21_1;
1386
+ if (!(($mask0 & 2) === 0))
1387
+ distributePoints = this.c21_1;
1388
+ if (!(($mask0 & 4) === 0))
1389
+ protectBella = this.d21_1;
1390
+ if (!(($mask0 & 8) === 0))
1391
+ enableFourSevensCombination = this.e21_1;
1392
+ if (!(($mask0 & 16) === 0))
1393
+ enableTrumpSevenCombination = this.f21_1;
1394
+ if (!(($mask0 & 32) === 0))
1395
+ enableTrumpSevenCombinationAfterDistribution = this.g21_1;
1396
+ if (!(($mask0 & 64) === 0))
1397
+ playerWhoChooseSuitGoFirst = this.h21_1;
1398
+ if (!(($mask0 & 128) === 0))
1399
+ winnerShuffleCards = this.i21_1;
1400
+ if (!(($mask0 & 256) === 0))
1401
+ playWithoutLiabilities = this.j21_1;
1402
+ if (!(($mask0 & 512) === 0))
1403
+ trumpCardGoToPlayerWhoShuffleCards = this.k21_1;
1404
+ if (!(($mask0 & 1024) === 0))
1405
+ enableFineIfNoBribes = this.l21_1;
1406
+ if (!(($mask0 & 2048) === 0))
1407
+ fineIfNoBribes = this.m21_1;
1408
+ if (!(($mask0 & 4096) === 0))
1409
+ enableFineAfterThirdByte = this.n21_1;
1410
+ if (!(($mask0 & 8192) === 0))
1411
+ checkTrumpCombination = this.o21_1;
1412
+ if (!(($mask0 & 16384) === 0))
1413
+ checkOnlyTrumpDebertz = this.p21_1;
1414
+ if (!(($mask0 & 32768) === 0))
1415
+ tenCardsInHand = this.q21_1;
1416
+ return this.h22(needToPutHigherTrump, distributePoints, protectBella, enableFourSevensCombination, enableTrumpSevenCombination, enableTrumpSevenCombinationAfterDistribution, playerWhoChooseSuitGoFirst, winnerShuffleCards, playWithoutLiabilities, trumpCardGoToPlayerWhoShuffleCards, enableFineIfNoBribes, fineIfNoBribes, enableFineAfterThirdByte, checkTrumpCombination, checkOnlyTrumpDebertz, tenCardsInHand);
1417
+ };
1418
+ Rules.prototype.toString = function () {
1419
+ return 'Rules(needToPutHigherTrump=' + this.b21_1 + ', distributePoints=' + this.c21_1 + ', protectBella=' + this.d21_1 + ', enableFourSevensCombination=' + this.e21_1 + ', enableTrumpSevenCombination=' + this.f21_1 + ', enableTrumpSevenCombinationAfterDistribution=' + this.g21_1 + ', playerWhoChooseSuitGoFirst=' + this.h21_1 + ', winnerShuffleCards=' + this.i21_1 + ', playWithoutLiabilities=' + this.j21_1 + ', trumpCardGoToPlayerWhoShuffleCards=' + this.k21_1 + ', enableFineIfNoBribes=' + this.l21_1 + ', fineIfNoBribes=' + this.m21_1 + ', enableFineAfterThirdByte=' + this.n21_1 + ', checkTrumpCombination=' + this.o21_1 + ', checkOnlyTrumpDebertz=' + this.p21_1 + ', tenCardsInHand=' + this.q21_1 + ')';
1420
+ };
1421
+ Rules.prototype.hashCode = function () {
1422
+ var result = this.b21_1 | 0;
1423
+ result = imul(result, 31) + (this.c21_1 | 0) | 0;
1424
+ result = imul(result, 31) + (this.d21_1 | 0) | 0;
1425
+ result = imul(result, 31) + (this.e21_1 | 0) | 0;
1426
+ result = imul(result, 31) + (this.f21_1 | 0) | 0;
1427
+ result = imul(result, 31) + (this.g21_1 | 0) | 0;
1428
+ result = imul(result, 31) + (this.h21_1 | 0) | 0;
1429
+ result = imul(result, 31) + (this.i21_1 | 0) | 0;
1430
+ result = imul(result, 31) + (this.j21_1 | 0) | 0;
1431
+ result = imul(result, 31) + (this.k21_1 | 0) | 0;
1432
+ result = imul(result, 31) + (this.l21_1 | 0) | 0;
1433
+ result = imul(result, 31) + this.m21_1 | 0;
1434
+ result = imul(result, 31) + (this.n21_1 | 0) | 0;
1435
+ result = imul(result, 31) + (this.o21_1 | 0) | 0;
1436
+ result = imul(result, 31) + (this.p21_1 | 0) | 0;
1437
+ result = imul(result, 31) + (this.q21_1 | 0) | 0;
1438
+ return result;
1439
+ };
1440
+ Rules.prototype.equals = function (other) {
1441
+ if (this === other)
1442
+ return true;
1443
+ if (!(other instanceof Rules))
1444
+ return false;
1445
+ var tmp0_other_with_cast = other instanceof Rules ? other : THROW_CCE();
1446
+ if (!(this.b21_1 === tmp0_other_with_cast.b21_1))
1447
+ return false;
1448
+ if (!(this.c21_1 === tmp0_other_with_cast.c21_1))
1449
+ return false;
1450
+ if (!(this.d21_1 === tmp0_other_with_cast.d21_1))
1451
+ return false;
1452
+ if (!(this.e21_1 === tmp0_other_with_cast.e21_1))
1453
+ return false;
1454
+ if (!(this.f21_1 === tmp0_other_with_cast.f21_1))
1455
+ return false;
1456
+ if (!(this.g21_1 === tmp0_other_with_cast.g21_1))
1457
+ return false;
1458
+ if (!(this.h21_1 === tmp0_other_with_cast.h21_1))
1459
+ return false;
1460
+ if (!(this.i21_1 === tmp0_other_with_cast.i21_1))
1461
+ return false;
1462
+ if (!(this.j21_1 === tmp0_other_with_cast.j21_1))
1463
+ return false;
1464
+ if (!(this.k21_1 === tmp0_other_with_cast.k21_1))
1465
+ return false;
1466
+ if (!(this.l21_1 === tmp0_other_with_cast.l21_1))
1467
+ return false;
1468
+ if (!(this.m21_1 === tmp0_other_with_cast.m21_1))
1469
+ return false;
1470
+ if (!(this.n21_1 === tmp0_other_with_cast.n21_1))
1471
+ return false;
1472
+ if (!(this.o21_1 === tmp0_other_with_cast.o21_1))
1473
+ return false;
1474
+ if (!(this.p21_1 === tmp0_other_with_cast.p21_1))
1475
+ return false;
1476
+ if (!(this.q21_1 === tmp0_other_with_cast.q21_1))
1477
+ return false;
1478
+ return true;
1479
+ };
1480
+ Rules.$metadata$ = classMeta('Rules');
1481
+ Object.defineProperty(Rules.prototype, 'needToPutHigherTrump', {
1482
+ configurable: true,
1483
+ get: Rules.prototype.r21
1484
+ });
1485
+ Object.defineProperty(Rules.prototype, 'distributePoints', {
1486
+ configurable: true,
1487
+ get: Rules.prototype.s21
1488
+ });
1489
+ Object.defineProperty(Rules.prototype, 'protectBella', {
1490
+ configurable: true,
1491
+ get: Rules.prototype.t21
1492
+ });
1493
+ Object.defineProperty(Rules.prototype, 'enableFourSevensCombination', {
1494
+ configurable: true,
1495
+ get: Rules.prototype.u21
1496
+ });
1497
+ Object.defineProperty(Rules.prototype, 'enableTrumpSevenCombination', {
1498
+ configurable: true,
1499
+ get: Rules.prototype.v21
1500
+ });
1501
+ Object.defineProperty(Rules.prototype, 'enableTrumpSevenCombinationAfterDistribution', {
1502
+ configurable: true,
1503
+ get: Rules.prototype.w21
1504
+ });
1505
+ Object.defineProperty(Rules.prototype, 'playerWhoChooseSuitGoFirst', {
1506
+ configurable: true,
1507
+ get: Rules.prototype.x21
1508
+ });
1509
+ Object.defineProperty(Rules.prototype, 'winnerShuffleCards', {
1510
+ configurable: true,
1511
+ get: Rules.prototype.y21
1512
+ });
1513
+ Object.defineProperty(Rules.prototype, 'playWithoutLiabilities', {
1514
+ configurable: true,
1515
+ get: Rules.prototype.z21
1516
+ });
1517
+ Object.defineProperty(Rules.prototype, 'trumpCardGoToPlayerWhoShuffleCards', {
1518
+ configurable: true,
1519
+ get: Rules.prototype.a22
1520
+ });
1521
+ Object.defineProperty(Rules.prototype, 'enableFineIfNoBribes', {
1522
+ configurable: true,
1523
+ get: Rules.prototype.b22
1524
+ });
1525
+ Object.defineProperty(Rules.prototype, 'fineIfNoBribes', {
1526
+ configurable: true,
1527
+ get: Rules.prototype.c22
1528
+ });
1529
+ Object.defineProperty(Rules.prototype, 'enableFineAfterThirdByte', {
1530
+ configurable: true,
1531
+ get: Rules.prototype.d22
1532
+ });
1533
+ Object.defineProperty(Rules.prototype, 'checkTrumpCombination', {
1534
+ configurable: true,
1535
+ get: Rules.prototype.e22
1536
+ });
1537
+ Object.defineProperty(Rules.prototype, 'checkOnlyTrumpDebertz', {
1538
+ configurable: true,
1539
+ get: Rules.prototype.f22
1540
+ });
1541
+ Object.defineProperty(Rules.prototype, 'tenCardsInHand', {
1542
+ configurable: true,
1543
+ get: Rules.prototype.g22
1544
+ });
1545
+ var RulesSetType_belot_instance;
1546
+ var RulesSetType_klabor_instance;
1547
+ var RulesSetType_debertzCommon_instance;
1548
+ var RulesSetType_debertzKharkiv_instance;
1549
+ var RulesSetType_debertzMoscow_instance;
1550
+ var RulesSetType_custom_instance;
1551
+ function values_0() {
1552
+ return [RulesSetType_belot_getInstance(), RulesSetType_klabor_getInstance(), RulesSetType_debertzCommon_getInstance(), RulesSetType_debertzKharkiv_getInstance(), RulesSetType_debertzMoscow_getInstance(), RulesSetType_custom_getInstance()];
1553
+ }
1554
+ function valueOf_0(value) {
1555
+ switch (value) {
1556
+ case 'belot':
1557
+ return RulesSetType_belot_getInstance();
1558
+ case 'klabor':
1559
+ return RulesSetType_klabor_getInstance();
1560
+ case 'debertzCommon':
1561
+ return RulesSetType_debertzCommon_getInstance();
1562
+ case 'debertzKharkiv':
1563
+ return RulesSetType_debertzKharkiv_getInstance();
1564
+ case 'debertzMoscow':
1565
+ return RulesSetType_debertzMoscow_getInstance();
1566
+ case 'custom':
1567
+ return RulesSetType_custom_getInstance();
1568
+ default:
1569
+ RulesSetType_initEntries();
1570
+ THROW_ISE();
1571
+ break;
1572
+ }
1573
+ }
1574
+ var RulesSetType_entriesInitialized;
1575
+ function RulesSetType_initEntries() {
1576
+ if (RulesSetType_entriesInitialized)
1577
+ return Unit_getInstance();
1578
+ RulesSetType_entriesInitialized = true;
1579
+ RulesSetType_belot_instance = new RulesSetType('belot', 0);
1580
+ RulesSetType_klabor_instance = new RulesSetType('klabor', 1);
1581
+ RulesSetType_debertzCommon_instance = new RulesSetType('debertzCommon', 2);
1582
+ RulesSetType_debertzKharkiv_instance = new RulesSetType('debertzKharkiv', 3);
1583
+ RulesSetType_debertzMoscow_instance = new RulesSetType('debertzMoscow', 4);
1584
+ RulesSetType_custom_instance = new RulesSetType('custom', 5);
1585
+ }
1586
+ function RulesSetType(name, ordinal) {
1587
+ Enum.call(this, name, ordinal);
1588
+ }
1589
+ RulesSetType.$metadata$ = classMeta('RulesSetType', undefined, undefined, undefined, undefined, Enum.prototype);
1590
+ Object.defineProperty(RulesSetType.prototype, 'name', {
1591
+ configurable: true,
1592
+ get: RulesSetType.prototype.c5
1593
+ });
1594
+ Object.defineProperty(RulesSetType.prototype, 'ordinal', {
1595
+ configurable: true,
1596
+ get: RulesSetType.prototype.wh
1597
+ });
1598
+ function RulesSetType_belot_getInstance() {
1599
+ RulesSetType_initEntries();
1600
+ return RulesSetType_belot_instance;
1601
+ }
1602
+ function RulesSetType_klabor_getInstance() {
1603
+ RulesSetType_initEntries();
1604
+ return RulesSetType_klabor_instance;
1605
+ }
1606
+ function RulesSetType_debertzCommon_getInstance() {
1607
+ RulesSetType_initEntries();
1608
+ return RulesSetType_debertzCommon_instance;
1609
+ }
1610
+ function RulesSetType_debertzKharkiv_getInstance() {
1611
+ RulesSetType_initEntries();
1612
+ return RulesSetType_debertzKharkiv_instance;
1613
+ }
1614
+ function RulesSetType_debertzMoscow_getInstance() {
1615
+ RulesSetType_initEntries();
1616
+ return RulesSetType_debertzMoscow_instance;
1617
+ }
1618
+ function RulesSetType_custom_getInstance() {
1619
+ RulesSetType_initEntries();
1620
+ return RulesSetType_custom_instance;
1621
+ }
1622
+ function CardGrowthComparator(trump, firstCardSuit) {
1623
+ this.l22_1 = trump;
1624
+ this.m22_1 = firstCardSuit;
1625
+ }
1626
+ CardGrowthComparator.prototype.n22 = function (a, b) {
1627
+ return getGrowth(b, this.l22_1, this.m22_1) - getGrowth(a, this.l22_1, this.m22_1) | 0;
1628
+ };
1629
+ CardGrowthComparator.prototype.compare = function (a, b) {
1630
+ var tmp = a instanceof GameCard ? a : THROW_CCE();
1631
+ return this.n22(tmp, b instanceof GameCard ? b : THROW_CCE());
1632
+ };
1633
+ CardGrowthComparator.$metadata$ = classMeta('CardGrowthComparator', [Comparator]);
1634
+ function filterByCardName(_this__u8e3s4, name) {
1635
+ var tmp$ret$1;
1636
+ // Inline function 'kotlin.collections.filter' call
1637
+ var tmp0_filter = byCardNamePredicate(name.slice());
1638
+ var tmp$ret$0;
1639
+ // Inline function 'kotlin.collections.filterTo' call
1640
+ var tmp0_filterTo = ArrayList_init_$Create$();
1641
+ var tmp0_iterator = _this__u8e3s4.f();
1642
+ while (tmp0_iterator.g()) {
1643
+ var element = tmp0_iterator.h();
1644
+ if (tmp0_filter(element)) {
1645
+ tmp0_filterTo.a(element);
1646
+ }
1647
+ }
1648
+ tmp$ret$0 = tmp0_filterTo;
1649
+ tmp$ret$1 = tmp$ret$0;
1650
+ return tmp$ret$1;
1651
+ }
1652
+ function CardIndexComparator() {
1653
+ CardIndexComparator_instance = this;
1654
+ }
1655
+ CardIndexComparator.prototype.n22 = function (a, b) {
1656
+ return a.o22_1 - b.o22_1 | 0;
1657
+ };
1658
+ CardIndexComparator.prototype.compare = function (a, b) {
1659
+ var tmp = a instanceof GameCard ? a : THROW_CCE();
1660
+ return this.n22(tmp, b instanceof GameCard ? b : THROW_CCE());
1661
+ };
1662
+ CardIndexComparator.$metadata$ = objectMeta('CardIndexComparator', [Comparator]);
1663
+ var CardIndexComparator_instance;
1664
+ function CardIndexComparator_getInstance() {
1665
+ if (CardIndexComparator_instance == null)
1666
+ new CardIndexComparator();
1667
+ return CardIndexComparator_instance;
1668
+ }
1669
+ function filterBySuit(_this__u8e3s4, suit) {
1670
+ var tmp$ret$1;
1671
+ // Inline function 'kotlin.collections.filter' call
1672
+ var tmp0_filter = bySuitPredicate(suit.slice());
1673
+ var tmp$ret$0;
1674
+ // Inline function 'kotlin.collections.filterTo' call
1675
+ var tmp0_filterTo = ArrayList_init_$Create$();
1676
+ var tmp0_iterator = _this__u8e3s4.f();
1677
+ while (tmp0_iterator.g()) {
1678
+ var element = tmp0_iterator.h();
1679
+ if (tmp0_filter(element)) {
1680
+ tmp0_filterTo.a(element);
1681
+ }
1682
+ }
1683
+ tmp$ret$0 = tmp0_filterTo;
1684
+ tmp$ret$1 = tmp$ret$0;
1685
+ return tmp$ret$1;
1686
+ }
1687
+ function CardNumberComparator() {
1688
+ CardNumberComparator_instance = this;
1689
+ }
1690
+ CardNumberComparator.prototype.n22 = function (a, b) {
1691
+ return b.p22() - a.p22() | 0;
1692
+ };
1693
+ CardNumberComparator.prototype.compare = function (a, b) {
1694
+ var tmp = a instanceof GameCard ? a : THROW_CCE();
1695
+ return this.n22(tmp, b instanceof GameCard ? b : THROW_CCE());
1696
+ };
1697
+ CardNumberComparator.$metadata$ = objectMeta('CardNumberComparator', [Comparator]);
1698
+ var CardNumberComparator_instance;
1699
+ function CardNumberComparator_getInstance() {
1700
+ if (CardNumberComparator_instance == null)
1701
+ new CardNumberComparator();
1702
+ return CardNumberComparator_instance;
1703
+ }
1704
+ function getPoint(_this__u8e3s4, trump) {
1705
+ var isNotTrump = !trump.equals(_this__u8e3s4.q22());
1706
+ var tmp0_subject = _this__u8e3s4.c5();
1707
+ var tmp0 = tmp0_subject.b5_1;
1708
+ var tmp;
1709
+ switch (tmp0) {
1710
+ case 7:
1711
+ case 6:
1712
+ tmp = 0;
1713
+ break;
1714
+ case 5:
1715
+ tmp = isNotTrump ? 0 : 14;
1716
+ break;
1717
+ case 4:
1718
+ tmp = 10;
1719
+ break;
1720
+ case 3:
1721
+ tmp = isNotTrump ? 2 : 20;
1722
+ break;
1723
+ case 2:
1724
+ tmp = 3;
1725
+ break;
1726
+ case 1:
1727
+ tmp = 4;
1728
+ break;
1729
+ case 0:
1730
+ tmp = 11;
1731
+ break;
1732
+ default:
1733
+ throw IllegalStateException_init_$Create$('Invalid card name ' + _this__u8e3s4.c5());
1734
+ }
1735
+ return tmp;
1736
+ }
1737
+ function getGrowth(_this__u8e3s4, trump, firstCardSuit) {
1738
+ var minPoint = 0;
1739
+ var isTrump = trump.equals(_this__u8e3s4.q22());
1740
+ var isCurrentSuit = firstCardSuit.equals(_this__u8e3s4.q22());
1741
+ var minGrowth;
1742
+ var maxGrowth;
1743
+ var tmp0_subject = _this__u8e3s4.c5();
1744
+ var tmp0 = tmp0_subject.b5_1;
1745
+ switch (tmp0) {
1746
+ case 7:
1747
+ minGrowth = 0;
1748
+ maxGrowth = 8;
1749
+ break;
1750
+ case 6:
1751
+ minGrowth = 1;
1752
+ maxGrowth = 9;
1753
+ break;
1754
+ case 5:
1755
+ minGrowth = 2;
1756
+ maxGrowth = 14;
1757
+ break;
1758
+ case 4:
1759
+ minGrowth = 6;
1760
+ maxGrowth = 12;
1761
+ break;
1762
+ case 3:
1763
+ minGrowth = 3;
1764
+ maxGrowth = 15;
1765
+ break;
1766
+ case 2:
1767
+ minGrowth = 4;
1768
+ maxGrowth = 10;
1769
+ break;
1770
+ case 1:
1771
+ minGrowth = 5;
1772
+ maxGrowth = 11;
1773
+ break;
1774
+ case 0:
1775
+ minGrowth = 7;
1776
+ maxGrowth = 13;
1777
+ break;
1778
+ default:
1779
+ throw IllegalStateException_init_$Create$('Invalid index playerId in Card.getGrowth()');
1780
+ }
1781
+ var tmp;
1782
+ if (isTrump) {
1783
+ tmp = maxGrowth;
1784
+ } else {
1785
+ var tmp_0;
1786
+ if (isCurrentSuit) {
1787
+ tmp_0 = minGrowth;
1788
+ } else {
1789
+ tmp_0 = minPoint;
1790
+ }
1791
+ tmp = tmp_0;
1792
+ }
1793
+ return tmp;
1794
+ }
1795
+ function byCardNamePredicate(types) {
1796
+ return byCardNamePredicate$lambda(types);
1797
+ }
1798
+ function bySuitPredicate(types) {
1799
+ return bySuitPredicate$lambda(types);
1800
+ }
1801
+ function byCardNamePredicate$lambda($types) {
1802
+ return function (p1) {
1803
+ var tmp$ret$1;
1804
+ $l$block: {
1805
+ // Inline function 'kotlin.collections.any' call
1806
+ var indexedObject = $types;
1807
+ var inductionVariable = 0;
1808
+ var last = indexedObject.length;
1809
+ while (inductionVariable < last) {
1810
+ var element = indexedObject[inductionVariable];
1811
+ inductionVariable = inductionVariable + 1 | 0;
1812
+ var tmp$ret$0;
1813
+ // Inline function 'com.logic.data.models.table.cards.byCardNamePredicate.<anonymous>.<anonymous>' call
1814
+ tmp$ret$0 = p1.c5().equals(element);
1815
+ if (tmp$ret$0) {
1816
+ tmp$ret$1 = true;
1817
+ break $l$block;
1818
+ }
1819
+ }
1820
+ tmp$ret$1 = false;
1821
+ }
1822
+ return tmp$ret$1;
1823
+ };
1824
+ }
1825
+ function bySuitPredicate$lambda($types) {
1826
+ return function (p1) {
1827
+ var tmp$ret$1;
1828
+ $l$block: {
1829
+ // Inline function 'kotlin.collections.any' call
1830
+ var indexedObject = $types;
1831
+ var inductionVariable = 0;
1832
+ var last = indexedObject.length;
1833
+ while (inductionVariable < last) {
1834
+ var element = indexedObject[inductionVariable];
1835
+ inductionVariable = inductionVariable + 1 | 0;
1836
+ var tmp$ret$0;
1837
+ // Inline function 'com.logic.data.models.table.cards.bySuitPredicate.<anonymous>.<anonymous>' call
1838
+ tmp$ret$0 = p1.q22().equals(element);
1839
+ if (tmp$ret$0) {
1840
+ tmp$ret$1 = true;
1841
+ break $l$block;
1842
+ }
1843
+ }
1844
+ tmp$ret$1 = false;
1845
+ }
1846
+ return tmp$ret$1;
1847
+ };
1848
+ }
1849
+ var CardName_ACE_instance;
1850
+ var CardName_KING_instance;
1851
+ var CardName_DAME_instance;
1852
+ var CardName_JACK_instance;
1853
+ var CardName_TEN_instance;
1854
+ var CardName_NINE_instance;
1855
+ var CardName_EIGHT_instance;
1856
+ var CardName_SEVEN_instance;
1857
+ var CardName_SIX_instance;
1858
+ var CardName_FIVE_instance;
1859
+ var CardName_FOUR_instance;
1860
+ var CardName_TREE_instance;
1861
+ var CardName_TWO_instance;
1862
+ var CardName_STUB_instance;
1863
+ var CardName_entriesInitialized;
1864
+ function CardName_initEntries() {
1865
+ if (CardName_entriesInitialized)
1866
+ return Unit_getInstance();
1867
+ CardName_entriesInitialized = true;
1868
+ CardName_ACE_instance = new CardName('ACE', 0);
1869
+ CardName_KING_instance = new CardName('KING', 1);
1870
+ CardName_DAME_instance = new CardName('DAME', 2);
1871
+ CardName_JACK_instance = new CardName('JACK', 3);
1872
+ CardName_TEN_instance = new CardName('TEN', 4);
1873
+ CardName_NINE_instance = new CardName('NINE', 5);
1874
+ CardName_EIGHT_instance = new CardName('EIGHT', 6);
1875
+ CardName_SEVEN_instance = new CardName('SEVEN', 7);
1876
+ CardName_SIX_instance = new CardName('SIX', 8);
1877
+ CardName_FIVE_instance = new CardName('FIVE', 9);
1878
+ CardName_FOUR_instance = new CardName('FOUR', 10);
1879
+ CardName_TREE_instance = new CardName('TREE', 11);
1880
+ CardName_TWO_instance = new CardName('TWO', 12);
1881
+ CardName_STUB_instance = new CardName('STUB', 13);
1882
+ }
1883
+ function Companion_5() {
1884
+ Companion_instance_5 = this;
1885
+ }
1886
+ Companion_5.prototype.r22 = function (suit, cardNumber) {
1887
+ return new GameCard(getNumber(Companion_getInstance_6(), cardNumber, suit));
1888
+ };
1889
+ Companion_5.$metadata$ = objectMeta('Companion');
1890
+ var Companion_instance_5;
1891
+ function Companion_getInstance_5() {
1892
+ if (Companion_instance_5 == null)
1893
+ new Companion_5();
1894
+ return Companion_instance_5;
1895
+ }
1896
+ function getNumber($this, cardNumber, suit) {
1897
+ return imul(getIndex(suit), 13) + getCardNumber($this, cardNumber) | 0;
1898
+ }
1899
+ function getCardNumber($this, number) {
1900
+ var tmp0_subject = number;
1901
+ var tmp0 = tmp0_subject.b5_1;
1902
+ var tmp;
1903
+ switch (tmp0) {
1904
+ case 12:
1905
+ tmp = 0;
1906
+ break;
1907
+ case 11:
1908
+ tmp = 1;
1909
+ break;
1910
+ case 10:
1911
+ tmp = 2;
1912
+ break;
1913
+ case 9:
1914
+ tmp = 3;
1915
+ break;
1916
+ case 8:
1917
+ tmp = 4;
1918
+ break;
1919
+ case 7:
1920
+ tmp = 5;
1921
+ break;
1922
+ case 6:
1923
+ tmp = 6;
1924
+ break;
1925
+ case 5:
1926
+ tmp = 7;
1927
+ break;
1928
+ case 4:
1929
+ tmp = 8;
1930
+ break;
1931
+ case 3:
1932
+ tmp = 9;
1933
+ break;
1934
+ case 2:
1935
+ tmp = 10;
1936
+ break;
1937
+ case 1:
1938
+ tmp = 11;
1939
+ break;
1940
+ case 0:
1941
+ tmp = 12;
1942
+ break;
1943
+ default:
1944
+ throw IllegalStateException_init_$Create$('Invalid CardNumber ' + number);
1945
+ }
1946
+ return tmp;
1947
+ }
1948
+ function getName($this, number) {
1949
+ var tmp0_subject = number;
1950
+ var tmp;
1951
+ switch (tmp0_subject) {
1952
+ case 0:
1953
+ tmp = CardName_TWO_getInstance();
1954
+ break;
1955
+ case 1:
1956
+ tmp = CardName_TREE_getInstance();
1957
+ break;
1958
+ case 2:
1959
+ tmp = CardName_FOUR_getInstance();
1960
+ break;
1961
+ case 3:
1962
+ tmp = CardName_FIVE_getInstance();
1963
+ break;
1964
+ case 4:
1965
+ tmp = CardName_SIX_getInstance();
1966
+ break;
1967
+ case 5:
1968
+ tmp = CardName_SEVEN_getInstance();
1969
+ break;
1970
+ case 6:
1971
+ tmp = CardName_EIGHT_getInstance();
1972
+ break;
1973
+ case 7:
1974
+ tmp = CardName_NINE_getInstance();
1975
+ break;
1976
+ case 8:
1977
+ tmp = CardName_TEN_getInstance();
1978
+ break;
1979
+ case 9:
1980
+ tmp = CardName_JACK_getInstance();
1981
+ break;
1982
+ case 10:
1983
+ tmp = CardName_DAME_getInstance();
1984
+ break;
1985
+ case 11:
1986
+ tmp = CardName_KING_getInstance();
1987
+ break;
1988
+ case 12:
1989
+ tmp = CardName_ACE_getInstance();
1990
+ break;
1991
+ default:
1992
+ throw IllegalStateException_init_$Create$('Invalid index name in Card.getName() ' + number);
1993
+ }
1994
+ return tmp;
1995
+ }
1996
+ function _get_isShirt__vd98rp($this) {
1997
+ var tmp = $this.o22_1;
1998
+ Companion_getInstance_6();
1999
+ return tmp === 52;
2000
+ }
2001
+ function CardName(name, ordinal) {
2002
+ Enum.call(this, name, ordinal);
2003
+ }
2004
+ CardName.$metadata$ = classMeta('CardName', undefined, undefined, undefined, undefined, Enum.prototype);
2005
+ function Companion_6() {
2006
+ Companion_instance_6 = this;
2007
+ this.s22_1 = -1;
2008
+ this.t22_1 = 13;
2009
+ this.u22_1 = 52;
2010
+ this.v22_1 = 53;
2011
+ }
2012
+ Companion_6.$metadata$ = objectMeta('Companion');
2013
+ var Companion_instance_6;
2014
+ function Companion_getInstance_6() {
2015
+ if (Companion_instance_6 == null)
2016
+ new Companion_6();
2017
+ return Companion_instance_6;
2018
+ }
2019
+ function CardName_ACE_getInstance() {
2020
+ CardName_initEntries();
2021
+ return CardName_ACE_instance;
2022
+ }
2023
+ function CardName_KING_getInstance() {
2024
+ CardName_initEntries();
2025
+ return CardName_KING_instance;
2026
+ }
2027
+ function CardName_DAME_getInstance() {
2028
+ CardName_initEntries();
2029
+ return CardName_DAME_instance;
2030
+ }
2031
+ function CardName_JACK_getInstance() {
2032
+ CardName_initEntries();
2033
+ return CardName_JACK_instance;
2034
+ }
2035
+ function CardName_TEN_getInstance() {
2036
+ CardName_initEntries();
2037
+ return CardName_TEN_instance;
2038
+ }
2039
+ function CardName_NINE_getInstance() {
2040
+ CardName_initEntries();
2041
+ return CardName_NINE_instance;
2042
+ }
2043
+ function CardName_EIGHT_getInstance() {
2044
+ CardName_initEntries();
2045
+ return CardName_EIGHT_instance;
2046
+ }
2047
+ function CardName_SEVEN_getInstance() {
2048
+ CardName_initEntries();
2049
+ return CardName_SEVEN_instance;
2050
+ }
2051
+ function CardName_SIX_getInstance() {
2052
+ CardName_initEntries();
2053
+ return CardName_SIX_instance;
2054
+ }
2055
+ function CardName_FIVE_getInstance() {
2056
+ CardName_initEntries();
2057
+ return CardName_FIVE_instance;
2058
+ }
2059
+ function CardName_FOUR_getInstance() {
2060
+ CardName_initEntries();
2061
+ return CardName_FOUR_instance;
2062
+ }
2063
+ function CardName_TREE_getInstance() {
2064
+ CardName_initEntries();
2065
+ return CardName_TREE_instance;
2066
+ }
2067
+ function CardName_TWO_getInstance() {
2068
+ CardName_initEntries();
2069
+ return CardName_TWO_instance;
2070
+ }
2071
+ function CardName_STUB_getInstance() {
2072
+ CardName_initEntries();
2073
+ return CardName_STUB_instance;
2074
+ }
2075
+ function GameCard(index) {
2076
+ Companion_getInstance_6();
2077
+ this.o22_1 = index;
2078
+ }
2079
+ GameCard.prototype.y2 = function () {
2080
+ return this.o22_1;
2081
+ };
2082
+ GameCard.prototype.q22 = function () {
2083
+ var tmp;
2084
+ Companion_getInstance_6();
2085
+ var containsUpper = 13;
2086
+ var containsArg = this.o22_1;
2087
+ if (0 <= containsArg ? containsArg <= containsUpper : false) {
2088
+ tmp = Suit_DIAMOND_getInstance();
2089
+ } else {
2090
+ var tmp_0 = this.o22_1;
2091
+ Companion_getInstance_6();
2092
+ if (tmp_0 <= imul(13, 2)) {
2093
+ tmp = Suit_SPADE_getInstance();
2094
+ } else {
2095
+ var tmp_1 = this.o22_1;
2096
+ Companion_getInstance_6();
2097
+ if (tmp_1 <= imul(13, 3)) {
2098
+ tmp = Suit_HEART_getInstance();
2099
+ } else {
2100
+ var tmp_2 = this.o22_1;
2101
+ Companion_getInstance_6();
2102
+ if (tmp_2 <= imul(13, 4)) {
2103
+ tmp = Suit_CLUB_getInstance();
2104
+ } else {
2105
+ throw IllegalStateException_init_$Create$('Invalid suitCard in Card.getValue() ' + this.o22_1);
2106
+ }
2107
+ }
2108
+ }
2109
+ }
2110
+ return tmp;
2111
+ };
2112
+ GameCard.prototype.p22 = function () {
2113
+ var tmp;
2114
+ if (this.w22()) {
2115
+ Companion_getInstance_6();
2116
+ tmp = -1;
2117
+ } else {
2118
+ var tmp_0 = this.o22_1;
2119
+ Companion_getInstance_6();
2120
+ tmp = tmp_0 - imul(13, getIndex(this.q22())) | 0;
2121
+ }
2122
+ return tmp;
2123
+ };
2124
+ GameCard.prototype.c5 = function () {
2125
+ return this.w22() ? CardName_STUB_getInstance() : getName(Companion_getInstance_6(), this.p22());
2126
+ };
2127
+ GameCard.prototype.w22 = function () {
2128
+ var tmp = this.o22_1;
2129
+ Companion_getInstance_6();
2130
+ return tmp >= 53;
2131
+ };
2132
+ GameCard.prototype.toString = function () {
2133
+ if (_get_isShirt__vd98rp(this)) {
2134
+ return 'GameCard(SHIRT)';
2135
+ }
2136
+ if (this.w22()) {
2137
+ return 'GameCard(STUB, ' + this.o22_1 + ')';
2138
+ }
2139
+ return 'GameCard(' + this.c5() + ', suit: ' + this.q22() + ', index=' + this.o22_1 + ')';
2140
+ };
2141
+ GameCard.prototype.hashCode = function () {
2142
+ return this.o22_1;
2143
+ };
2144
+ GameCard.prototype.equals = function (other) {
2145
+ if (this === other)
2146
+ return true;
2147
+ if (!(other instanceof GameCard))
2148
+ return false;
2149
+ var tmp0_other_with_cast = other instanceof GameCard ? other : THROW_CCE();
2150
+ if (!(this.o22_1 === tmp0_other_with_cast.o22_1))
2151
+ return false;
2152
+ return true;
2153
+ };
2154
+ GameCard.$metadata$ = classMeta('GameCard');
2155
+ function GameCardWIthPlayerId(playerId, gameCard) {
2156
+ this.x22_1 = playerId;
2157
+ this.y22_1 = gameCard;
2158
+ }
2159
+ GameCardWIthPlayerId.prototype.i1z = function () {
2160
+ return this.x22_1;
2161
+ };
2162
+ GameCardWIthPlayerId.prototype.toString = function () {
2163
+ return 'GameCardWIthPlayerId(playerId=' + this.x22_1 + ', gameCard=' + this.y22_1 + ')';
2164
+ };
2165
+ GameCardWIthPlayerId.prototype.hashCode = function () {
2166
+ var result = getStringHashCode(this.x22_1);
2167
+ result = imul(result, 31) + this.y22_1.hashCode() | 0;
2168
+ return result;
2169
+ };
2170
+ GameCardWIthPlayerId.prototype.equals = function (other) {
2171
+ if (this === other)
2172
+ return true;
2173
+ if (!(other instanceof GameCardWIthPlayerId))
2174
+ return false;
2175
+ var tmp0_other_with_cast = other instanceof GameCardWIthPlayerId ? other : THROW_CCE();
2176
+ if (!(this.x22_1 === tmp0_other_with_cast.x22_1))
2177
+ return false;
2178
+ if (!this.y22_1.equals(tmp0_other_with_cast.y22_1))
2179
+ return false;
2180
+ return true;
2181
+ };
2182
+ GameCardWIthPlayerId.$metadata$ = classMeta('GameCardWIthPlayerId', [PlayerIdContract]);
2183
+ Object.defineProperty(GameCardWIthPlayerId.prototype, 'playerId', {
2184
+ configurable: true,
2185
+ get: function () {
2186
+ return this.i1z();
2187
+ }
2188
+ });
2189
+ function ProcessingCard(gameCard, payload) {
2190
+ this.z22_1 = gameCard;
2191
+ this.a23_1 = payload;
2192
+ }
2193
+ ProcessingCard.prototype.b23 = function () {
2194
+ return this.z22_1;
2195
+ };
2196
+ ProcessingCard.prototype.toString = function () {
2197
+ return 'ProcessingCard(gameCard=' + this.z22_1 + ', payload=' + this.a23_1 + ')';
2198
+ };
2199
+ ProcessingCard.prototype.hashCode = function () {
2200
+ var result = this.z22_1.hashCode();
2201
+ result = imul(result, 31) + (this.a23_1 == null ? 0 : hashCode(this.a23_1)) | 0;
2202
+ return result;
2203
+ };
2204
+ ProcessingCard.prototype.equals = function (other) {
2205
+ if (this === other)
2206
+ return true;
2207
+ if (!(other instanceof ProcessingCard))
2208
+ return false;
2209
+ var tmp0_other_with_cast = other instanceof ProcessingCard ? other : THROW_CCE();
2210
+ if (!this.z22_1.equals(tmp0_other_with_cast.z22_1))
2211
+ return false;
2212
+ if (!equals(this.a23_1, tmp0_other_with_cast.a23_1))
2213
+ return false;
2214
+ return true;
2215
+ };
2216
+ ProcessingCard.$metadata$ = classMeta('ProcessingCard');
2217
+ var Suit_DIAMOND_instance;
2218
+ var Suit_SPADE_instance;
2219
+ var Suit_HEART_instance;
2220
+ var Suit_CLUB_instance;
2221
+ function values_1() {
2222
+ return [Suit_DIAMOND_getInstance(), Suit_SPADE_getInstance(), Suit_HEART_getInstance(), Suit_CLUB_getInstance()];
2223
+ }
2224
+ var Suit_entriesInitialized;
2225
+ function Suit_initEntries() {
2226
+ if (Suit_entriesInitialized)
2227
+ return Unit_getInstance();
2228
+ Suit_entriesInitialized = true;
2229
+ Suit_DIAMOND_instance = new Suit('DIAMOND', 0);
2230
+ Suit_SPADE_instance = new Suit('SPADE', 1);
2231
+ Suit_HEART_instance = new Suit('HEART', 2);
2232
+ Suit_CLUB_instance = new Suit('CLUB', 3);
2233
+ }
2234
+ function Suit(name, ordinal) {
2235
+ Enum.call(this, name, ordinal);
2236
+ }
2237
+ Suit.$metadata$ = classMeta('Suit', undefined, undefined, undefined, undefined, Enum.prototype);
2238
+ function Suit_DIAMOND_getInstance() {
2239
+ Suit_initEntries();
2240
+ return Suit_DIAMOND_instance;
2241
+ }
2242
+ function Suit_SPADE_getInstance() {
2243
+ Suit_initEntries();
2244
+ return Suit_SPADE_instance;
2245
+ }
2246
+ function Suit_HEART_getInstance() {
2247
+ Suit_initEntries();
2248
+ return Suit_HEART_instance;
2249
+ }
2250
+ function Suit_CLUB_getInstance() {
2251
+ Suit_initEntries();
2252
+ return Suit_CLUB_instance;
2253
+ }
2254
+ function getIndex(_this__u8e3s4) {
2255
+ var tmp0_subject = _this__u8e3s4;
2256
+ var tmp0 = tmp0_subject.b5_1;
2257
+ var tmp;
2258
+ switch (tmp0) {
2259
+ case 0:
2260
+ tmp = 0;
2261
+ break;
2262
+ case 1:
2263
+ tmp = 1;
2264
+ break;
2265
+ case 2:
2266
+ tmp = 2;
2267
+ break;
2268
+ case 3:
2269
+ tmp = 3;
2270
+ break;
2271
+ default:
2272
+ noWhenBranchMatchedException();
2273
+ break;
2274
+ }
2275
+ return tmp;
2276
+ }
2277
+ function _no_name_provided__qut3iv($logger) {
2278
+ this.d23_1 = $logger;
2279
+ AbstractCoroutineContextElement.call(this, Key_getInstance());
2280
+ }
2281
+ _no_name_provided__qut3iv.prototype.lp = function (context, exception) {
2282
+ return this.d23_1.e23('AsyncErrorHandler', 'AsyncProvider error: ' + exception, exception);
2283
+ };
2284
+ _no_name_provided__qut3iv.$metadata$ = classMeta(undefined, [CoroutineExceptionHandler], undefined, undefined, undefined, AbstractCoroutineContextElement.prototype);
2285
+ function AsyncProviderImpl(logger) {
2286
+ var tmp = this;
2287
+ tmp.f23_1 = Job$default(null, 1, null);
2288
+ var tmp_0 = this;
2289
+ var tmp$ret$0;
2290
+ // Inline function 'kotlinx.coroutines.CoroutineExceptionHandler' call
2291
+ tmp$ret$0 = new _no_name_provided__qut3iv(logger);
2292
+ tmp_0.g23_1 = tmp$ret$0;
2293
+ this.h23_1 = CoroutineScope(Dispatchers_getInstance().st().v4(this.f23_1));
2294
+ this.i23_1 = CoroutineScope(Dispatchers_getInstance().ot_1.v4(this.f23_1));
2295
+ }
2296
+ AsyncProviderImpl.prototype.j23 = function () {
2297
+ return this.g23_1;
2298
+ };
2299
+ AsyncProviderImpl.prototype.k23 = function (context, block) {
2300
+ return launch$default(this.h23_1, context, null, block, 2, null);
2301
+ };
2302
+ AsyncProviderImpl.prototype.m23 = function (context, block) {
2303
+ return launch$default(this.i23_1, context, null, block, 2, null);
2304
+ };
2305
+ AsyncProviderImpl.prototype.ym = function () {
2306
+ if (!this.f23_1.ep()) {
2307
+ this.f23_1.vl(null, 1, null);
2308
+ }
2309
+ };
2310
+ AsyncProviderImpl.$metadata$ = classMeta('AsyncProviderImpl', [AsyncProvider]);
2311
+ function AsyncProvider() {
2312
+ }
2313
+ AsyncProvider.$metadata$ = interfaceMeta('AsyncProvider');
2314
+ function get_coreModule() {
2315
+ init_properties_DI_kt_pa5hx();
2316
+ return coreModule;
2317
+ }
2318
+ var coreModule;
2319
+ function coreModule$lambda($this$$receiver) {
2320
+ init_properties_DI_kt_pa5hx();
2321
+ return Unit_getInstance();
2322
+ }
2323
+ var properties_initialized_DI_kt_3whi87;
2324
+ function init_properties_DI_kt_pa5hx() {
2325
+ if (properties_initialized_DI_kt_3whi87) {
2326
+ } else {
2327
+ properties_initialized_DI_kt_3whi87 = true;
2328
+ coreModule = Module_init_$Create$('Core Module', false, null, coreModule$lambda, 6, null);
2329
+ }
2330
+ }
2331
+ function compose(functions) {
2332
+ return compose$lambda(functions);
2333
+ }
2334
+ function compose$lambda($functions) {
2335
+ return function (x) {
2336
+ var tmp$ret$1;
2337
+ // Inline function 'kotlin.collections.foldRight' call
2338
+ var accumulator = x;
2339
+ if (!$functions.k()) {
2340
+ var iterator = $functions.m($functions.i());
2341
+ while (iterator.r()) {
2342
+ var tmp$ret$0;
2343
+ // Inline function 'com.logic.domain.engine.compose.<anonymous>.<anonymous>' call
2344
+ var tmp0__anonymous__q1qw7t = iterator.s();
2345
+ var tmp1__anonymous__uwfjfc = accumulator;
2346
+ tmp$ret$0 = tmp0__anonymous__q1qw7t(tmp1__anonymous__uwfjfc);
2347
+ accumulator = tmp$ret$0;
2348
+ }
2349
+ }
2350
+ tmp$ret$1 = accumulator;
2351
+ return tmp$ret$1;
2352
+ };
2353
+ }
2354
+ function createStore(reducer, preloadedState, enhancer) {
2355
+ if (!(enhancer == null)) {
2356
+ return enhancer(createStore$lambda)(reducer, preloadedState, null);
2357
+ }
2358
+ var currentState = MutableStateFlow(preloadedState);
2359
+ var currentReducer = {_v: reducer};
2360
+ createStore$dispatch(currentState, currentReducer, INIT_getInstance());
2361
+ return new createStore$2(currentState, currentReducer);
2362
+ }
2363
+ function createStore$default(reducer, preloadedState, enhancer, $mask0, $handler) {
2364
+ if (!(($mask0 & 4) === 0))
2365
+ enhancer = null;
2366
+ return createStore(reducer, preloadedState, enhancer);
2367
+ }
2368
+ function createStore$dispatch(currentState, currentReducer, action) {
2369
+ currentState.e11(currentReducer._v.o23(currentState.z1(), action));
2370
+ }
2371
+ function createStore$replaceReducer(currentReducer, currentState, nextReducer) {
2372
+ currentReducer._v = nextReducer;
2373
+ createStore$dispatch(currentState, currentReducer, REPLACE_getInstance());
2374
+ }
2375
+ function createStore$lambda(r, initialState, _anonymous_parameter_2__qggqfi) {
2376
+ return createStore$default(r, initialState, null, 4, null);
2377
+ }
2378
+ function createStore$dispatch$ref($currentState, $currentReducer) {
2379
+ var l = function (p0) {
2380
+ createStore$dispatch($currentState, $currentReducer, p0);
2381
+ return Unit_getInstance();
2382
+ };
2383
+ l.callableName = 'dispatch';
2384
+ return l;
2385
+ }
2386
+ function createStore$replaceReducer$ref($currentReducer, $currentState) {
2387
+ var l = function (p0) {
2388
+ createStore$replaceReducer($currentReducer, $currentState, p0);
2389
+ return Unit_getInstance();
2390
+ };
2391
+ l.callableName = 'replaceReducer';
2392
+ return l;
2393
+ }
2394
+ function createStore$2($currentState, $currentReducer) {
2395
+ this.r23_1 = $currentState;
2396
+ var tmp = this;
2397
+ tmp.p23_1 = createStore$dispatch$ref($currentState, $currentReducer);
2398
+ var tmp_0 = this;
2399
+ tmp_0.q23_1 = createStore$replaceReducer$ref($currentReducer, $currentState);
2400
+ }
2401
+ createStore$2.prototype.s23 = function (_set____db54di) {
2402
+ this.p23_1 = _set____db54di;
2403
+ };
2404
+ createStore$2.prototype.t23 = function () {
2405
+ return this.p23_1;
2406
+ };
2407
+ createStore$2.prototype.u23 = function () {
2408
+ return this.r23_1;
2409
+ };
2410
+ createStore$2.prototype.v23 = function () {
2411
+ return this.q23_1;
2412
+ };
2413
+ createStore$2.prototype.hl = function () {
2414
+ return this.r23_1.z1();
2415
+ };
2416
+ createStore$2.$metadata$ = classMeta(undefined, [Store]);
2417
+ Object.defineProperty(createStore$2.prototype, 'dispatch', {
2418
+ configurable: true,
2419
+ get: function () {
2420
+ return this.t23();
2421
+ },
2422
+ set: function (value) {
2423
+ this.s23(value);
2424
+ }
2425
+ });
2426
+ Object.defineProperty(createStore$2.prototype, 'observe', {
2427
+ configurable: true,
2428
+ get: function () {
2429
+ return this.u23();
2430
+ }
2431
+ });
2432
+ Object.defineProperty(createStore$2.prototype, 'replaceReducer', {
2433
+ configurable: true,
2434
+ get: function () {
2435
+ return this.v23();
2436
+ }
2437
+ });
2438
+ Object.defineProperty(createStore$2.prototype, 'state', {
2439
+ configurable: true,
2440
+ get: function () {
2441
+ return this.hl();
2442
+ }
2443
+ });
2444
+ function Action() {
2445
+ }
2446
+ Action.$metadata$ = interfaceMeta('Action');
2447
+ function parseActionName(_this__u8e3s4) {
2448
+ var tmp;
2449
+ try {
2450
+ var tmp_0 = toString_0(_this__u8e3s4);
2451
+ tmp = first(split$default(tmp_0, ['('], false, 0, 6, null));
2452
+ } catch ($p) {
2453
+ var tmp_1;
2454
+ if ($p instanceof Exception) {
2455
+ tmp_1 = '';
2456
+ } else {
2457
+ throw $p;
2458
+ }
2459
+ tmp = tmp_1;
2460
+ }
2461
+ return tmp;
2462
+ }
2463
+ function Middleware() {
2464
+ }
2465
+ Middleware.$metadata$ = interfaceMeta('Middleware');
2466
+ function middleware(dispatch) {
2467
+ return new middleware$1(dispatch);
2468
+ }
2469
+ function middleware$1($dispatch) {
2470
+ this.z23_1 = $dispatch;
2471
+ }
2472
+ middleware$1.prototype.y23 = function (store, next, action) {
2473
+ this.z23_1(store, next, action);
2474
+ };
2475
+ middleware$1.$metadata$ = classMeta(undefined, [Middleware]);
2476
+ function Reducer() {
2477
+ }
2478
+ Reducer.$metadata$ = interfaceMeta('Reducer');
2479
+ function combineReducers(reducers) {
2480
+ return new combineReducers$1(reducers);
2481
+ }
2482
+ function combineReducers$1($reducers) {
2483
+ this.a24_1 = $reducers;
2484
+ }
2485
+ combineReducers$1.prototype.b24 = function (state, action) {
2486
+ var tmp$ret$4;
2487
+ // Inline function 'kotlin.collections.fold' call
2488
+ var tmp$ret$2;
2489
+ // Inline function 'kotlin.collections.filter' call
2490
+ var tmp$ret$1;
2491
+ // Inline function 'kotlin.collections.filterTo' call
2492
+ var tmp0_filterTo = ArrayList_init_$Create$();
2493
+ var indexedObject = this.a24_1;
2494
+ var inductionVariable = 0;
2495
+ var last = indexedObject.length;
2496
+ while (inductionVariable < last) {
2497
+ var element = indexedObject[inductionVariable];
2498
+ inductionVariable = inductionVariable + 1 | 0;
2499
+ var tmp$ret$0;
2500
+ // Inline function 'com.logic.domain.engine.definitions.<no name provided>.reduce.<anonymous>' call
2501
+ tmp$ret$0 = element.x23(action);
2502
+ if (tmp$ret$0) {
2503
+ tmp0_filterTo.a(element);
2504
+ }
2505
+ }
2506
+ tmp$ret$1 = tmp0_filterTo;
2507
+ tmp$ret$2 = tmp$ret$1;
2508
+ var tmp0_fold = tmp$ret$2;
2509
+ var accumulator = state;
2510
+ var tmp0_iterator = tmp0_fold.f();
2511
+ while (tmp0_iterator.g()) {
2512
+ var element_0 = tmp0_iterator.h();
2513
+ var tmp$ret$3;
2514
+ // Inline function 'com.logic.domain.engine.definitions.<no name provided>.reduce.<anonymous>' call
2515
+ var tmp1__anonymous__uwfjfc = accumulator;
2516
+ tmp$ret$3 = element_0.o23(tmp1__anonymous__uwfjfc, action);
2517
+ accumulator = tmp$ret$3;
2518
+ }
2519
+ tmp$ret$4 = accumulator;
2520
+ return tmp$ret$4;
2521
+ };
2522
+ combineReducers$1.prototype.o23 = function (state, action) {
2523
+ return this.b24((state == null ? true : isObject(state)) ? state : THROW_CCE(), action);
2524
+ };
2525
+ combineReducers$1.$metadata$ = classMeta(undefined, [Reducer]);
2526
+ function Store() {
2527
+ }
2528
+ Store.$metadata$ = interfaceMeta('Store');
2529
+ function INIT() {
2530
+ INIT_instance = this;
2531
+ StoreLifecycleAction.call(this);
2532
+ }
2533
+ INIT.$metadata$ = objectMeta('INIT', undefined, undefined, undefined, undefined, StoreLifecycleAction.prototype);
2534
+ Object.defineProperty(INIT.prototype, 'actionTag', {
2535
+ configurable: true,
2536
+ get: function () {
2537
+ return this.w23();
2538
+ }
2539
+ });
2540
+ var INIT_instance;
2541
+ function INIT_getInstance() {
2542
+ if (INIT_instance == null)
2543
+ new INIT();
2544
+ return INIT_instance;
2545
+ }
2546
+ function REPLACE() {
2547
+ REPLACE_instance = this;
2548
+ StoreLifecycleAction.call(this);
2549
+ }
2550
+ REPLACE.$metadata$ = objectMeta('REPLACE', undefined, undefined, undefined, undefined, StoreLifecycleAction.prototype);
2551
+ Object.defineProperty(REPLACE.prototype, 'actionTag', {
2552
+ configurable: true,
2553
+ get: function () {
2554
+ return this.w23();
2555
+ }
2556
+ });
2557
+ var REPLACE_instance;
2558
+ function REPLACE_getInstance() {
2559
+ if (REPLACE_instance == null)
2560
+ new REPLACE();
2561
+ return REPLACE_instance;
2562
+ }
2563
+ function StoreLifecycleAction() {
2564
+ }
2565
+ StoreLifecycleAction.$metadata$ = classMeta('StoreLifecycleAction', [Action]);
2566
+ Object.defineProperty(StoreLifecycleAction.prototype, 'actionTag', {
2567
+ configurable: true,
2568
+ get: function () {
2569
+ return this.w23();
2570
+ }
2571
+ });
2572
+ function BufferedAction() {
2573
+ }
2574
+ BufferedAction.$metadata$ = interfaceMeta('BufferedAction', [Action]);
2575
+ function ReleaseBufferTriggerAction() {
2576
+ }
2577
+ ReleaseBufferTriggerAction.$metadata$ = interfaceMeta('ReleaseBufferTriggerAction', [Action]);
2578
+ function ExpectantAction() {
2579
+ }
2580
+ ExpectantAction.$metadata$ = interfaceMeta('ExpectantAction', [Action]);
2581
+ function applyCatcher(logger) {
2582
+ return applyCatcher$lambda(logger);
2583
+ }
2584
+ function applyCatcher$lambda$lambda$lambda($origDispatch, $logger) {
2585
+ return function (action) {
2586
+ var tmp;
2587
+ try {
2588
+ tmp = $origDispatch(action);
2589
+ } catch ($p) {
2590
+ var tmp_0;
2591
+ if ($p instanceof Exception) {
2592
+ $logger.e23('StoreEnhancer', 'StoreEnhancer error: ' + $p, $p);
2593
+ tmp_0 = Unit_getInstance();
2594
+ } else {
2595
+ throw $p;
2596
+ }
2597
+ tmp = tmp_0;
2598
+ }
2599
+ return Unit_getInstance();
2600
+ };
2601
+ }
2602
+ function applyCatcher$lambda$lambda($storeCreator, $logger) {
2603
+ return function (reducer, initialState, en) {
2604
+ var store = $storeCreator(reducer, initialState, en);
2605
+ var origDispatch = store.dispatch;
2606
+ store.dispatch = applyCatcher$lambda$lambda$lambda(origDispatch, $logger);
2607
+ return store;
2608
+ };
2609
+ }
2610
+ function applyCatcher$lambda($logger) {
2611
+ return function (storeCreator) {
2612
+ return applyCatcher$lambda$lambda(storeCreator, $logger);
2613
+ };
2614
+ }
2615
+ function applyMiddleware(middlewares) {
2616
+ return applyMiddleware$lambda(middlewares);
2617
+ }
2618
+ function applyMiddleware$lambda$lambda$lambda$lambda($tmp0__anonymous__1nv1x1, $store, $tmp1__anonymous__6ijp4k) {
2619
+ return function (action) {
2620
+ $tmp0__anonymous__1nv1x1.y23($store, $tmp1__anonymous__6ijp4k, action);
2621
+ return Unit_getInstance();
2622
+ };
2623
+ }
2624
+ function applyMiddleware$lambda$lambda$lambda($middlewares, $origDispatch, $store) {
2625
+ return function (action) {
2626
+ var tmp$ret$2;
2627
+ // Inline function 'kotlin.collections.filter' call
2628
+ var tmp$ret$1;
2629
+ // Inline function 'kotlin.collections.filterTo' call
2630
+ var tmp0_filterTo = ArrayList_init_$Create$();
2631
+ var indexedObject = $middlewares;
2632
+ var inductionVariable = 0;
2633
+ var last = indexedObject.length;
2634
+ while (inductionVariable < last) {
2635
+ var element = indexedObject[inductionVariable];
2636
+ inductionVariable = inductionVariable + 1 | 0;
2637
+ var tmp$ret$0;
2638
+ // Inline function 'com.logic.redux.enhancers.applyMiddleware.<anonymous>.<anonymous>.<anonymous>.<anonymous>' call
2639
+ tmp$ret$0 = element.x23(action);
2640
+ if (tmp$ret$0) {
2641
+ tmp0_filterTo.a(element);
2642
+ }
2643
+ }
2644
+ tmp$ret$1 = tmp0_filterTo;
2645
+ tmp$ret$2 = tmp$ret$1;
2646
+ var filteredMiddlewares = tmp$ret$2;
2647
+ var tmp$ret$4;
2648
+ // Inline function 'kotlin.collections.foldRight' call
2649
+ var accumulator = $origDispatch;
2650
+ if (!filteredMiddlewares.k()) {
2651
+ var iterator = filteredMiddlewares.m(filteredMiddlewares.i());
2652
+ while (iterator.r()) {
2653
+ var tmp$ret$3;
2654
+ // Inline function 'com.logic.redux.enhancers.applyMiddleware.<anonymous>.<anonymous>.<anonymous>.<anonymous>' call
2655
+ var tmp0__anonymous__q1qw7t = iterator.s();
2656
+ var tmp1__anonymous__uwfjfc = accumulator;
2657
+ tmp$ret$3 = applyMiddleware$lambda$lambda$lambda$lambda(tmp0__anonymous__q1qw7t, $store, tmp1__anonymous__uwfjfc);
2658
+ accumulator = tmp$ret$3;
2659
+ }
2660
+ }
2661
+ tmp$ret$4 = accumulator;
2662
+ var firstDispatcher = tmp$ret$4;
2663
+ firstDispatcher(action);
2664
+ return Unit_getInstance();
2665
+ };
2666
+ }
2667
+ function applyMiddleware$lambda$lambda($storeCreator, $middlewares) {
2668
+ return function (reducer, initialState, en) {
2669
+ var store = $storeCreator(reducer, initialState, en);
2670
+ var origDispatch = store.dispatch;
2671
+ store.dispatch = applyMiddleware$lambda$lambda$lambda($middlewares, origDispatch, store);
2672
+ return store;
2673
+ };
2674
+ }
2675
+ function applyMiddleware$lambda($middlewares) {
2676
+ return function (storeCreator) {
2677
+ return applyMiddleware$lambda$lambda(storeCreator, $middlewares);
2678
+ };
2679
+ }
2680
+ function findItemIndex(_this__u8e3s4, predicate) {
2681
+ var tmp$ret$3;
2682
+ // Inline function 'kotlin.collections.mapIndexedNotNull' call
2683
+ var tmp$ret$2;
2684
+ // Inline function 'kotlin.collections.mapIndexedNotNullTo' call
2685
+ var tmp1_mapIndexedNotNullTo = ArrayList_init_$Create$();
2686
+ // Inline function 'kotlin.collections.forEachIndexed' call
2687
+ var index = 0;
2688
+ var tmp0_iterator = _this__u8e3s4.f();
2689
+ while (tmp0_iterator.g()) {
2690
+ var item = tmp0_iterator.h();
2691
+ // Inline function 'kotlin.collections.mapIndexedNotNullTo.<anonymous>' call
2692
+ var tmp1 = index;
2693
+ index = tmp1 + 1 | 0;
2694
+ var tmp0__anonymous__q1qw7t = checkIndexOverflow(tmp1);
2695
+ var tmp$ret$0;
2696
+ // Inline function 'com.logic.utils.findItemIndex.<anonymous>' call
2697
+ var tmp;
2698
+ if (predicate(item)) {
2699
+ tmp = tmp0__anonymous__q1qw7t;
2700
+ } else {
2701
+ tmp = null;
2702
+ }
2703
+ tmp$ret$0 = tmp;
2704
+ var tmp0_safe_receiver = tmp$ret$0;
2705
+ if (tmp0_safe_receiver == null)
2706
+ null;
2707
+ else {
2708
+ var tmp$ret$1;
2709
+ // Inline function 'kotlin.let' call
2710
+ // Inline function 'kotlin.contracts.contract' call
2711
+ tmp1_mapIndexedNotNullTo.a(tmp0_safe_receiver);
2712
+ tmp$ret$1 = Unit_getInstance();
2713
+ }
2714
+ }
2715
+ tmp$ret$2 = tmp1_mapIndexedNotNullTo;
2716
+ tmp$ret$3 = tmp$ret$2;
2717
+ return single(tmp$ret$3);
2718
+ }
2719
+ function nextTo(_this__u8e3s4, index) {
2720
+ var nextItemIndex = index + 1 | 0;
2721
+ return nextItemIndex > get_lastIndex(_this__u8e3s4) ? _this__u8e3s4.j(0) : _this__u8e3s4.j(nextItemIndex);
2722
+ }
2723
+ function updateItem(_this__u8e3s4, newValue, predicate) {
2724
+ var tmp$ret$1;
2725
+ // Inline function 'com.logic.utils.copy' call
2726
+ var tmp$ret$0;
2727
+ // Inline function 'kotlin.apply' call
2728
+ var tmp0_apply = toMutableList(_this__u8e3s4);
2729
+ // Inline function 'kotlin.contracts.contract' call
2730
+ // Inline function 'com.logic.utils.updateItem.<anonymous>' call
2731
+ var index = findItemIndex(tmp0_apply, predicate);
2732
+ tmp0_apply.j3(index, newValue);
2733
+ return tmp0_apply;
2734
+ tmp$ret$0 = tmp0_apply;
2735
+ tmp$ret$1 = tmp$ret$0;
2736
+ return tmp$ret$1;
2737
+ }
2738
+ function copy(_this__u8e3s4, mutatorBlock) {
2739
+ var tmp$ret$0;
2740
+ // Inline function 'kotlin.apply' call
2741
+ var tmp0_apply = toMutableList(_this__u8e3s4);
2742
+ // Inline function 'kotlin.contracts.contract' call
2743
+ mutatorBlock(tmp0_apply);
2744
+ tmp$ret$0 = tmp0_apply;
2745
+ return tmp$ret$0;
2746
+ }
2747
+ function updated(_this__u8e3s4, newValue, predicate) {
2748
+ var index = findItemIndex(_this__u8e3s4, predicate);
2749
+ _this__u8e3s4.j3(index, newValue);
2750
+ return _this__u8e3s4;
2751
+ }
2752
+ function sortWithItem(_this__u8e3s4, item) {
2753
+ return sortWithPosition(_this__u8e3s4, _this__u8e3s4.q2(item));
2754
+ }
2755
+ function nextTo_0(_this__u8e3s4, predicate) {
2756
+ var nextItemIndex = findItemIndex(_this__u8e3s4, predicate) + 1 | 0;
2757
+ return nextItemIndex > get_lastIndex(_this__u8e3s4) ? _this__u8e3s4.j(0) : _this__u8e3s4.j(nextItemIndex);
2758
+ }
2759
+ function sortWithPosition(_this__u8e3s4, position) {
2760
+ var tmp$ret$0;
2761
+ // Inline function 'kotlin.collections.mutableListOf' call
2762
+ tmp$ret$0 = ArrayList_init_$Create$();
2763
+ var newList = tmp$ret$0;
2764
+ var currentItem = _this__u8e3s4.j(position);
2765
+ var inductionVariable = 0;
2766
+ var last = _this__u8e3s4.i() - 1 | 0;
2767
+ if (inductionVariable <= last)
2768
+ do {
2769
+ var i = inductionVariable;
2770
+ inductionVariable = inductionVariable + 1 | 0;
2771
+ newList.a(currentItem);
2772
+ currentItem = nextTo(_this__u8e3s4, _this__u8e3s4.q2(currentItem));
2773
+ }
2774
+ while (inductionVariable <= last);
2775
+ return newList;
2776
+ }
2777
+ function GameLogger() {
2778
+ }
2779
+ GameLogger.$metadata$ = interfaceMeta('GameLogger', [LoggerOutput]);
2780
+ function LoggerOutput() {
2781
+ }
2782
+ LoggerOutput.$metadata$ = interfaceMeta('LoggerOutput');
2783
+ var Category_LIFECYCLE_instance;
2784
+ var Category_NONE_instance;
2785
+ var Category_entriesInitialized;
2786
+ function Category_initEntries() {
2787
+ if (Category_entriesInitialized)
2788
+ return Unit_getInstance();
2789
+ Category_entriesInitialized = true;
2790
+ Category_LIFECYCLE_instance = new Category('LIFECYCLE', 0, true);
2791
+ Category_NONE_instance = new Category('NONE', 1, true);
2792
+ }
2793
+ function generateTag($this, tag) {
2794
+ return (!($this.k24_1 == null) ? !(tag == null) : false) ? '' + $this.k24_1 + ':' + tag : tag;
2795
+ }
2796
+ function Category(name, ordinal, isEnabled) {
2797
+ Enum.call(this, name, ordinal);
2798
+ this.n24_1 = isEnabled;
2799
+ }
2800
+ Category.$metadata$ = classMeta('Category', undefined, undefined, undefined, undefined, Enum.prototype);
2801
+ function Logger$loggerSource$1() {
2802
+ this.o24_1 = new PlatformLogger();
2803
+ }
2804
+ Logger$loggerSource$1.prototype.p24 = function (tag, msg) {
2805
+ this.o24_1.p24(tag, msg);
2806
+ };
2807
+ Logger$loggerSource$1.prototype.q24 = function (tag, msg, exception) {
2808
+ this.o24_1.q24(tag, msg, exception);
2809
+ };
2810
+ Logger$loggerSource$1.prototype.r24 = function (tag, msg) {
2811
+ this.o24_1.r24(tag, msg);
2812
+ };
2813
+ Logger$loggerSource$1.$metadata$ = classMeta(undefined, [LoggerSource]);
2814
+ function Category_NONE_getInstance() {
2815
+ Category_initEntries();
2816
+ return Category_NONE_instance;
2817
+ }
2818
+ function Logger() {
2819
+ Logger_instance = this;
2820
+ var tmp = this;
2821
+ tmp.i24_1 = new Logger$loggerSource$1();
2822
+ this.j24_1 = true;
2823
+ this.k24_1 = null;
2824
+ }
2825
+ Logger.prototype.d24 = function (tag, message) {
2826
+ this.s24(tag, message, Category_NONE_getInstance());
2827
+ };
2828
+ Logger.prototype.t24 = function (tag, message, category) {
2829
+ if (this.j24_1 ? category.n24_1 : false) {
2830
+ this.i24_1.r24(generateTag(this, tag), message);
2831
+ }
2832
+ };
2833
+ Logger.prototype.u24 = function (tag, message, category, $mask0, $handler) {
2834
+ if (!(($mask0 & 1) === 0))
2835
+ tag = null;
2836
+ if (!(($mask0 & 4) === 0))
2837
+ category = Category_NONE_getInstance();
2838
+ return this.t24(tag, message, category);
2839
+ };
2840
+ Logger.prototype.s24 = function (tag, message, category) {
2841
+ if (this.j24_1 ? category.n24_1 : false) {
2842
+ this.i24_1.p24(generateTag(this, tag), message);
2843
+ }
2844
+ };
2845
+ Logger.prototype.v24 = function (tag, message, exception, category) {
2846
+ if (this.j24_1 ? category.n24_1 : false) {
2847
+ var tmp0_safe_receiver = exception;
2848
+ if (tmp0_safe_receiver == null)
2849
+ null;
2850
+ else {
2851
+ printStackTrace(tmp0_safe_receiver);
2852
+ }
2853
+ this.i24_1.q24(generateTag(this, tag), generateMsg(message, exception), exception);
2854
+ }
2855
+ };
2856
+ Logger.prototype.w24 = function (tag, message, exception, category, $mask0, $handler) {
2857
+ if (!(($mask0 & 1) === 0))
2858
+ tag = null;
2859
+ if (!(($mask0 & 2) === 0))
2860
+ message = null;
2861
+ if (!(($mask0 & 4) === 0))
2862
+ exception = null;
2863
+ if (!(($mask0 & 8) === 0))
2864
+ category = Category_NONE_getInstance();
2865
+ return this.v24(tag, message, exception, category);
2866
+ };
2867
+ Logger.$metadata$ = objectMeta('Logger');
2868
+ var Logger_instance;
2869
+ function Logger_getInstance() {
2870
+ if (Logger_instance == null)
2871
+ new Logger();
2872
+ return Logger_instance;
2873
+ }
2874
+ function LoggerSource() {
2875
+ }
2876
+ LoggerSource.$metadata$ = interfaceMeta('LoggerSource');
2877
+ function generateMsg(msg, exception) {
2878
+ var logMessage = '';
2879
+ var tmp$ret$0;
2880
+ // Inline function 'kotlin.text.isNullOrBlank' call
2881
+ // Inline function 'kotlin.contracts.contract' call
2882
+ tmp$ret$0 = msg == null ? true : isBlank(msg);
2883
+ if (!tmp$ret$0) {
2884
+ logMessage = logMessage + msg;
2885
+ }
2886
+ if (!(exception == null)) {
2887
+ var tmp = logMessage;
2888
+ var tmp$ret$1;
2889
+ // Inline function 'kotlin.text.orEmpty' call
2890
+ var tmp0_orEmpty = exception.message;
2891
+ var tmp0_elvis_lhs = tmp0_orEmpty;
2892
+ tmp$ret$1 = tmp0_elvis_lhs == null ? '' : tmp0_elvis_lhs;
2893
+ logMessage = tmp + (' Exception: ' + tmp$ret$1 + ', stackTrace: ' + stackTraceToString(exception));
2894
+ }
2895
+ if (isBlank(logMessage)) {
2896
+ logMessage = 'Unknown error';
2897
+ }
2898
+ return logMessage;
2899
+ }
2900
+ function getLogTag(tag) {
2901
+ var tmp0_elvis_lhs = tag;
2902
+ return tmp0_elvis_lhs == null ? '' : tmp0_elvis_lhs;
2903
+ }
2904
+ function CombinedGameLogger(logOutputs) {
2905
+ this.x24_1 = logOutputs;
2906
+ }
2907
+ CombinedGameLogger.prototype.d24 = function (tag, message) {
2908
+ // Inline function 'kotlin.collections.forEach' call
2909
+ var tmp0_forEach = this.x24_1;
2910
+ var tmp0_iterator = tmp0_forEach.f();
2911
+ while (tmp0_iterator.g()) {
2912
+ var element = tmp0_iterator.h();
2913
+ // Inline function 'com.logic.utils.logger.game.CombinedGameLogger.d.<anonymous>' call
2914
+ element.d24(tag, message);
2915
+ }
2916
+ };
2917
+ CombinedGameLogger.prototype.e23 = function (tag, message, exception) {
2918
+ // Inline function 'kotlin.collections.forEach' call
2919
+ var tmp0_forEach = this.x24_1;
2920
+ var tmp0_iterator = tmp0_forEach.f();
2921
+ while (tmp0_iterator.g()) {
2922
+ var element = tmp0_iterator.h();
2923
+ // Inline function 'com.logic.utils.logger.game.CombinedGameLogger.e.<anonymous>' call
2924
+ element.e23(tag, message, exception);
2925
+ }
2926
+ };
2927
+ CombinedGameLogger.prototype.g24 = function (tag, message) {
2928
+ // Inline function 'kotlin.collections.forEach' call
2929
+ var tmp0_forEach = this.x24_1;
2930
+ var tmp0_iterator = tmp0_forEach.f();
2931
+ while (tmp0_iterator.g()) {
2932
+ var element = tmp0_iterator.h();
2933
+ // Inline function 'com.logic.utils.logger.game.CombinedGameLogger.w.<anonymous>' call
2934
+ element.g24(tag, message);
2935
+ }
2936
+ };
2937
+ CombinedGameLogger.$metadata$ = classMeta('CombinedGameLogger', [GameLogger]);
2938
+ function LoggerOutputWithPayload() {
2939
+ }
2940
+ LoggerOutputWithPayload.$metadata$ = interfaceMeta('LoggerOutputWithPayload');
2941
+ function LoggerPayload() {
2942
+ }
2943
+ LoggerPayload.$metadata$ = interfaceMeta('LoggerPayload');
2944
+ function PlatformGameLogger() {
2945
+ PlatformGameLogger_instance = this;
2946
+ }
2947
+ PlatformGameLogger.prototype.d24 = function (tag, message) {
2948
+ Logger_getInstance().d24(tag, message);
2949
+ };
2950
+ PlatformGameLogger.prototype.e23 = function (tag, message, exception) {
2951
+ var tmp = Logger_getInstance();
2952
+ tmp.w24(tag, message, exception, null, 8, null);
2953
+ };
2954
+ PlatformGameLogger.prototype.g24 = function (tag, message) {
2955
+ var tmp = Logger_getInstance();
2956
+ tmp.u24(tag, message, null, 4, null);
2957
+ };
2958
+ PlatformGameLogger.$metadata$ = objectMeta('PlatformGameLogger', [GameLogger]);
2959
+ var PlatformGameLogger_instance;
2960
+ function PlatformGameLogger_getInstance() {
2961
+ if (PlatformGameLogger_instance == null)
2962
+ new PlatformGameLogger();
2963
+ return PlatformGameLogger_instance;
2964
+ }
2965
+ function PlatformLogger() {
2966
+ }
2967
+ PlatformLogger.prototype.p24 = function (tag, msg) {
2968
+ console.log(getLogTag(tag) + ': ' + msg);
2969
+ };
2970
+ PlatformLogger.prototype.q24 = function (tag, msg, exception) {
2971
+ if (!(exception == null)) {
2972
+ console.error(getLogTag(tag) + ': ' + msg + ', exception: ' + exception);
2973
+ } else {
2974
+ console.error(getLogTag(tag) + ': ' + msg);
2975
+ }
2976
+ };
2977
+ PlatformLogger.prototype.r24 = function (tag, msg) {
2978
+ console.warn(getLogTag(tag) + ': ' + msg);
2979
+ };
2980
+ PlatformLogger.$metadata$ = classMeta('PlatformLogger');
2981
+ //region block: post-declaration
2982
+ $serializer.prototype.h1n = typeParametersSerializers;
2983
+ $serializer_0.prototype.h1n = typeParametersSerializers;
2984
+ $serializer_1.prototype.h1n = typeParametersSerializers;
2985
+ _no_name_provided__qut3iv.prototype.o4 = get;
2986
+ _no_name_provided__qut3iv.prototype.u4 = fold;
2987
+ _no_name_provided__qut3iv.prototype.t4 = minusKey;
2988
+ _no_name_provided__qut3iv.prototype.v4 = plus;
2989
+ AsyncProviderImpl.prototype.l23 = launchStore$default;
2990
+ AsyncProviderImpl.prototype.n23 = launchWorker$default;
2991
+ middleware$1.prototype.x23 = canHandle;
2992
+ combineReducers$1.prototype.x23 = canHandle_0;
2993
+ StoreLifecycleAction.prototype.w23 = get_actionTag;
2994
+ INIT.prototype.w23 = get_actionTag;
2995
+ REPLACE.prototype.w23 = get_actionTag;
2996
+ CombinedGameLogger.prototype.e24 = d$default;
2997
+ CombinedGameLogger.prototype.f24 = e$default;
2998
+ CombinedGameLogger.prototype.h24 = w$default;
2999
+ PlatformGameLogger.prototype.e24 = d$default;
3000
+ PlatformGameLogger.prototype.f24 = e$default;
3001
+ PlatformGameLogger.prototype.h24 = w$default;
3002
+ //endregion
3003
+ //region block: exports
3004
+ function $jsExportAll$(_) {
3005
+ var $com = _.com || (_.com = {});
3006
+ var $com$logic = $com.logic || ($com.logic = {});
3007
+ Object.defineProperty($com$logic, 'GameEngineConfig', {
3008
+ configurable: true,
3009
+ get: GameEngineConfig_getInstance
3010
+ });
3011
+ var $com = _.com || (_.com = {});
3012
+ var $com$logic = $com.logic || ($com.logic = {});
3013
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3014
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3015
+ $com$logic$data$models.TerminationGameReason = TerminationGameReason;
3016
+ $com$logic$data$models.TerminationGameReason.TerminationGameReason_init_$Create$ = TerminationGameReason_init_$Create$;
3017
+ Object.defineProperty($com$logic$data$models.TerminationGameReason, 'Companion', {
3018
+ configurable: true,
3019
+ get: Companion_getInstance
3020
+ });
3021
+ var $com = _.com || (_.com = {});
3022
+ var $com$logic = $com.logic || ($com.logic = {});
3023
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3024
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3025
+ var $com$logic$data$models$player = $com$logic$data$models.player || ($com$logic$data$models.player = {});
3026
+ $com$logic$data$models$player.GameUserInfo = GameUserInfo;
3027
+ var $com = _.com || (_.com = {});
3028
+ var $com$logic = $com.logic || ($com.logic = {});
3029
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3030
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3031
+ var $com$logic$data$models$player = $com$logic$data$models.player || ($com$logic$data$models.player = {});
3032
+ $com$logic$data$models$player.getPlayer = getPlayer;
3033
+ $com$logic$data$models$player.getPlayerIndex = getPlayerIndex;
3034
+ var $com = _.com || (_.com = {});
3035
+ var $com$logic = $com.logic || ($com.logic = {});
3036
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3037
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3038
+ var $com$logic$data$models$player = $com$logic$data$models.player || ($com$logic$data$models.player = {});
3039
+ $com$logic$data$models$player.PlayerConnectionState = PlayerConnectionState;
3040
+ $com$logic$data$models$player.PlayerConnectionState.values = values;
3041
+ $com$logic$data$models$player.PlayerConnectionState.valueOf = valueOf;
3042
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'LIVE', {
3043
+ configurable: true,
3044
+ get: PlayerConnectionState_LIVE_getInstance
3045
+ });
3046
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'TIMEOUT', {
3047
+ configurable: true,
3048
+ get: PlayerConnectionState_TIMEOUT_getInstance
3049
+ });
3050
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'LOST_CONNECTION', {
3051
+ configurable: true,
3052
+ get: PlayerConnectionState_LOST_CONNECTION_getInstance
3053
+ });
3054
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'LEFT', {
3055
+ configurable: true,
3056
+ get: PlayerConnectionState_LEFT_getInstance
3057
+ });
3058
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'DISCONNECTING', {
3059
+ configurable: true,
3060
+ get: PlayerConnectionState_DISCONNECTING_getInstance
3061
+ });
3062
+ Object.defineProperty($com$logic$data$models$player.PlayerConnectionState, 'DELETED', {
3063
+ configurable: true,
3064
+ get: PlayerConnectionState_DELETED_getInstance
3065
+ });
3066
+ var $com = _.com || (_.com = {});
3067
+ var $com$logic = $com.logic || ($com.logic = {});
3068
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3069
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3070
+ var $com$logic$data$models$rules = $com$logic$data$models.rules || ($com$logic$data$models.rules = {});
3071
+ $com$logic$data$models$rules.Rules = Rules;
3072
+ Object.defineProperty($com$logic$data$models$rules.Rules, 'Companion', {
3073
+ configurable: true,
3074
+ get: Companion_getInstance_4
3075
+ });
3076
+ var $com = _.com || (_.com = {});
3077
+ var $com$logic = $com.logic || ($com.logic = {});
3078
+ var $com$logic$data = $com$logic.data || ($com$logic.data = {});
3079
+ var $com$logic$data$models = $com$logic$data.models || ($com$logic$data.models = {});
3080
+ var $com$logic$data$models$rules = $com$logic$data$models.rules || ($com$logic$data$models.rules = {});
3081
+ $com$logic$data$models$rules.RulesSetType = RulesSetType;
3082
+ $com$logic$data$models$rules.RulesSetType.values = values_0;
3083
+ $com$logic$data$models$rules.RulesSetType.valueOf = valueOf_0;
3084
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'belot', {
3085
+ configurable: true,
3086
+ get: RulesSetType_belot_getInstance
3087
+ });
3088
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'klabor', {
3089
+ configurable: true,
3090
+ get: RulesSetType_klabor_getInstance
3091
+ });
3092
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'debertzCommon', {
3093
+ configurable: true,
3094
+ get: RulesSetType_debertzCommon_getInstance
3095
+ });
3096
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'debertzKharkiv', {
3097
+ configurable: true,
3098
+ get: RulesSetType_debertzKharkiv_getInstance
3099
+ });
3100
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'debertzMoscow', {
3101
+ configurable: true,
3102
+ get: RulesSetType_debertzMoscow_getInstance
3103
+ });
3104
+ Object.defineProperty($com$logic$data$models$rules.RulesSetType, 'custom', {
3105
+ configurable: true,
3106
+ get: RulesSetType_custom_getInstance
3107
+ });
3108
+ var $com = _.com || (_.com = {});
3109
+ var $com$logic = $com.logic || ($com.logic = {});
3110
+ var $com$logic$domain = $com$logic.domain || ($com$logic.domain = {});
3111
+ var $com$logic$domain$engine = $com$logic$domain.engine || ($com$logic$domain.engine = {});
3112
+ var $com$logic$domain$engine$definitions = $com$logic$domain$engine.definitions || ($com$logic$domain$engine.definitions = {});
3113
+ var $com = _.com || (_.com = {});
3114
+ var $com$logic = $com.logic || ($com.logic = {});
3115
+ var $com$logic$domain = $com$logic.domain || ($com$logic.domain = {});
3116
+ var $com$logic$domain$engine = $com$logic$domain.engine || ($com$logic$domain.engine = {});
3117
+ var $com$logic$domain$engine$definitions = $com$logic$domain$engine.definitions || ($com$logic$domain$engine.definitions = {});
3118
+ var $com = _.com || (_.com = {});
3119
+ var $com$logic = $com.logic || ($com.logic = {});
3120
+ var $com$logic$redux = $com$logic.redux || ($com$logic.redux = {});
3121
+ var $com$logic$redux$actions = $com$logic$redux.actions || ($com$logic$redux.actions = {});
3122
+ var $com = _.com || (_.com = {});
3123
+ var $com$logic = $com.logic || ($com.logic = {});
3124
+ var $com$logic$utils = $com$logic.utils || ($com$logic.utils = {});
3125
+ var $com$logic$utils$logger = $com$logic$utils.logger || ($com$logic$utils.logger = {});
3126
+ var $com$logic$utils$logger$game = $com$logic$utils$logger.game || ($com$logic$utils$logger.game = {});
3127
+ }
3128
+ $jsExportAll$(_);
3129
+ _.$jsExportAll$ = $jsExportAll$;
3130
+ _.$_$ = _.$_$ || {};
3131
+ _.$_$.a = MechanicException;
3132
+ _.$_$.b = PlayerIdContract;
3133
+ _.$_$.c = Player;
3134
+ _.$_$.d = Team;
3135
+ _.$_$.e = get_byIdPlayerPredicate;
3136
+ _.$_$.f = filterByPlayerId;
3137
+ _.$_$.g = filterPlayerTurn;
3138
+ _.$_$.h = getPlayer;
3139
+ _.$_$.i = nextToPlayerId;
3140
+ _.$_$.j = CardGrowthComparator;
3141
+ _.$_$.k = GameCardWIthPlayerId;
3142
+ _.$_$.l = GameCard;
3143
+ _.$_$.m = ProcessingCard;
3144
+ _.$_$.n = values_1;
3145
+ _.$_$.o = filterByCardName;
3146
+ _.$_$.p = filterBySuit;
3147
+ _.$_$.q = getGrowth;
3148
+ _.$_$.r = getPoint;
3149
+ _.$_$.s = GameErrorReason;
3150
+ _.$_$.t = PlayerExitReason;
3151
+ _.$_$.u = PlayerLostConnectionReason;
3152
+ _.$_$.v = PlayerTimeoutReason;
3153
+ _.$_$.w = AsyncProviderImpl;
3154
+ _.$_$.x = AsyncProvider;
3155
+ _.$_$.y = get_coreModule;
3156
+ _.$_$.z = get_actionTag;
3157
+ _.$_$.a1 = Action;
3158
+ _.$_$.b1 = Middleware;
3159
+ _.$_$.c1 = Reducer;
3160
+ _.$_$.d1 = combineReducers;
3161
+ _.$_$.e1 = middleware;
3162
+ _.$_$.f1 = parseActionName;
3163
+ _.$_$.g1 = compose;
3164
+ _.$_$.h1 = createStore;
3165
+ _.$_$.i1 = ignoreBuffer;
3166
+ _.$_$.j1 = BufferedAction;
3167
+ _.$_$.k1 = ignoreExpectant;
3168
+ _.$_$.l1 = ExpectantAction;
3169
+ _.$_$.m1 = ReleaseBufferTriggerAction;
3170
+ _.$_$.n1 = applyCatcher;
3171
+ _.$_$.o1 = applyMiddleware;
3172
+ _.$_$.p1 = CombinedGameLogger;
3173
+ _.$_$.q1 = LoggerOutputWithPayload;
3174
+ _.$_$.r1 = LoggerPayload;
3175
+ _.$_$.s1 = GameLogger;
3176
+ _.$_$.t1 = LoggerOutput;
3177
+ _.$_$.u1 = generateMsg;
3178
+ _.$_$.v1 = nextTo;
3179
+ _.$_$.w1 = sortWithItem;
3180
+ _.$_$.x1 = updateItem;
3181
+ _.$_$.y1 = updated;
3182
+ _.$_$.z1 = PlayerConnectionState_DELETED_getInstance;
3183
+ _.$_$.a2 = PlayerConnectionState_LEFT_getInstance;
3184
+ _.$_$.b2 = PlayerConnectionState_LIVE_getInstance;
3185
+ _.$_$.c2 = PlayerConnectionState_LOST_CONNECTION_getInstance;
3186
+ _.$_$.d2 = PlayerConnectionState_TIMEOUT_getInstance;
3187
+ _.$_$.e2 = CardName_ACE_getInstance;
3188
+ _.$_$.f2 = CardName_DAME_getInstance;
3189
+ _.$_$.g2 = CardName_EIGHT_getInstance;
3190
+ _.$_$.h2 = CardName_JACK_getInstance;
3191
+ _.$_$.i2 = CardName_KING_getInstance;
3192
+ _.$_$.j2 = CardName_NINE_getInstance;
3193
+ _.$_$.k2 = CardName_SEVEN_getInstance;
3194
+ _.$_$.l2 = CardName_TEN_getInstance;
3195
+ _.$_$.m2 = e$default_0;
3196
+ _.$_$.n2 = d$default;
3197
+ _.$_$.o2 = e$default;
3198
+ _.$_$.p2 = w$default;
3199
+ _.$_$.q2 = Companion_getInstance_3;
3200
+ _.$_$.r2 = CardIndexComparator_getInstance;
3201
+ _.$_$.s2 = CardNumberComparator_getInstance;
3202
+ _.$_$.t2 = Companion_getInstance_5;
3203
+ _.$_$.u2 = GameErrorReason_getInstance;
3204
+ _.$_$.v2 = GameFinishedReason_getInstance;
3205
+ _.$_$.w2 = ProcessingReason_getInstance;
3206
+ _.$_$.x2 = RestartGameReason_getInstance;
3207
+ _.$_$.y2 = WaitingForConnectionReason_getInstance;
3208
+ _.$_$.z2 = PlatformGameLogger_getInstance;
3209
+ _.$_$.a3 = Logger_getInstance;
3210
+ //endregion
3211
+ return _;
3212
+ }));
3213
+
3214
+ //# sourceMappingURL=Logic_Debertz-core.js.map