XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet

XFESpaceNinjaServer

A simple server for a small space ninja game

公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/XFESpaceNinjaServer

fix: handle high spoofed mastery rank plus noDailyStandingLimits (#1201)

In case the spoofed mastery rank is so high that 999,999 is *less* than the assumed maximum value for daily affiliation bins, we'll just use that so that the bar is always (at least) 100% full. Reviewed-on: https://onlyg.it/OpenWF/SpaceNinjaServer/pulls/1201

b7f05e85
Sainan <sainan@calamity.inc>
提交于

代码差异

1 个文件 +2 -1
Modified src/controllers/api/inventoryController.ts +2 -1
@@ -246,8 +246,9 @@ export const getInventoryResponse = async (
246 246 }
247 247
248 248 if (config.noDailyStandingLimits) {
249 const spoofedDailyAffiliation = Math.max(999_999, 16000 + inventoryResponse.PlayerLevel * 500);
249 250 for (const key of allDailyAffiliationKeys) {
250 inventoryResponse[key] = 999_999;
251 inventoryResponse[key] = spoofedDailyAffiliation;
251 252 }
252 253 }
253 254