From 40f277884e03c71c9e1a3538f402d81b4c75648e Mon Sep 17 00:00:00 2001 From: punkfairie Date: Sat, 13 May 2023 14:23:16 -0700 Subject: [PATCH] Create Settings class. --- src/models/Settings.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/models/Settings.ts diff --git a/src/models/Settings.ts b/src/models/Settings.ts new file mode 100644 index 0000000..de42870 --- /dev/null +++ b/src/models/Settings.ts @@ -0,0 +1,19 @@ +export class Settings { + static #instance: Settings; + + minValue: number; + maxDistance: number; + + private constructor() { + this.minValue = 500000; + this.maxDistance = 10000; + } + + static get(): Settings { + if (!Settings.#instance) { + Settings.#instance = new Settings(); + } + + return Settings.#instance; + } +} \ No newline at end of file