first prototype hopefully
This commit is contained in:
45
ambient.d.ts
vendored
Normal file
45
ambient.d.ts
vendored
Normal file
@@ -0,0 +1,45 @@
|
||||
/* eslint-disable no-unused-vars */
|
||||
/* eslint-disable @typescript-eslint/consistent-type-definitions */
|
||||
/* eslint-disable @typescript-eslint/member-delimiter-style */
|
||||
/* eslint-disable @typescript-eslint/naming-convention */
|
||||
/* eslint-disable @typescript-eslint/semi */
|
||||
|
||||
declare namespace LILY {
|
||||
interface Utils {
|
||||
with<V, R>(value: V, callback: (v: V) => R): R // A silly helper to kinda curry values
|
||||
}
|
||||
|
||||
interface Box {
|
||||
enable(): void
|
||||
disable(): void
|
||||
get equipped(): boolean
|
||||
get enabled(): boolean
|
||||
}
|
||||
|
||||
interface Eyes {
|
||||
zones: AssetGroupName[]
|
||||
craft: CraftingItem
|
||||
rgb: string[]
|
||||
timeout: NodeJS.Timeout | undefined
|
||||
set_rgb(item: Item, index: number): boolean
|
||||
next_rgb(): boolean | undefined
|
||||
roll_rgb(): void
|
||||
start(): boolean
|
||||
stop(): boolean
|
||||
dim(): boolean
|
||||
clear(): boolean
|
||||
check(zone: AssetGroupName): Item | undefined
|
||||
get item(): Item | undefined
|
||||
}
|
||||
|
||||
type CommandCB = (...arguments: string[]) => unknown
|
||||
type Command<T> = Record<string, T | CommandCB>
|
||||
interface Commands extends Command<Commands> {}
|
||||
interface Belt {
|
||||
admins: number[]
|
||||
cli: Commands
|
||||
is_cb(subject: Commands | CommandCB): subject is CommandCB
|
||||
run(tokens: string[]): string
|
||||
receive(data: ServerChatRoomMessage): undefined
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user