@hotbunny/hackhub-content-sdk 0.9.2 → 0.9.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.d.ts +25 -0
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -1851,6 +1851,31 @@ export declare namespace Random {
1851
1851
  export function sleep(ms: number): Promise<void>;
1852
1852
  export {};
1853
1853
  }
1854
+ /**
1855
+ * Mod settings API. Provides access to the values configured by
1856
+ * the player in the Mods menu (defined via Bootstrap.Settings).
1857
+ *
1858
+ * @example
1859
+ * ```ts
1860
+ * import { ModSettings } from "@hotbunny/hackhub-content-sdk";
1861
+ *
1862
+ * const difficulty = ModSettings.get<string>("difficulty");
1863
+ * const all = ModSettings.getAll();
1864
+ * ```
1865
+ */
1866
+ export declare namespace ModSettings {
1867
+ /** Get a setting value by key. Returns the default if not changed by player. */
1868
+ export function get<T = any>(key: string): T | undefined;
1869
+ /** Get all setting values as a key-value map. */
1870
+ export function getAll(): Record<string, any>;
1871
+ /** Programmatically set a setting value. */
1872
+ export function set(key: string, value: any): void;
1873
+ /** Reset a setting to its default value. */
1874
+ export function reset(key: string): void;
1875
+ /** Reset all settings to their defaults. */
1876
+ export function resetAll(): void;
1877
+ export {};
1878
+ }
1854
1879
  /**
1855
1880
  * Marks a class as the mod's entry point.
1856
1881
  * Each mod must have exactly one @RegisterModPackage class extending Bootstrap.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hotbunny/hackhub-content-sdk",
3
- "version": "0.9.2",
3
+ "version": "0.9.3",
4
4
  "description": "Official modding SDK for HackHub - Ultimate Hacker Simulator on Steam. Create custom quests, websites, terminal commands, and desktop apps.",
5
5
  "types": "index.d.ts",
6
6
  "exports": {