From d4415f8edd459b070f0546a07809c8f2a36c8c0a Mon Sep 17 00:00:00 2001 From: BanLanGen <2318115955@qq.com> Date: Wed, 27 Aug 2025 02:05:34 +0800 Subject: [PATCH] FIX NEW VERSION --- package-lock.json | 8 ++-- package.json | 2 +- .../dynamic/worldStateController.ts | 2 +- src/routes/api.ts | 2 - src/routes/cache.ts | 2 + src/routes/dynamic.ts | 2 +- src/services/worldStateService.ts | 41 ++++++++++++++++++- src/types/worldStateTypes.ts | 2 +- .../worldState/worldState.json | 9 ++-- 9 files changed, 56 insertions(+), 14 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3b2f138b..1fe0a7e4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -23,7 +23,7 @@ "ncp": "^2.0.0", "typescript": "^5.5", "undici": "^7.10.0", - "warframe-public-export-plus": "^0.5.82", + "warframe-public-export-plus": "^0.5.83", "warframe-riven-info": "^0.1.2", "winston": "^3.17.0", "winston-daily-rotate-file": "^5.0.0", @@ -5507,9 +5507,9 @@ } }, "node_modules/warframe-public-export-plus": { - "version": "0.5.82", - "resolved": "https://registry.npmjs.org/warframe-public-export-plus/-/warframe-public-export-plus-0.5.82.tgz", - "integrity": "sha512-hZa9KpMDA2wy0Hn03y9Nfyzbjxer1I6Rvb52b363uzrqS0cvDO56rhiDo71JbraeV34qF6yo+Vca1zwFmw2srA==" + "version": "0.5.83", + "resolved": "https://registry.npmjs.org/warframe-public-export-plus/-/warframe-public-export-plus-0.5.83.tgz", + "integrity": "sha512-SJgw6NxQaiLgMfnKGML8mRY9lT3wJb3HEABSvuCd/XiKpUqPgqTCp7EwPhbG3D/FMtN+IZjBQgykLD5R7/MSRA==" }, "node_modules/warframe-riven-info": { "version": "0.1.2", diff --git a/package.json b/package.json index f7617ec7..ada60910 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "ncp": "^2.0.0", "typescript": "^5.5", "undici": "^7.10.0", - "warframe-public-export-plus": "^0.5.82", + "warframe-public-export-plus": "^0.5.83", "warframe-riven-info": "^0.1.2", "winston": "^3.17.0", "winston-daily-rotate-file": "^5.0.0", diff --git a/src/controllers/dynamic/worldStateController.ts b/src/controllers/dynamic/worldStateController.ts index f6b538d5..c15da876 100644 --- a/src/controllers/dynamic/worldStateController.ts +++ b/src/controllers/dynamic/worldStateController.ts @@ -4,7 +4,7 @@ import { version_compare } from "@/src/helpers/inventoryHelpers"; export const worldStateController: RequestHandler = async (req, res) => { const buildLabel = req.query.buildLabel as string | undefined; - const worldState = getWorldState(buildLabel); + const worldState = getWorldState("2025.08.26.09.49/IjV4RCfdEm14t9Q6vK5FgA"); const populatePromises = [populateDailyDeal(worldState)]; diff --git a/src/routes/api.ts b/src/routes/api.ts index 04d778b1..61ed670a 100644 --- a/src/routes/api.ts +++ b/src/routes/api.ts @@ -165,9 +165,7 @@ import { updateThemeController } from "@/src/controllers/api/updateThemeControll import { upgradesController } from "@/src/controllers/api/upgradesController"; import { valenceSwapController } from "@/src/controllers/api/valenceSwapController"; import { wishlistController } from "@/src/controllers/api/wishlistController"; - const apiRouter = express.Router(); - // get apiRouter.get("/abandonLibraryDailyTask.php", abandonLibraryDailyTaskController); apiRouter.get("/abortDojoComponentDestruction.php", abortDojoComponentDestructionController); diff --git a/src/routes/cache.ts b/src/routes/cache.ts index 622d361f..d3ac1188 100644 --- a/src/routes/cache.ts +++ b/src/routes/cache.ts @@ -1,6 +1,7 @@ import express from "express"; import { buildConfig } from "@/src/services/buildConfigService"; import fs from "fs/promises"; +import { worldStateController } from "@/src/controllers/dynamic/worldStateController"; const cacheRouter = express.Router(); @@ -27,5 +28,6 @@ cacheRouter.get(/^\/0\/.+!.+$/, async (req, res) => { res.status(404).end(); } }); +cacheRouter.get("/worldState.php", worldStateController); export { cacheRouter }; diff --git a/src/routes/dynamic.ts b/src/routes/dynamic.ts index c6950a16..15d37e05 100644 --- a/src/routes/dynamic.ts +++ b/src/routes/dynamic.ts @@ -9,6 +9,6 @@ const dynamicController = express.Router(); dynamicController.get("/aggregateSessions.php", aggregateSessionsController); dynamicController.get("/getGuildAds.php", getGuildAdsController); dynamicController.get("/getProfileViewingData.php", getProfileViewingDataGetController); -dynamicController.get("/worldState.php", worldStateController); +// dynamicController.get("/worldState.php", worldStateController); export { dynamicController }; diff --git a/src/services/worldStateService.ts b/src/services/worldStateService.ts index c2a575a7..629b3c5e 100644 --- a/src/services/worldStateService.ts +++ b/src/services/worldStateService.ts @@ -1920,6 +1920,45 @@ export const getWorldState = (buildLabel?: string): IWorldState => { RegularOverride: 0, StartDate: { $date: { $numberLong: "1755517920000" } }, EndDate: { $date: { $numberLong: "1893498780000" } } + }, + { + TypeName: "/Lotus/Types/StoreItems/Packages/HeirloomPackC", + ShowInMarket: true, + HideFromMarket: true, + SupporterPack: false, + Discount: 0, + BogoBuy: 0, + BogoGet: 0, + PremiumOverride: 1, + RegularOverride: 0, + StartDate: { $date: { $numberLong: "1755517920000" } }, + EndDate: { $date: { $numberLong: "1893498780000" } } + }, + { + TypeName: "/Lotus/Types/StoreItems/Packages/HeirloomPackB", + ShowInMarket: true, + HideFromMarket: true, + SupporterPack: false, + Discount: 0, + BogoBuy: 0, + BogoGet: 0, + PremiumOverride: 1, + RegularOverride: 0, + StartDate: { $date: { $numberLong: "1755517920000" } }, + EndDate: { $date: { $numberLong: "1893498780000" } } + }, + { + TypeName: "/Lotus/Types/StoreItems/Packages/PrimeAccessory2StoreItem", + ShowInMarket: true, + HideFromMarket: false, + SupporterPack: false, + Discount: 0, + BogoBuy: 0, + BogoGet: 0, + PremiumOverride: 1, + RegularOverride: 0, + StartDate: { $date: { $numberLong: "1755517920000" } }, + EndDate: { $date: { $numberLong: "1893498780000" } } } ], GlobalUpgrades: [], @@ -3003,7 +3042,7 @@ export const getWorldState = (buildLabel?: string): IWorldState => { Success: 0, Personal: true, Bounty: true, - Tag: config.unfaithfulBugFixes?.useAnniversaryTagForOldGoals ? tagsForOlderGoals[2] : "NightwatchTacAlert", + Tag: config.unfaithfulBugFixes?.useAnniversaryTagForOldGoals ? tagsForOlderGoals[2] : "GalleonRobbery", Faction: "FC_GRINEER", Desc: "/Lotus/Language/G1Quests/ProjectNightwatchTacAlertTitle", Icon: "/Lotus/Materials/Emblems/BountyBadge_e.png", diff --git a/src/types/worldStateTypes.ts b/src/types/worldStateTypes.ts index 3f4d233e..b3fc7e34 100644 --- a/src/types/worldStateTypes.ts +++ b/src/types/worldStateTypes.ts @@ -7,7 +7,7 @@ export interface IWorldState { Time: number; InGameMarket: IInGameMarket; Goals: IGoal[]; - Alerts: []; + Alerts: IGoal[]; Sorties: ISortie[]; LiteSorties: ILiteSortie[]; SyndicateMissions: ISyndicateMissionInfo[]; diff --git a/static/fixed_responses/worldState/worldState.json b/static/fixed_responses/worldState/worldState.json index 13cd9925..7c847800 100644 --- a/static/fixed_responses/worldState/worldState.json +++ b/static/fixed_responses/worldState/worldState.json @@ -181,6 +181,9 @@ "/Lotus/Types/StoreItems/Packages/PrimeAccess1AccessoryStoreItem", "/Lotus/Types/StoreItems/Packages/PrimeAccessoryStoreItem", "/Lotus/Types/StoreItems/Packages/PrimeAccessStoreItem", + "/Lotus/Types/StoreItems/Packages/HeirloomPackA", + "/Lotus/Types/StoreItems/Packages/HeirloomPackB", + "/Lotus/Types/StoreItems/Packages/HeirloomPackC", "/Lotus/Types/StoreItems/Packages/2024Bundles/VoltNovaSumoDeluxePack", "/Lotus/Types/StoreItems/Packages/2024Bundles/JadeShadowsSupporterPack", "/Lotus/Types/StoreItems/Packages/2024Bundles/WeaponStarterPack" @@ -352,9 +355,9 @@ } ], "NodeOverrides": [ - { "_id": { "$oid": "549b18e9b029cef5991d6aec" }, "Node": "EuropaHUB", "Hide": true }, - { "_id": { "$oid": "54a1737aeb658f6cbccf70ff" }, "Node": "ErisHUB", "Hide": true }, - { "_id": { "$oid": "54a736ddec12f80bd6e9e326" }, "Node": "VenusHUB", "Hide": true }, + { "_id": { "$oid": "549b18e9b029cef5991d6aec" }, "Node": "EuropaHUB", "Hide": false }, + { "_id": { "$oid": "54a1737aeb658f6cbccf70ff" }, "Node": "ErisHUB", "Hide": false }, + { "_id": { "$oid": "54a736ddec12f80bd6e9e326" }, "Node": "VenusHUB", "Hide": false }, { "_id": { "$oid": "5ad9f9bb6df82a56eabf3d44" }, "Node": "SolNode802", "Seed": 9969639 }, { "_id": { "$oid": "5b8817c2bd4f253264d6aa91" },