fix: add missing fields to config schema

This commit is contained in:
syntaxbullet
2025-12-18 17:39:46 +01:00
parent 71fefb3a14
commit 3c20b23cc1
2 changed files with 11 additions and 2 deletions

View File

@@ -23,6 +23,10 @@ export interface GameConfigType {
transfers: {
allowSelfTransfer: boolean;
minAmount: bigint;
},
exam: {
multMin: number;
multMax: number;
}
},
inventory: {
@@ -76,6 +80,10 @@ const configSchema = z.object({
transfers: z.object({
allowSelfTransfer: z.boolean(),
minAmount: bigIntSchema,
}),
exam: z.object({
multMin: z.number(),
multMax: z.number(),
})
}),
inventory: z.object({
@@ -115,7 +123,8 @@ export function reloadConfig() {
transfers: {
...rawConfig.economy.transfers,
minAmount: BigInt(rawConfig.economy.transfers.minAmount),
}
},
exam: rawConfig.economy.exam,
};
config.inventory = {
...rawConfig.inventory,