返回提交历史
Modified
src/services/inventoryService.ts
+1
-2
XFEstudio/XFESpaceNinjaServer
fix: treat ExtraRemaining from U8 like an absolute value (#3770)
Closes #3769 Reviewed-on: https://onlyg.it/OpenWF/SpaceNinjaServer/pulls/3770 Co-authored-by: Sainan <63328889+Sainan@users.noreply.github.com> Co-committed-by: Sainan <63328889+Sainan@users.noreply.github.com>
84fea816
代码差异
1 个文件
+1
-2
@@ -2234,7 +2234,7 @@ export const applyClientEquipmentUpdates = (
2234
2234
}
2235
2235
2236
2236
if (ExtraRemaining) {
2237
if (!buildLabel || version_compare(buildLabel, gameToBuildVersion["8.0.0"]) >= 0) {
2237
if (!buildLabel || version_compare(buildLabel, gameToBuildVersion["9.1.2"]) >= 0) {
2238
2238
if (ExtraRemaining > 0) {
2239
2239
throw new Error(
2240
2240
`unexpected value for ExtraRemaining (${ExtraRemaining}); expected a delta from this client`
@@ -2243,7 +2243,6 @@ export const applyClientEquipmentUpdates = (
2243
2243
item.ExtraRemaining ??= 4;
2244
2244
item.ExtraRemaining += ExtraRemaining;
2245
2245
} else {
2246
// U7 still provided an absolute value; unclear when this changed.
2247
2246
if (ExtraRemaining < 0) {
2248
2247
throw new Error(
2249
2248
`unexpected value for ExtraRemaining (${ExtraRemaining}); expected an absolute value from this client`