raspberry_games_server_game_logic 1.8.369 → 1.8.371
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.
- package/Kotlin-DateTime-library-kotlinx-datetime.js +1 -1
- package/Logic_Debertz-core.js +1 -1
- package/Logic_Debertz-engine.js +87 -81
- package/Logic_Debertz-engine.js.map +1 -1
- package/kotlin-kotlin-stdlib.js +10 -10
- package/kotlin-kotlin-stdlib.js.map +1 -1
- package/kotlinx-coroutines-core.js +1 -1
- package/package.json +1 -1
|
@@ -380,7 +380,7 @@
|
|
|
380
380
|
function addFormatStructureForTime(structure) {
|
|
381
381
|
this.t5k(structure);
|
|
382
382
|
}
|
|
383
|
-
initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder,
|
|
383
|
+
initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder, WithDate, WithTime]);
|
|
384
384
|
initMetadataForClass(Builder_0, 'Builder', VOID, VOID, [AbstractDateTimeFormatBuilder, AbstractWithDateTimeBuilder]);
|
|
385
385
|
initMetadataForClass(LocalDateTimeFormat, 'LocalDateTimeFormat', VOID, AbstractDateTimeFormat);
|
|
386
386
|
function set_fractionOfSecond(value) {
|
package/Logic_Debertz-core.js
CHANGED
|
@@ -379,7 +379,7 @@
|
|
|
379
379
|
initMetadataForClass(AppEnvironmentValue, 'AppEnvironmentValue', VOID, Enum);
|
|
380
380
|
//endregion
|
|
381
381
|
function GameEngineConfig() {
|
|
382
|
-
this.version = '1.8.
|
|
382
|
+
this.version = '1.8.371';
|
|
383
383
|
}
|
|
384
384
|
protoOf(GameEngineConfig).y3v = function () {
|
|
385
385
|
return this.version;
|
package/Logic_Debertz-engine.js
CHANGED
|
@@ -42577,6 +42577,9 @@
|
|
|
42577
42577
|
var kLoss = Math.max(tmp0, b_0);
|
|
42578
42578
|
var raw = item.h70_1 + kBase * (kWin * diffPos + kLoss * diffNeg);
|
|
42579
42579
|
var newRating = clampAndRound($this, raw, minUserRating, maxUserRating);
|
|
42580
|
+
if (item.j70_1 && newRating < item.h70_1) {
|
|
42581
|
+
newRating = item.h70_1;
|
|
42582
|
+
}
|
|
42580
42583
|
tmp$ret$3 = new PlayerRatingOutput(item.g70_1, item.h70_1, newRating, item.j70_1);
|
|
42581
42584
|
}
|
|
42582
42585
|
destination.j(tmp$ret$3);
|
|
@@ -42708,7 +42711,7 @@
|
|
|
42708
42711
|
}
|
|
42709
42712
|
}
|
|
42710
42713
|
function clampAndRound($this, value, minUserRating, maxUserRating) {
|
|
42711
|
-
var upper =
|
|
42714
|
+
var upper = maxUserRating;
|
|
42712
42715
|
var clamped = coerceIn(value, minUserRating, upper);
|
|
42713
42716
|
// Inline function 'kotlin.math.pow' call
|
|
42714
42717
|
var factor = Math.pow(10.0, 2);
|
|
@@ -49997,6 +50000,54 @@
|
|
|
49997
50000
|
// Inline function 'com.logic.redux.store.definitions.middlewareForActionType' call
|
|
49998
50001
|
return new roundLifecycleMiddleware$$inlined$middlewareForActionType$1(scenePositionProvider, logger);
|
|
49999
50002
|
}
|
|
50003
|
+
function validateRatingChange(logger, playerAchievements) {
|
|
50004
|
+
var tmp;
|
|
50005
|
+
if (playerAchievements == null) {
|
|
50006
|
+
tmp = null;
|
|
50007
|
+
} else {
|
|
50008
|
+
// Inline function 'kotlin.collections.filter' call
|
|
50009
|
+
// Inline function 'kotlin.collections.filterTo' call
|
|
50010
|
+
var destination = ArrayList_init_$Create$_0();
|
|
50011
|
+
var _iterator__ex2g4s = playerAchievements.l();
|
|
50012
|
+
while (_iterator__ex2g4s.m()) {
|
|
50013
|
+
var element = _iterator__ex2g4s.n();
|
|
50014
|
+
// Inline function 'kotlin.math.absoluteValue' call
|
|
50015
|
+
var this_0 = element.oldRating - element.newRating;
|
|
50016
|
+
if (Math.abs(this_0) >= 80) {
|
|
50017
|
+
destination.j(element);
|
|
50018
|
+
}
|
|
50019
|
+
}
|
|
50020
|
+
tmp = destination;
|
|
50021
|
+
}
|
|
50022
|
+
var tmp1_elvis_lhs = tmp;
|
|
50023
|
+
var suspiciousRatingChange = tmp1_elvis_lhs == null ? emptyList() : tmp1_elvis_lhs;
|
|
50024
|
+
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
50025
|
+
if (!suspiciousRatingChange.r()) {
|
|
50026
|
+
logger.w('roundLifecycleMiddleware', 'Suspicious rating change: ' + toString(suspiciousRatingChange));
|
|
50027
|
+
}
|
|
50028
|
+
var tmp_0;
|
|
50029
|
+
if (playerAchievements == null) {
|
|
50030
|
+
tmp_0 = null;
|
|
50031
|
+
} else {
|
|
50032
|
+
// Inline function 'kotlin.collections.filter' call
|
|
50033
|
+
// Inline function 'kotlin.collections.filterTo' call
|
|
50034
|
+
var destination_0 = ArrayList_init_$Create$_0();
|
|
50035
|
+
var _iterator__ex2g4s_0 = playerAchievements.l();
|
|
50036
|
+
while (_iterator__ex2g4s_0.m()) {
|
|
50037
|
+
var element_0 = _iterator__ex2g4s_0.n();
|
|
50038
|
+
if (element_0.oldRating < 2000 && element_0.newRating > 2000) {
|
|
50039
|
+
destination_0.j(element_0);
|
|
50040
|
+
}
|
|
50041
|
+
}
|
|
50042
|
+
tmp_0 = destination_0;
|
|
50043
|
+
}
|
|
50044
|
+
var tmp3_elvis_lhs = tmp_0;
|
|
50045
|
+
var ratingChangeAboveLimit = tmp3_elvis_lhs == null ? emptyList() : tmp3_elvis_lhs;
|
|
50046
|
+
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
50047
|
+
if (!ratingChangeAboveLimit.r()) {
|
|
50048
|
+
logger.w('roundLifecycleMiddleware', 'Rating change above limit: ' + toString(suspiciousRatingChange));
|
|
50049
|
+
}
|
|
50050
|
+
}
|
|
50000
50051
|
function roundLifecycleMiddleware$$inlined$middlewareForActionType$1($scenePositionProvider, $logger) {
|
|
50001
50052
|
this.v91_1 = $scenePositionProvider;
|
|
50002
50053
|
this.w91_1 = $logger;
|
|
@@ -50116,105 +50167,60 @@
|
|
|
50116
50167
|
tmp_3 = destination_2;
|
|
50117
50168
|
}
|
|
50118
50169
|
var playerAchievements = tmp_3;
|
|
50119
|
-
|
|
50120
|
-
|
|
50121
|
-
|
|
50122
|
-
|
|
50123
|
-
|
|
50124
|
-
|
|
50125
|
-
var destination_3 = ArrayList_init_$Create$_0();
|
|
50126
|
-
var _iterator__ex2g4s_3 = playerAchievements.l();
|
|
50127
|
-
while (_iterator__ex2g4s_3.m()) {
|
|
50128
|
-
var element_0 = _iterator__ex2g4s_3.n();
|
|
50129
|
-
// Inline function 'kotlin.math.absoluteValue' call
|
|
50130
|
-
var this_2 = element_0.oldRating - element_0.newRating;
|
|
50131
|
-
if (Math.abs(this_2) >= 60) {
|
|
50132
|
-
destination_3.j(element_0);
|
|
50133
|
-
}
|
|
50134
|
-
}
|
|
50135
|
-
tmp_4 = destination_3;
|
|
50136
|
-
}
|
|
50137
|
-
var tmp14_elvis_lhs = tmp_4;
|
|
50138
|
-
var suspiciousRatingChange = tmp14_elvis_lhs == null ? emptyList() : tmp14_elvis_lhs;
|
|
50139
|
-
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
50140
|
-
if (!suspiciousRatingChange.r()) {
|
|
50141
|
-
this.w91_1.w('roundLifecycleMiddleware', 'Suspicious rating change: ' + toString(suspiciousRatingChange));
|
|
50142
|
-
}
|
|
50170
|
+
validateRatingChange(this.w91_1, playerAchievements);
|
|
50171
|
+
var tmp_4 = store.dispatch;
|
|
50172
|
+
var tmp15_id = table_0.id;
|
|
50173
|
+
var tmp16_gameId = table_0.gameId;
|
|
50174
|
+
var tmp17_roundNumber = table_0.gameInfo.round.roundNumber;
|
|
50175
|
+
var tmp18_earnedBiggestPointPlayerId = sceneData.b79_1;
|
|
50143
50176
|
var tmp_5;
|
|
50144
|
-
if (playerAchievements == null) {
|
|
50145
|
-
tmp_5 = null;
|
|
50146
|
-
} else {
|
|
50147
|
-
// Inline function 'kotlin.collections.filter' call
|
|
50148
|
-
// Inline function 'kotlin.collections.filterTo' call
|
|
50149
|
-
var destination_4 = ArrayList_init_$Create$_0();
|
|
50150
|
-
var _iterator__ex2g4s_4 = playerAchievements.l();
|
|
50151
|
-
while (_iterator__ex2g4s_4.m()) {
|
|
50152
|
-
var element_1 = _iterator__ex2g4s_4.n();
|
|
50153
|
-
if (element_1.oldRating < 2000 && element_1.newRating > 2000) {
|
|
50154
|
-
destination_4.j(element_1);
|
|
50155
|
-
}
|
|
50156
|
-
}
|
|
50157
|
-
tmp_5 = destination_4;
|
|
50158
|
-
}
|
|
50159
|
-
var tmp16_elvis_lhs = tmp_5;
|
|
50160
|
-
var ratingChangeAboveLimit = tmp16_elvis_lhs == null ? emptyList() : tmp16_elvis_lhs;
|
|
50161
|
-
// Inline function 'kotlin.collections.isNotEmpty' call
|
|
50162
|
-
if (!ratingChangeAboveLimit.r()) {
|
|
50163
|
-
this.w91_1.w('roundLifecycleMiddleware', 'Rating change above limit: ' + toString(suspiciousRatingChange));
|
|
50164
|
-
}
|
|
50165
|
-
var tmp_6 = store.dispatch;
|
|
50166
|
-
var tmp19_id = table_0.id;
|
|
50167
|
-
var tmp20_gameId = table_0.gameId;
|
|
50168
|
-
var tmp21_roundNumber = table_0.gameInfo.round.roundNumber;
|
|
50169
|
-
var tmp22_earnedBiggestPointPlayerId = sceneData.b79_1;
|
|
50170
|
-
var tmp_7;
|
|
50171
50177
|
if (gameWinners == null) {
|
|
50172
|
-
|
|
50178
|
+
tmp_5 = null;
|
|
50173
50179
|
} else {
|
|
50174
50180
|
// Inline function 'kotlin.collections.toTypedArray' call
|
|
50175
|
-
|
|
50181
|
+
tmp_5 = copyToArray(gameWinners);
|
|
50176
50182
|
}
|
|
50177
|
-
var
|
|
50178
|
-
var
|
|
50183
|
+
var tmp19_gameWinners = tmp_5;
|
|
50184
|
+
var tmp_6;
|
|
50179
50185
|
if (isGameFinished) {
|
|
50180
50186
|
// Inline function 'kotlin.collections.map' call
|
|
50181
|
-
var
|
|
50187
|
+
var this_2 = table_0.players;
|
|
50182
50188
|
// Inline function 'kotlin.collections.mapTo' call
|
|
50183
|
-
var
|
|
50184
|
-
var
|
|
50185
|
-
while (
|
|
50186
|
-
var item_2 =
|
|
50187
|
-
var tmp$ret$
|
|
50188
|
-
|
|
50189
|
+
var destination_3 = ArrayList_init_$Create$(collectionSizeOrDefault(this_2, 10));
|
|
50190
|
+
var _iterator__ex2g4s_3 = this_2.l();
|
|
50191
|
+
while (_iterator__ex2g4s_3.m()) {
|
|
50192
|
+
var item_2 = _iterator__ex2g4s_3.n();
|
|
50193
|
+
var tmp$ret$23 = mapToGameAnalytics(item_2, table_0.gameDuration);
|
|
50194
|
+
destination_3.j(tmp$ret$23);
|
|
50189
50195
|
}
|
|
50190
50196
|
// Inline function 'kotlin.collections.toTypedArray' call
|
|
50191
|
-
|
|
50197
|
+
tmp_6 = copyToArray(destination_3);
|
|
50192
50198
|
} else {
|
|
50193
|
-
|
|
50199
|
+
tmp_6 = null;
|
|
50194
50200
|
}
|
|
50195
|
-
var
|
|
50201
|
+
var tmp20_playersGameAnalytics = tmp_6;
|
|
50196
50202
|
// Inline function 'kotlin.collections.map' call
|
|
50197
|
-
var
|
|
50203
|
+
var this_3 = table_0.players;
|
|
50198
50204
|
// Inline function 'kotlin.collections.mapTo' call
|
|
50199
|
-
var
|
|
50200
|
-
var
|
|
50201
|
-
while (
|
|
50202
|
-
var item_3 =
|
|
50203
|
-
var tmp$ret$
|
|
50204
|
-
|
|
50205
|
+
var destination_4 = ArrayList_init_$Create$(collectionSizeOrDefault(this_3, 10));
|
|
50206
|
+
var _iterator__ex2g4s_4 = this_3.l();
|
|
50207
|
+
while (_iterator__ex2g4s_4.m()) {
|
|
50208
|
+
var item_3 = _iterator__ex2g4s_4.n();
|
|
50209
|
+
var tmp$ret$27 = mapToRoundAnalytics(item_3, table_0.gameDuration);
|
|
50210
|
+
destination_4.j(tmp$ret$27);
|
|
50205
50211
|
}
|
|
50206
50212
|
// Inline function 'kotlin.collections.toTypedArray' call
|
|
50207
|
-
var
|
|
50208
|
-
var
|
|
50209
|
-
var
|
|
50213
|
+
var tmp21_playersRoundAnalytics = copyToArray(destination_4);
|
|
50214
|
+
var tmp22_gameHistory = table_0.gameHistory;
|
|
50215
|
+
var tmp_7;
|
|
50210
50216
|
if (playerAchievements == null) {
|
|
50211
|
-
|
|
50217
|
+
tmp_7 = null;
|
|
50212
50218
|
} else {
|
|
50213
50219
|
// Inline function 'kotlin.collections.toTypedArray' call
|
|
50214
|
-
|
|
50220
|
+
tmp_7 = copyToArray(playerAchievements);
|
|
50215
50221
|
}
|
|
50216
|
-
var
|
|
50217
|
-
|
|
50222
|
+
var tmp23_achievements = tmp_7;
|
|
50223
|
+
tmp_4(new RoundEndedAction(tmp15_id, tmp16_gameId, tmp17_roundNumber, tmp18_earnedBiggestPointPlayerId, gameLosers, tmp19_gameWinners, tmp20_playersGameAnalytics, tmp21_playersRoundAnalytics, tmp23_achievements, tmp22_gameHistory));
|
|
50218
50224
|
}
|
|
50219
50225
|
}
|
|
50220
50226
|
}
|
|
@@ -54745,7 +54751,7 @@
|
|
|
54745
54751
|
var tmp3_bribes = emptyList();
|
|
54746
54752
|
var tmp4_gameInfo = roundFinishedGameInfoReducer(this, table);
|
|
54747
54753
|
var tmp5_gameHistory = this.a9a_1.v99(table.gameHistory);
|
|
54748
|
-
return table.copy(VOID, VOID, VOID, VOID, destination, VOID, tmp0_sceneInfo, tmp2_cardsOnTable, tmp3_bribes,
|
|
54754
|
+
return table.copy(VOID, VOID, VOID, VOID, destination, VOID, tmp0_sceneInfo, tmp2_cardsOnTable, tmp3_bribes, VOID, VOID, tmp4_gameInfo, tmp5_gameHistory);
|
|
54749
54755
|
};
|
|
54750
54756
|
protoOf(TableLifecycleReducerImpl).p99 = function (table) {
|
|
54751
54757
|
// Inline function 'kotlin.collections.map' call
|