forked from OpenWF/SpaceNinjaServer
feat: noDailyStandingLimits cheat (#791)
This commit is contained in:
parent
d8845bc478
commit
1a8e0f33b9
@ -28,5 +28,6 @@
|
||||
"unlockDoubleCapacityPotatoesEverywhere": true,
|
||||
"unlockExilusEverywhere": true,
|
||||
"unlockArcanesEverywhere": true,
|
||||
"noDailyStandingLimits": true,
|
||||
"spoofMasteryRank": -1
|
||||
}
|
||||
|
@ -15,6 +15,7 @@ import {
|
||||
ExportVirtuals
|
||||
} from "warframe-public-export-plus";
|
||||
import { handleSubsumeCompletion } from "./infestedFoundryController";
|
||||
import { allDailyAffiliationKeys } from "@/src/services/inventoryService";
|
||||
|
||||
export const inventoryController: RequestHandler = async (request, response) => {
|
||||
const account = await getAccountForRequest(request);
|
||||
@ -32,20 +33,9 @@ export const inventoryController: RequestHandler = async (request, response) =>
|
||||
account.LastLoginDay = today;
|
||||
await account.save();
|
||||
|
||||
inventory.DailyAffiliation = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationPvp = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationLibrary = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationCetus = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationQuills = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationSolaris = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationVentkids = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationVox = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationEntrati = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationNecraloid = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationZariman = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationKahl = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationCavia = 16000 + inventory.PlayerLevel * 500;
|
||||
inventory.DailyAffiliationHex = 16000 + inventory.PlayerLevel * 500;
|
||||
for (const key of allDailyAffiliationKeys) {
|
||||
inventory[key] = 16000 + inventory.PlayerLevel * 500;
|
||||
}
|
||||
inventory.DailyFocus = 250000 + inventory.PlayerLevel * 5000;
|
||||
await inventory.save();
|
||||
}
|
||||
@ -244,6 +234,12 @@ export const inventoryController: RequestHandler = async (request, response) =>
|
||||
}
|
||||
}
|
||||
|
||||
if (config.noDailyStandingLimits) {
|
||||
for (const key of allDailyAffiliationKeys) {
|
||||
inventoryResponse[key] = 999_999;
|
||||
}
|
||||
}
|
||||
|
||||
// Fix for #380
|
||||
inventoryResponse.NextRefill = { $date: { $numberLong: "9999999999999" } };
|
||||
|
||||
|
@ -54,6 +54,7 @@ interface IConfig {
|
||||
unlockDoubleCapacityPotatoesEverywhere?: boolean;
|
||||
unlockExilusEverywhere?: boolean;
|
||||
unlockArcanesEverywhere?: boolean;
|
||||
noDailyStandingLimits?: boolean;
|
||||
spoofMasteryRank?: number;
|
||||
}
|
||||
|
||||
|
@ -514,8 +514,12 @@ const standingLimitBinToInventoryKey: Record<
|
||||
STANDING_LIMIT_BIN_HEX: "DailyAffiliationHex"
|
||||
};
|
||||
|
||||
export const allDailyAffiliationKeys: (keyof IDailyAffiliations)[] = Object.entries(standingLimitBinToInventoryKey).map(
|
||||
arr => arr[1]
|
||||
);
|
||||
|
||||
export const getStandingLimit = (inventory: IDailyAffiliations, bin: TStandingLimitBin): number => {
|
||||
if (bin == "STANDING_LIMIT_BIN_NONE") {
|
||||
if (bin == "STANDING_LIMIT_BIN_NONE" || config.noDailyStandingLimits) {
|
||||
return Number.MAX_SAFE_INTEGER;
|
||||
}
|
||||
return inventory[standingLimitBinToInventoryKey[bin]];
|
||||
@ -526,7 +530,7 @@ export const updateStandingLimit = (
|
||||
bin: TStandingLimitBin,
|
||||
subtrahend: number
|
||||
): void => {
|
||||
if (bin != "STANDING_LIMIT_BIN_NONE") {
|
||||
if (bin != "STANDING_LIMIT_BIN_NONE" && !config.noDailyStandingLimits) {
|
||||
inventory[standingLimitBinToInventoryKey[bin]] -= subtrahend;
|
||||
}
|
||||
};
|
||||
|
@ -298,6 +298,12 @@
|
||||
Arcane Adapters Everywhere
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-check">
|
||||
<input class="form-check-input" type="checkbox" id="noDailyStandingLimits" />
|
||||
<label class="form-check-label" for="noDailyStandingLimits">
|
||||
No Daily Standing Limits
|
||||
</label>
|
||||
</div>
|
||||
<div class="form-group mt-2">
|
||||
<label class="form-label" for="spoofMasteryRank">
|
||||
Spoofed Mastery Rank (-1 to disable)
|
||||
|
Loading…
x
Reference in New Issue
Block a user