4577fae207
Quick Cheats, full command DB with category/source filters, item/perk/ buff/skill databases with fill-in parameters and per-flavor command variants, settings tab with hotkey recorder, opacity, flavor, autostart. Dark HUD theme on a transparent frameless window. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
70 lines
1.4 KiB
TypeScript
70 lines
1.4 KiB
TypeScript
export type Source = "cheatmod" | "devmode";
|
||
|
||
export interface CommandArg {
|
||
name: string;
|
||
required: boolean;
|
||
type: string; // "string" | "number" | "boolean"
|
||
desc: string;
|
||
}
|
||
|
||
export interface CommandExample {
|
||
caption: string;
|
||
command: string;
|
||
}
|
||
|
||
/** A command from the Cheat mod docs (built as `name arg:value ...`). */
|
||
export interface ModCommand {
|
||
name: string;
|
||
desc: string;
|
||
args: CommandArg[];
|
||
examples: CommandExample[];
|
||
category: string;
|
||
source: "cheatmod";
|
||
}
|
||
|
||
export interface TemplateParam {
|
||
name: string;
|
||
type: "number" | "string" | "select";
|
||
required?: boolean;
|
||
desc?: string;
|
||
default?: string | number;
|
||
options?: string[];
|
||
}
|
||
|
||
/** A hand-curated vanilla command (built from a `{placeholder}` template). */
|
||
export interface VanillaCommand {
|
||
name: string;
|
||
template: string;
|
||
desc: string;
|
||
params: TemplateParam[];
|
||
category: string;
|
||
source: "devmode";
|
||
}
|
||
|
||
export type AnyCommand = ModCommand | VanillaCommand;
|
||
|
||
export interface DbEntry {
|
||
id: string;
|
||
name: string;
|
||
desc: string;
|
||
params?: string; // buffs only: effect formula
|
||
}
|
||
|
||
export interface QuickEntry {
|
||
label: string;
|
||
desc: string;
|
||
params: TemplateParam[];
|
||
variants: Partial<Record<Source, string>>;
|
||
}
|
||
|
||
export interface QuickGroup {
|
||
group: string;
|
||
entries: QuickEntry[];
|
||
}
|
||
|
||
export interface Settings {
|
||
flavor: Source;
|
||
opacity: number; // 0.5–1
|
||
startHidden: boolean;
|
||
}
|