From aa6c51a9cb8f35afc9bbcf3bcd95e0221a2dca76 Mon Sep 17 00:00:00 2001 From: SirEdvin Date: Sun, 26 Jul 2026 08:18:24 +0000 Subject: [PATCH 1/3] feat: complete peripheral type coverage --- .../displayPedestal.d.ts | 11 +++ .../displayPedestal.ts | 15 ++++ .../entityLink.d.ts | 8 +++ .../entityLink.ts | 12 ++++ .../hologramProjector.d.ts | 52 ++++++++++++++ .../hologramProjector.ts | 52 ++++++++++++++ .../informativeRegistry.d.ts | 6 +- .../informativeRegistry.ts | 7 +- .../integrations/ae2.d.ts | 36 ++++++++++ .../integrations/ae2.ts | 36 ++++++++++ .../integrations/arsNouveau.d.ts | 9 +++ .../integrations/arsNouveau.ts | 11 +++ .../integrations/create/api.d.ts | 24 +++++++ .../integrations/create/api.ts | 26 +++++++ .../integrations/deepResonance.d.ts | 21 ++++++ .../integrations/deepResonance.ts | 22 ++++++ .../integrations/easyVillagers.d.ts | 14 ++++ .../integrations/easyVillagers.ts | 21 ++++++ .../integrations/entityLink.d.ts | 18 +++++ .../integrations/entityLink.ts | 28 ++++++++ .../integrations/fluxController.d.ts | 35 ++++++++++ .../integrations/fluxController.ts | 40 +++++++++++ .../integrations/gtceu/controllable.d.ts | 4 +- .../integrations/gtceu/controllable.ts | 6 +- .../integrations/gtceu/workable.d.ts | 2 + .../integrations/gtceu/workable.ts | 2 + .../integrations/lantern.d.ts | 7 ++ .../integrations/lantern.ts | 9 +++ .../integrations/magicTome.d.ts | 25 +++++++ .../integrations/magicTome.ts | 30 ++++++++ .../integrations/naturesCompass.d.ts | 16 +++++ .../integrations/naturesCompass.ts | 21 ++++++ .../integrations/occultism.d.ts | 14 ++++ .../integrations/occultism.ts | 18 +++++ .../integrations/powah.d.ts | 27 +++++++ .../integrations/powah.ts | 36 ++++++++++ .../integrations/specializedMachines.d.ts | 22 ++++++ .../integrations/specializedMachines.ts | 29 ++++++++ .../integrations/universalShop.d.ts | 15 ++++ .../integrations/universalShop.ts | 17 +++++ .../integrations/vanilla.d.ts | 51 ++++++++++++++ .../integrations/vanilla.ts | 70 +++++++++++++++++++ .../itemPedestal.d.ts | 6 ++ .../itemPedestal.ts | 9 +++ .../mapPedestal.d.ts | 19 +++++ .../mapPedestal.ts | 20 ++++++ .../networkManager.d.ts | 5 +- .../networkManager.ts | 5 +- .../package-lock.json | 4 +- .../package.json | 2 +- .../peripheralHub.d.ts | 26 +++++++ .../peripheralHub.ts | 36 ++++++++++ .../realityForger.d.ts | 22 ++++++ .../realityForger.ts | 31 ++++++++ .../recipeRegistry.d.ts | 3 + .../recipeRegistry.ts | 3 + .../remoteObserver.d.ts | 17 +++++ .../remoteObserver.ts | 23 ++++++ .../statueWorkbench.d.ts | 4 +- .../statueWorkbench.ts | 4 +- .../turtle.d.ts | 13 ++++ .../turtle.ts | 17 +++++ .../types.d.ts | 10 +++ .../types.ts | 8 +++ .../ultimateSensor.d.ts | 12 ++++ .../ultimateSensor.ts | 25 +++++++ 66 files changed, 1232 insertions(+), 17 deletions(-) create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/realityForger.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/turtle.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/types.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/types.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts create mode 100644 projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.ts diff --git a/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts new file mode 100644 index 00000000..6be5c96f --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts @@ -0,0 +1,11 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface DisplayPedestal extends IPeripheral { + getItem(): ItemDetail | null; + setItem(id: string, name?: string, nbtData?: string): Result; + isLabelRendered(): boolean; + setLabelRendered(value: boolean): void; + isItemRendered(): boolean; + setItemRendered(value: boolean): void; +} +export declare const displayPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.ts b/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.ts new file mode 100644 index 00000000..f286f000 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.ts @@ -0,0 +1,15 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface DisplayPedestal extends IPeripheral { + getItem(): ItemDetail | null; + setItem(id: string, name?: string, nbtData?: string): Result; + isLabelRendered(): boolean; + setLabelRendered(value: boolean): void; + isItemRendered(): boolean; + setItemRendered(value: boolean): void; +} + +export const displayPedestalProvider = new IPeripheralProvider( + "display_pedestal" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts new file mode 100644 index 00000000..9e14b1df --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts @@ -0,0 +1,8 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "./types"; +/** @noSelf **/ +export interface EntityLink extends IPeripheral { + isEntityFound(): boolean; + inspect(): EntityDetail | null; +} +export declare const entityLinkProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts new file mode 100644 index 00000000..271da5c9 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts @@ -0,0 +1,12 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "./types"; + +/** @noSelf **/ +export interface EntityLink extends IPeripheral { + isEntityFound(): boolean; + inspect(): EntityDetail | null; +} + +export const entityLinkProvider = new IPeripheralProvider( + "entity_link" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts new file mode 100644 index 00000000..f2713fcd --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts @@ -0,0 +1,52 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { BlockState, Position } from "./types"; +export type Vector3 = [number, number, number]; +export type Quaternion = [number, number, number, number]; +export type DisplayOptions = { + brightness?: number; + glow_color_override?: number; + interpolation_duration?: number; + start_interpolation?: number; + height?: number; + width?: number; + shadow_radius?: number; + shadow_strength?: number; + view_range?: number; + billboard?: string; + transformation?: { + scale?: Vector3; + translation?: Vector3; + left_rotation?: Quaternion; + right_rotation?: Quaternion; + }; +}; +export type TextDisplayOptions = DisplayOptions & { + line_width?: number; + background?: number; + shadow?: boolean; + see_through?: boolean; + default_background?: boolean; + text_opacity?: number; + alignment?: string; +}; +export type ItemDisplayOptions = DisplayOptions & { + item_display?: string; +}; +/** @noSelf **/ +export interface HologramProjector extends ConfigurationAPI<{ + entityLimit: number; + distanceLimit: number; +}> { + item(item: object, options?: ItemDisplayOptions): string; + block(blockState: BlockState, options?: DisplayOptions): string; + text(text: object, options?: TextDisplayOptions): string; + destroy(uuid: string): Result; + move(uuid: string, position: Position): Result; + rotate(uuid: string, xRot?: number, yRot?: number): Result; + list(mode: "owned" | "around"): LuaTable; + update(uuid: string, content?: object, options?: DisplayOptions): Result; + ride(riderUUID: string, mountUUID: string): Result; + unmount(riderUUID: string): Result; +} +export declare const hologramProjectorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts new file mode 100644 index 00000000..e293cbf8 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts @@ -0,0 +1,52 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { BlockState, Position } from "./types"; + +export type Vector3 = [number, number, number]; +export type Quaternion = [number, number, number, number]; +export type DisplayOptions = { + brightness?: number; + glow_color_override?: number; + interpolation_duration?: number; + start_interpolation?: number; + height?: number; + width?: number; + shadow_radius?: number; + shadow_strength?: number; + view_range?: number; + billboard?: string; + transformation?: { + scale?: Vector3; + translation?: Vector3; + left_rotation?: Quaternion; + right_rotation?: Quaternion; + }; +}; +export type TextDisplayOptions = DisplayOptions & { + line_width?: number; + background?: number; + shadow?: boolean; + see_through?: boolean; + default_background?: boolean; + text_opacity?: number; + alignment?: string; +}; +export type ItemDisplayOptions = DisplayOptions & { item_display?: string }; + +/** @noSelf **/ +export interface HologramProjector + extends ConfigurationAPI<{ entityLimit: number; distanceLimit: number }> { + item(item: object, options?: ItemDisplayOptions): string; + block(blockState: BlockState, options?: DisplayOptions): string; + text(text: object, options?: TextDisplayOptions): string; + destroy(uuid: string): Result; + move(uuid: string, position: Position): Result; + rotate(uuid: string, xRot?: number, yRot?: number): Result; + list(mode: "owned" | "around"): LuaTable; + update(uuid: string, content?: object, options?: DisplayOptions): Result; + ride(riderUUID: string, mountUUID: string): Result; + unmount(riderUUID: string): Result; +} + +export const hologramProjectorProvider = + new IPeripheralProvider("hologram_projector"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts index 406113ad..828b0071 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts @@ -2,10 +2,10 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { FluidDetail, IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface InformativeRegistry extends ConfigurationAPI { - list(listName: "list" | "item" | "fluid" | "block" | "itemTags" | "fluidTags" | "blockTags"): string[]; - describe(listName: "itemTags" | "blockTags" | "fluidTags", tag: string): string[]; + list(listName: "list" | "item" | "fluid" | "block" | "itemTags" | "fluidTags" | "blockTags" | "entityTypeTags" | "mods" | "entity"): string[]; + describe(listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string): string[]; describe(listName: "item", id: string): ItemDetail; describe(listName: "fluid", id: string): FluidDetail; - describe(listName: "list" | "block", id: string): LuaTable; + describe(listName: "list" | "block" | "mods" | "entity", id: string): LuaTable; } export declare const informativeRegistryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts index de47b423..f41724c7 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts @@ -12,14 +12,17 @@ export interface InformativeRegistry extends ConfigurationAPI { | "itemTags" | "fluidTags" | "blockTags" + | "entityTypeTags" + | "mods" + | "entity" ): string[]; describe( - listName: "itemTags" | "blockTags" | "fluidTags", + listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string ): string[]; describe(listName: "item", id: string): ItemDetail; describe(listName: "fluid", id: string): FluidDetail; - describe(listName: "list" | "block", id: string): LuaTable; + describe(listName: "list" | "block" | "mods" | "entity", id: string): LuaTable; } export const informativeRegistryProvider = diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts new file mode 100644 index 00000000..4e9e078c --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts @@ -0,0 +1,36 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type AE2CraftingCPU = { + name?: string; + capacity: number; + storage: number; + isBusy: boolean; +}; +export type AE2Pattern = { + inputs: object[]; + outputs: object[]; +}; +export type AE2Crafting = { + target: object; + amount: number; + progress: number; + CPU?: string; +}; +/** @noSelf **/ +export interface AE2NetworkAPI extends IPeripheral { + getAverageEnergyDemand(): number; + getAverageEnergyIncome(): number; + getChannelEnergyDemand(): number; + getChannelInformation(): { + maxChannels: number; + usedChannels: number; + }; + getCraftingCPUs(): AE2CraftingCPU[]; + getCraftableItems(): ItemDetail[]; + getCraftableFluids(): { + name: string; + }[]; + getPatternsFor(mode: "item" | "fluid", id: string): AE2Pattern[]; + getActiveCraftings(): AE2Crafting[]; + scheduleCrafting(mode: "item" | "fluid", id: string, amount?: number, targetCPU?: string): Result; +} +export declare const ae2Provider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts new file mode 100644 index 00000000..c5c0b31f --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts @@ -0,0 +1,36 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type AE2CraftingCPU = { + name?: string; + capacity: number; + storage: number; + isBusy: boolean; +}; +export type AE2Pattern = { inputs: object[]; outputs: object[] }; +export type AE2Crafting = { + target: object; + amount: number; + progress: number; + CPU?: string; +}; + +/** @noSelf **/ +export interface AE2NetworkAPI extends IPeripheral { + getAverageEnergyDemand(): number; + getAverageEnergyIncome(): number; + getChannelEnergyDemand(): number; + getChannelInformation(): { maxChannels: number; usedChannels: number }; + getCraftingCPUs(): AE2CraftingCPU[]; + getCraftableItems(): ItemDetail[]; + getCraftableFluids(): { name: string }[]; + getPatternsFor(mode: "item" | "fluid", id: string): AE2Pattern[]; + getActiveCraftings(): AE2Crafting[]; + scheduleCrafting( + mode: "item" | "fluid", + id: string, + amount?: number, + targetCPU?: string + ): Result; +} + +export const ae2Provider = new IPeripheralProvider("ae2"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts new file mode 100644 index 00000000..00250772 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts @@ -0,0 +1,9 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; +/** @noSelf **/ +export interface ArsNouveauMobJar extends IPeripheral { + inspect(): { + entity: EntityDetail; + } | object; +} +export declare const mobJarProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts new file mode 100644 index 00000000..41d19eed --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts @@ -0,0 +1,11 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; + +/** @noSelf **/ +export interface ArsNouveauMobJar extends IPeripheral { + inspect(): { entity: EntityDetail } | object; +} + +export const mobJarProvider = new IPeripheralProvider( + "mob_jar" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts new file mode 100644 index 00000000..8220d70f --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts @@ -0,0 +1,24 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { CreateFilterableAPI } from "./filterable_api"; +/** @noSelf **/ +export interface CreateScrollOptionAPI extends IPeripheral { + getScrollValue(): number; + setScrollValue(value: number): void; +} +/** @noSelf **/ +export interface CreateLinearActuatorAPI extends IPeripheral { + inspect(): { + movementSpeed: number; + isRunning: boolean; + }; +} +/** @noSelf **/ +export interface CreateBlazeBurnerAPI extends IPeripheral { + inspect(): { + fuelType: string; + remainingBurnTime: number; + }; +} +export declare const createFilterProvider: IPeripheralProvider; +export declare const createScrollProvider: IPeripheralProvider; +export declare const createProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts new file mode 100644 index 00000000..f305b62e --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts @@ -0,0 +1,26 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { CreateFilterableAPI } from "./filterable_api"; + +/** @noSelf **/ +export interface CreateScrollOptionAPI extends IPeripheral { + getScrollValue(): number; + setScrollValue(value: number): void; +} + +/** @noSelf **/ +export interface CreateLinearActuatorAPI extends IPeripheral { + inspect(): { movementSpeed: number; isRunning: boolean }; +} + +/** @noSelf **/ +export interface CreateBlazeBurnerAPI extends IPeripheral { + inspect(): { fuelType: string; remainingBurnTime: number }; +} + +export const createFilterProvider = + new IPeripheralProvider("create_filter"); +export const createScrollProvider = + new IPeripheralProvider("create_scroll"); +export const createProvider = new IPeripheralProvider< + CreateLinearActuatorAPI | CreateBlazeBurnerAPI +>("create"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts new file mode 100644 index 00000000..5d5a9660 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts @@ -0,0 +1,21 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface DeepResonanceCrystal extends IPeripheral { + inspect(): { + strength: number; + efficiency: number; + power: number; + purity: number; + glowing: boolean; + }; +} +/** @noSelf **/ +export interface DeepResonanceGenerator extends IPeripheral { + inspect(): { + energy: number; + lastRfPerTick: number; + isActive: boolean; + }; +} +export declare const resonatingCrystalProvider: IPeripheralProvider; +export declare const deepResonanceGeneratorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts new file mode 100644 index 00000000..99fa0aae --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts @@ -0,0 +1,22 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface DeepResonanceCrystal extends IPeripheral { + inspect(): { + strength: number; + efficiency: number; + power: number; + purity: number; + glowing: boolean; + }; +} + +/** @noSelf **/ +export interface DeepResonanceGenerator extends IPeripheral { + inspect(): { energy: number; lastRfPerTick: number; isActive: boolean }; +} + +export const resonatingCrystalProvider = + new IPeripheralProvider("resonating_crystal"); +export const deepResonanceGeneratorProvider = + new IPeripheralProvider("generator"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts new file mode 100644 index 00000000..026345b6 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts @@ -0,0 +1,14 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; +/** @noSelf **/ +export interface EasyTrader extends IPeripheral { + hasVillager(): boolean; + inspect(): EntityDetail | null; +} +/** @noSelf **/ +export interface EasyAutoTrader extends EasyTrader { + getSelectedOffer(): number; + setSelectedOffer(index: number): Result; +} +export declare const easyTraderProvider: IPeripheralProvider; +export declare const easyAutoTraderProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.ts new file mode 100644 index 00000000..bf16dbf2 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.ts @@ -0,0 +1,21 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; + +/** @noSelf **/ +export interface EasyTrader extends IPeripheral { + hasVillager(): boolean; + inspect(): EntityDetail | null; +} + +/** @noSelf **/ +export interface EasyAutoTrader extends EasyTrader { + getSelectedOffer(): number; + setSelectedOffer(index: number): Result; +} + +export const easyTraderProvider = new IPeripheralProvider( + "easy_trader" +); +export const easyAutoTraderProvider = new IPeripheralProvider( + "easy_auto_trader" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts new file mode 100644 index 00000000..033bf558 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts @@ -0,0 +1,18 @@ +import { Position } from "../types"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface ManaAndArtificeConstructAPI extends IPeripheral { + move(position: Position): Result; + store(position: Position, direction?: string): Result; + take(position: Position, direction: string | undefined, item: string, amount?: number): Result; + listCommands(): string[]; + diagnose(): LuaTable; + getCommand(): string; +} +/** @noSelf **/ +export interface AutomobilityAutomobileAPI extends IPeripheral { + rotate(delta: number): void; + boost(power: number, time: number): void; +} +export declare const constructProvider: IPeripheralProvider; +export declare const automobileProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts new file mode 100644 index 00000000..712a2632 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts @@ -0,0 +1,28 @@ +import { Position } from "../types"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface ManaAndArtificeConstructAPI extends IPeripheral { + move(position: Position): Result; + store(position: Position, direction?: string): Result; + take( + position: Position, + direction: string | undefined, + item: string, + amount?: number + ): Result; + listCommands(): string[]; + diagnose(): LuaTable; + getCommand(): string; +} + +/** @noSelf **/ +export interface AutomobilityAutomobileAPI extends IPeripheral { + rotate(delta: number): void; + boost(power: number, time: number): void; +} + +export const constructProvider = + new IPeripheralProvider("construct"); +export const automobileProvider = + new IPeripheralProvider("automobile"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts new file mode 100644 index 00000000..fbd1c5ad --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts @@ -0,0 +1,35 @@ +import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type FluxConnection = { + customName: string; + maxTransferLimit: number; + transferBuffer: number; + transferChange: number; + surgeMode: boolean; + deviceType: string; + isChunkLoaded: boolean; +}; +export type FluxNetwork = { + name: string; + id: number; + color: number; + securityLevel: string; +}; +export type FluxStatistics = { + controllerCount: number; + pointCount: number; + plugCount: number; + storageCount: number; + totalBuffer: number; + totalEnergy: number; + energyInput: number; + energyOutput: number; + averageTick: number; +}; +/** @noSelf **/ +export interface FluxController extends EnergyStorageAPI { + getConnections(): FluxConnection[]; + getNetwork(): FluxNetwork; + getStatistic(): FluxStatistics; +} +export declare const fluxControllerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.ts new file mode 100644 index 00000000..f6b031e4 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.ts @@ -0,0 +1,40 @@ +import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type FluxConnection = { + customName: string; + maxTransferLimit: number; + transferBuffer: number; + transferChange: number; + surgeMode: boolean; + deviceType: string; + isChunkLoaded: boolean; +}; +export type FluxNetwork = { + name: string; + id: number; + color: number; + securityLevel: string; +}; +export type FluxStatistics = { + controllerCount: number; + pointCount: number; + plugCount: number; + storageCount: number; + totalBuffer: number; + totalEnergy: number; + energyInput: number; + energyOutput: number; + averageTick: number; +}; + +/** @noSelf **/ +export interface FluxController extends EnergyStorageAPI { + getConnections(): FluxConnection[]; + getNetwork(): FluxNetwork; + getStatistic(): FluxStatistics; +} + +export const fluxControllerProvider = new IPeripheralProvider( + "flux_controller" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts index 86b06f0c..89e8fa84 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts @@ -3,6 +3,8 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ControllableMachine extends ConfigurationAPI { isWorkingEnabled(): boolean; - setWorkingEnabled(value: boolean): any; + setWorkingEnabled(value: boolean): void; + setSuspendAfterFinish(value: boolean): void; } +export declare const controllableProvider: IPeripheralProvider; export declare const workableProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts index 63507682..8466cf9f 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts @@ -4,10 +4,12 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ControllableMachine extends ConfigurationAPI { isWorkingEnabled(): boolean; - setWorkingEnabled(value: boolean); + setWorkingEnabled(value: boolean): void; + setSuspendAfterFinish(value: boolean): void; } -export const workableProvider = new IPeripheralProvider( +export const controllableProvider = new IPeripheralProvider( "gtceu:controllable", () => null ); +export const workableProvider = controllableProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts index 7fa4fcda..7a3910ee 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts @@ -2,6 +2,8 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface WorkableMachine extends ConfigurationAPI { + getProgress(): number; + getMaxProgress(): number; isActive(): boolean; } export declare const workableProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.ts index e98308a9..7bd03a3c 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.ts @@ -3,6 +3,8 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface WorkableMachine extends ConfigurationAPI { + getProgress(): number; + getMaxProgress(): number; isActive(): boolean; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts new file mode 100644 index 00000000..7ea991f7 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts @@ -0,0 +1,7 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface Lantern extends IPeripheral { + isEnabled(): boolean; + toggle(): Result; +} +export declare const lanternProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.ts new file mode 100644 index 00000000..cd51cd62 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.ts @@ -0,0 +1,9 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface Lantern extends IPeripheral { + isEnabled(): boolean; + toggle(): Result; +} + +export const lanternProvider = new IPeripheralProvider("lantern"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts new file mode 100644 index 00000000..a494786c --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts @@ -0,0 +1,25 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type SpellDetail = { + name: string; + display: string; + color: number; + sound?: string; + cost: number; +}; +export type ManaDetail = { + current: number; + max: number; + bookTier: number; + glyphBonus: number; +}; +/** @noSelf **/ +export interface MagicTome extends IPeripheral { + getSpells(): LuaTable; + getSelectedSlot(): number; + size(): number; + getSelectedSpell(): SpellDetail; + select(slot: number): void; + getMana(): ManaDetail; + cast(): void; +} +export declare const magicTomeProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.ts new file mode 100644 index 00000000..15df18c6 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.ts @@ -0,0 +1,30 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type SpellDetail = { + name: string; + display: string; + color: number; + sound?: string; + cost: number; +}; +export type ManaDetail = { + current: number; + max: number; + bookTier: number; + glyphBonus: number; +}; + +/** @noSelf **/ +export interface MagicTome extends IPeripheral { + getSpells(): LuaTable; + getSelectedSlot(): number; + size(): number; + getSelectedSpell(): SpellDetail; + select(slot: number): void; + getMana(): ManaDetail; + cast(): void; +} + +export const magicTomeProvider = new IPeripheralProvider( + "magic_tome" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts new file mode 100644 index 00000000..f67c5f94 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts @@ -0,0 +1,16 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type NatureCompassResult = { + x: number; + z: number; + distance: number; + biome: string; +}; +/** @noSelf **/ +export interface NaturesCompass extends ConfigurationAPI { + getBiomes(): string[]; + scheduleSearch(biome: string): Result; + getState(): string; + getResult(): NatureCompassResult | null; +} +export declare const naturesCompassProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.ts new file mode 100644 index 00000000..2d79fb3c --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.ts @@ -0,0 +1,21 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type NatureCompassResult = { + x: number; + z: number; + distance: number; + biome: string; +}; + +/** @noSelf **/ +export interface NaturesCompass extends ConfigurationAPI { + getBiomes(): string[]; + scheduleSearch(biome: string): Result; + getState(): string; + getResult(): NatureCompassResult | null; +} + +export const naturesCompassProvider = new IPeripheralProvider( + "natures_compass" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts new file mode 100644 index 00000000..c7f3e9af --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts @@ -0,0 +1,14 @@ +import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface OccultismStorage extends ItemStorageAPI { + getMaxSlots(): number; + getUsedSlots(): number; + isBlacklisted(itemID: string): boolean; +} +/** @noSelf **/ +export interface OccultismGoldenBowl extends IPeripheral { + isBusy(): boolean; + getCraftingInformation(): LuaTable | null; +} +export declare const occultismProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts new file mode 100644 index 00000000..efbc03e7 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts @@ -0,0 +1,18 @@ +import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface OccultismStorage extends ItemStorageAPI { + getMaxSlots(): number; + getUsedSlots(): number; + isBlacklisted(itemID: string): boolean; +} + +/** @noSelf **/ +export interface OccultismGoldenBowl extends IPeripheral { + isBusy(): boolean; + getCraftingInformation(): LuaTable | null; +} + +export const occultismProvider = + new IPeripheralProvider("occultism"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts new file mode 100644 index 00000000..5ac74f2a --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts @@ -0,0 +1,27 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface PowahEnergyStorageAPI extends IPeripheral { + getEnergyTransfer(): number; +} +/** @noSelf **/ +export interface PowahGeneratorAPI extends PowahEnergyStorageAPI { + getEnergyGeneration(): number; +} +/** @noSelf **/ +export interface PowahReactorAPI extends PowahGeneratorAPI { + inspect(): LuaTable; + toggleAutoMode(): void; +} +/** @noSelf **/ +export interface PowahEnderCellAPI extends PowahEnergyStorageAPI { + getChannel(): number; + setChannel(channel: number): void; + getMaxChannel(): number; +} +/** @noSelf **/ +export interface PowahRedstoneControlAPI extends IPeripheral { + getRedstoneMode(): string; + setRedstoneMode(mode: string): void; +} +export declare const powahExtraProvider: IPeripheralProvider; +export declare const powahRedstoneProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts new file mode 100644 index 00000000..ab07bfda --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts @@ -0,0 +1,36 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface PowahEnergyStorageAPI extends IPeripheral { + getEnergyTransfer(): number; +} + +/** @noSelf **/ +export interface PowahGeneratorAPI extends PowahEnergyStorageAPI { + getEnergyGeneration(): number; +} + +/** @noSelf **/ +export interface PowahReactorAPI extends PowahGeneratorAPI { + inspect(): LuaTable; + toggleAutoMode(): void; +} + +/** @noSelf **/ +export interface PowahEnderCellAPI extends PowahEnergyStorageAPI { + getChannel(): number; + setChannel(channel: number): void; + getMaxChannel(): number; +} + +/** @noSelf **/ +export interface PowahRedstoneControlAPI extends IPeripheral { + getRedstoneMode(): string; + setRedstoneMode(mode: string): void; +} + +export const powahExtraProvider = new IPeripheralProvider< + PowahEnergyStorageAPI | PowahGeneratorAPI | PowahReactorAPI | PowahEnderCellAPI +>("powah_extra"); +export const powahRedstoneProvider = + new IPeripheralProvider("powah_redstone"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts new file mode 100644 index 00000000..1f689a41 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts @@ -0,0 +1,22 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface ModernIndustrializationCrafter extends IPeripheral { + isBusy(): boolean; + getCraftingInformation(): { + progress: number; + currentEfficiency: number; + maxEfficiency: number; + baseRecipeCost: number; + currentRecipeCost: number; + } | object; +} +/** @noSelf **/ +export interface AlloyForgeryController extends IPeripheral { + inspect(): { + fuel: number; + currentSmeltTime: number; + smeltProgress: number; + }; +} +export declare const miCrafterProvider: IPeripheralProvider; +export declare const alloyForgeryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.ts new file mode 100644 index 00000000..31abbca3 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.ts @@ -0,0 +1,29 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface ModernIndustrializationCrafter extends IPeripheral { + isBusy(): boolean; + getCraftingInformation(): + | { + progress: number; + currentEfficiency: number; + maxEfficiency: number; + baseRecipeCost: number; + currentRecipeCost: number; + } + | object; +} + +/** @noSelf **/ +export interface AlloyForgeryController extends IPeripheral { + inspect(): { + fuel: number; + currentSmeltTime: number; + smeltProgress: number; + }; +} + +export const miCrafterProvider = + new IPeripheralProvider("mi_crafter"); +export const alloyForgeryProvider = + new IPeripheralProvider("alloy_forgery"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts new file mode 100644 index 00000000..bd3d7582 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts @@ -0,0 +1,15 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type ShopItemSetting = { + type: string; + price?: ItemDetail; +}; +/** @noSelf **/ +export interface UniversalShop extends IPeripheral { + getHologramMode(): string; + setHologramMode(mode: string): void; + getPrice(): ShopItemSetting; + setPrice(type: "free" | "single_item", itemHint?: object): Result; + getStock(): ShopItemSetting; + setStock(type: "selected_item" | "single_item", itemHint?: object): Result; +} +export declare const universalShopProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.ts new file mode 100644 index 00000000..27e93216 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.ts @@ -0,0 +1,17 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type ShopItemSetting = { type: string; price?: ItemDetail }; + +/** @noSelf **/ +export interface UniversalShop extends IPeripheral { + getHologramMode(): string; + setHologramMode(mode: string): void; + getPrice(): ShopItemSetting; + setPrice(type: "free" | "single_item", itemHint?: object): Result; + getStock(): ShopItemSetting; + setStock(type: "selected_item" | "single_item", itemHint?: object): Result; +} + +export const universalShopProvider = new IPeripheralProvider( + "universal_shop" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts new file mode 100644 index 00000000..0ea501a8 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts @@ -0,0 +1,51 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; +/** @noSelf **/ +export interface Lectern extends IPeripheral { + hasBook(): boolean; + getPageCount(): number; + getActivePage(): number; + setActivePage(page: number): Result; + getText(): string[]; + isBookEditable(): boolean; + addPage(text?: string): Result; + removePage(page: number): Result; + editPage(page: number, text: string): Result; + ejectBook(toName: string): Result; + injectBook(fromName: string, query?: object): Result; +} +/** @noSelf **/ +export interface Beacon extends IPeripheral { + getLevel(): number; + getPossiblePowers(): string[]; + getPowers(): object[]; + configure(primaryPower: string, fromInventory: string, paymentQuery: object, regenerationSecondary?: boolean): Result; +} +/** @noSelf **/ +export interface NoteBlock extends IPeripheral { + getNote(): number; + setNote(note: number): void; + getInstrument(): string; + setInstrument(instrument: string): void; + play(): void; +} +/** @noSelf **/ +export interface PoweredRail extends ExtendedInventoryAPI { + isPowered(): boolean; + pushMinecarts(reverse?: boolean): void; + getMinecarts(): EntityDetail[]; +} +/** @noSelf **/ +export interface Jukebox extends IPeripheral { + getDisc(): ItemDetail | null; + replay(): void; + stop(): void; + ejectDisc(toName: string): Result; + injectDisc(fromName: string, query?: object): Result; +} +export declare const lecternProvider: IPeripheralProvider; +export declare const beaconProvider: IPeripheralProvider; +export declare const noteBlockProvider: IPeripheralProvider; +export declare const poweredRailProvider: IPeripheralProvider; +export declare const jukeboxProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts new file mode 100644 index 00000000..979b51bb --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts @@ -0,0 +1,70 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { EntityDetail } from "../types"; + +/** @noSelf **/ +export interface Lectern extends IPeripheral { + hasBook(): boolean; + getPageCount(): number; + getActivePage(): number; + setActivePage(page: number): Result; + getText(): string[]; + isBookEditable(): boolean; + addPage(text?: string): Result; + removePage(page: number): Result; + editPage(page: number, text: string): Result; + ejectBook(toName: string): Result; + injectBook(fromName: string, query?: object): Result; +} + +/** @noSelf **/ +export interface Beacon extends IPeripheral { + getLevel(): number; + getPossiblePowers(): string[]; + getPowers(): object[]; + configure( + primaryPower: string, + fromInventory: string, + paymentQuery: object, + regenerationSecondary?: boolean + ): Result; +} + +/** @noSelf **/ +export interface NoteBlock extends IPeripheral { + getNote(): number; + setNote(note: number): void; + getInstrument(): string; + setInstrument(instrument: string): void; + play(): void; +} + +/** @noSelf **/ +export interface PoweredRail extends ExtendedInventoryAPI { + isPowered(): boolean; + pushMinecarts(reverse?: boolean): void; + getMinecarts(): EntityDetail[]; +} + +/** @noSelf **/ +export interface Jukebox extends IPeripheral { + getDisc(): ItemDetail | null; + replay(): void; + stop(): void; + ejectDisc(toName: string): Result; + injectDisc(fromName: string, query?: object): Result; +} + +export const lecternProvider = new IPeripheralProvider( + "minecraft:lectern" +); +export const beaconProvider = new IPeripheralProvider("minecraft:beacon"); +export const noteBlockProvider = new IPeripheralProvider( + "minecraft:note_block" +); +export const poweredRailProvider = new IPeripheralProvider( + "minecraft:powered_rail" +); +export const jukeboxProvider = new IPeripheralProvider( + "minecraft:jukebox" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts new file mode 100644 index 00000000..f9111467 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts @@ -0,0 +1,6 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface ItemPedestal extends ExtendedInventoryAPI { +} +export declare const itemPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.ts b/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.ts new file mode 100644 index 00000000..e5979262 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.ts @@ -0,0 +1,9 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface ItemPedestal extends ExtendedInventoryAPI {} + +export const itemPedestalProvider = new IPeripheralProvider( + "item_pedestal" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts new file mode 100644 index 00000000..f1369b23 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts @@ -0,0 +1,19 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Position } from "./types"; +export type MapData = { + colors: number[]; + scale: number; + banners: { + name?: string; + pos: Position; + color: string; + }[]; +}; +/** @noSelf **/ +export interface MapPedestal extends ExtendedInventoryAPI, OperationApi { + getData(): MapData; + updateData(): Result; +} +export declare const mapPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts new file mode 100644 index 00000000..5594f553 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts @@ -0,0 +1,20 @@ +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Position } from "./types"; + +export type MapData = { + colors: number[]; + scale: number; + banners: { name?: string; pos: Position; color: string }[]; +}; + +/** @noSelf **/ +export interface MapPedestal extends ExtendedInventoryAPI, OperationApi { + getData(): MapData; + updateData(): Result; +} + +export const mapPedestalProvider = new IPeripheralProvider( + "map_pedestal" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts index 2c2a2d05..1496c8bd 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts @@ -8,11 +8,14 @@ export interface NetworkManager extends ConfigurationAPI { add(group: string, peripheral: string): Result; remove(group: string, peripheral: string): Result; setGroupColor(group: string, color: number): Result; + getGroupColor(group: string): number; + setDelimiter(delimiter: string): Result; + setRange(range: number): Result; get(group: string): LuaMultiReturn; getDistanceBetween(first: string, second: string): { x: number; y: number; z: number; - }; + } | null; } export declare const networkManagerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts index 0297aeea..c2a238c4 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts @@ -9,11 +9,14 @@ export interface NetworkManager extends ConfigurationAPI { add(group: string, peripheral: string): Result; remove(group: string, peripheral: string): Result; setGroupColor(group: string, color: number): Result; + getGroupColor(group: string): number; + setDelimiter(delimiter: string): Result; + setRange(range: number): Result; get(group: string): LuaMultiReturn; getDistanceBetween( first: string, second: string - ): { x: number; y: number; z: number }; + ): { x: number; y: number; z: number } | null; } export const networkManagerProvider = new IPeripheralProvider( diff --git a/projects/typed-peripheral-unlimitedperipheralworks/package-lock.json b/projects/typed-peripheral-unlimitedperipheralworks/package-lock.json index d6285bbf..7b69ac84 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/package-lock.json +++ b/projects/typed-peripheral-unlimitedperipheralworks/package-lock.json @@ -1,12 +1,12 @@ { "name": "@siredvin/typed-peripheral-unlimitedperipheralworks", - "version": "0.1.0", + "version": "0.5.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@siredvin/typed-peripheral-unlimitedperipheralworks", - "version": "0.1.0", + "version": "0.5.0", "license": "MIT", "dependencies": { "@jackmacwindows/lua-types": "^2.13.1", diff --git a/projects/typed-peripheral-unlimitedperipheralworks/package.json b/projects/typed-peripheral-unlimitedperipheralworks/package.json index 6f98bc47..00daee02 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/package.json +++ b/projects/typed-peripheral-unlimitedperipheralworks/package.json @@ -1,6 +1,6 @@ { "name": "@siredvin/typed-peripheral-unlimitedperipheralworks", - "version": "0.4.1", + "version": "0.5.0", "description": "Typed peripheral library for UnlimitedPeripheralWorks peripherals", "files": [ "./*.d.ts", diff --git a/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts new file mode 100644 index 00000000..90ba4d40 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts @@ -0,0 +1,26 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface PeripheralHub extends IPeripheral { + getNamesRemote(): string[]; + isPresentRemote(name: string): boolean; + getTypeRemote(name: string): string | null; + hasTypeRemote(name: string, type: string): boolean; + getMethodsRemote(name: string): string[] | null; + callRemote(name: string, method: string, ...args: any[]): LuaMultiReturn; +} +/** @noSelf **/ +export interface PeripheralProxy extends PeripheralHub { + setTextStyle(value: string): Result; + setBoxStyle(value: string): Result; +} +/** @noSelf **/ +export interface PeripheraliumHub extends PeripheralHub { + isUpgrade(slot: number): boolean; + equip(slot: number): Result; + unequip(upgradeID: string): Result; + getUpgrades(): string[]; +} +export declare const peripheralProxyProvider: IPeripheralProvider; +export declare const peripheralHubProvider: IPeripheralProvider; +export declare const peripheraliumHubProvider: IPeripheralProvider; +export declare const netheritePeripheraliumHubProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.ts b/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.ts new file mode 100644 index 00000000..7fae112b --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.ts @@ -0,0 +1,36 @@ +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface PeripheralHub extends IPeripheral { + getNamesRemote(): string[]; + isPresentRemote(name: string): boolean; + getTypeRemote(name: string): string | null; + hasTypeRemote(name: string, type: string): boolean; + getMethodsRemote(name: string): string[] | null; + callRemote(name: string, method: string, ...args: any[]): LuaMultiReturn; +} + +/** @noSelf **/ +export interface PeripheralProxy extends PeripheralHub { + setTextStyle(value: string): Result; + setBoxStyle(value: string): Result; +} + +/** @noSelf **/ +export interface PeripheraliumHub extends PeripheralHub { + isUpgrade(slot: number): boolean; + equip(slot: number): Result; + unequip(upgradeID: string): Result; + getUpgrades(): string[]; +} + +export const peripheralProxyProvider = new IPeripheralProvider( + "peripheral_proxy" +); +export const peripheralHubProvider = new IPeripheralProvider( + "peripheral_hub" +); +export const peripheraliumHubProvider = + new IPeripheralProvider("peripheralium_hub"); +export const netheritePeripheraliumHubProvider = + new IPeripheralProvider("netherite_peripheralium_hub"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts new file mode 100644 index 00000000..7c6c2a7f --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts @@ -0,0 +1,22 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { BlockState, Position } from "./types"; +export type RealityFlags = { + playerPassable?: boolean; + lightPassable?: boolean; + skyLightPassable?: boolean; + invisible?: boolean; + lightLevel?: number; +}; +export type RealityBatch = [Position[], BlockState, RealityFlags?]; +/** @noSelf **/ +export interface RealityForger extends ConfigurationAPI<{ + interactionRadius: number; +}> { + detectAnchors(): Position[]; + clearAnchors(positions?: Position[]): Result; + forgeReality(blockState: BlockState, flags?: RealityFlags): Result; + forgeRealityPieces(positions: Position[], blockState: BlockState, flags?: RealityFlags): Result; + batchForgeRealityPieces(batch: RealityBatch[]): Result; +} +export declare const realityForgerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/realityForger.ts b/projects/typed-peripheral-unlimitedperipheralworks/realityForger.ts new file mode 100644 index 00000000..6530f20c --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/realityForger.ts @@ -0,0 +1,31 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { BlockState, Position } from "./types"; + +export type RealityFlags = { + playerPassable?: boolean; + lightPassable?: boolean; + skyLightPassable?: boolean; + invisible?: boolean; + lightLevel?: number; +}; + +export type RealityBatch = [Position[], BlockState, RealityFlags?]; + +/** @noSelf **/ +export interface RealityForger + extends ConfigurationAPI<{ interactionRadius: number }> { + detectAnchors(): Position[]; + clearAnchors(positions?: Position[]): Result; + forgeReality(blockState: BlockState, flags?: RealityFlags): Result; + forgeRealityPieces( + positions: Position[], + blockState: BlockState, + flags?: RealityFlags + ): Result; + batchForgeRealityPieces(batch: RealityBatch[]): Result; +} + +export const realityForgerProvider = new IPeripheralProvider( + "reality_forger" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts index 90c5768b..f5f70512 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts @@ -3,8 +3,11 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; import { EmiRecipe } from "./integrations/emi/emiRecipePaste"; /** @noSelf **/ export interface RecipeRegistry extends ConfigurationAPI { + getTypes(): string[]; get(recipeID: string): LuaTable | null; getEMI(recipeID: string): EmiRecipe | null; getRaw(recipeID: string): LuaTable | null; + list(types: string | string[]): string[]; + search(itemID: string, types: string | string[]): LuaTable[]; } export declare const recipeRegistryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.ts b/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.ts index 5f4572f9..93e4dfd0 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.ts @@ -4,9 +4,12 @@ import { EmiRecipe } from "./integrations/emi/emiRecipePaste"; /** @noSelf **/ export interface RecipeRegistry extends ConfigurationAPI { + getTypes(): string[]; get(recipeID: string): LuaTable | null; getEMI(recipeID: string): EmiRecipe | null; getRaw(recipeID: string): LuaTable | null; + list(types: string | string[]): string[]; + search(itemID: string, types: string | string[]): LuaTable[]; } export const recipeRegistryProvider = new IPeripheralProvider( diff --git a/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts new file mode 100644 index 00000000..8e12f1a5 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts @@ -0,0 +1,17 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Position } from "./types"; +export type RemoteObserverConfiguration = { + maxRange: number; + textStyle: string; + boxStyle: string; +}; +/** @noSelf **/ +export interface RemoteObserver extends ConfigurationAPI { + setTextStyle(value: string): Result; + setBoxStyle(value: string): Result; + addPosition(position: Position): Result; + removePosition(position: Position): Result; + getPositions(): Position[]; +} +export declare const remoteObserverProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.ts b/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.ts new file mode 100644 index 00000000..94ae4eaa --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.ts @@ -0,0 +1,23 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Position } from "./types"; + +export type RemoteObserverConfiguration = { + maxRange: number; + textStyle: string; + boxStyle: string; +}; + +/** @noSelf **/ +export interface RemoteObserver + extends ConfigurationAPI { + setTextStyle(value: string): Result; + setBoxStyle(value: string): Result; + addPosition(position: Position): Result; + removePosition(position: Position): Result; + getPositions(): Position[]; +} + +export const remoteObserverProvider = new IPeripheralProvider( + "remote_observer" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts index dd2c0767..99115ec0 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts @@ -1,7 +1,7 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface StatueWorkbench extends IPeripheral { - isPresent(): Boolean; + isPresent(): boolean; setStatueName(name: string): any; getStatueName(): string; setAuthor(author: string): any; @@ -14,7 +14,7 @@ export interface StatueWorkbench extends IPeripheral { } /** @noSelf **/ export declare class DummyStatueWorkbench implements StatueWorkbench { - isPresent(): Boolean; + isPresent(): boolean; setStatueName(name: string): void; getStatueName(): string; setAuthor(author: string): void; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts index 72c510cf..5f65e5d8 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts @@ -7,7 +7,7 @@ let DUMMY_CUBES = []; /** @noSelf **/ export interface StatueWorkbench extends IPeripheral { - isPresent(): Boolean; + isPresent(): boolean; setStatueName(name: string); getStatueName(): string; setAuthor(author: string); @@ -21,7 +21,7 @@ export interface StatueWorkbench extends IPeripheral { /** @noSelf **/ export class DummyStatueWorkbench implements StatueWorkbench { - isPresent(): Boolean { + isPresent(): boolean { return true; } setStatueName(name: string) { diff --git a/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts new file mode 100644 index 00000000..a94df87f --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts @@ -0,0 +1,13 @@ +import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +/** @noSelf **/ +export interface TweakedTurtle extends ExtendedInventoryAPI, EnergyStorageAPI { + turnOn(): void; + shutdown(): void; + reboot(): void; + getID(): number; + isOn(): boolean; + getLabel(): string | null; +} +export declare const tweakedTurtleProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/turtle.ts b/projects/typed-peripheral-unlimitedperipheralworks/turtle.ts new file mode 100644 index 00000000..86842474 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/turtle.ts @@ -0,0 +1,17 @@ +import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +/** @noSelf **/ +export interface TweakedTurtle extends ExtendedInventoryAPI, EnergyStorageAPI { + turnOn(): void; + shutdown(): void; + reboot(): void; + getID(): number; + isOn(): boolean; + getLabel(): string | null; +} + +export const tweakedTurtleProvider = new IPeripheralProvider( + "turtle" +); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts new file mode 100644 index 00000000..362cdfff --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts @@ -0,0 +1,10 @@ +export type Position = { + x: number; + y: number; + z: number; +}; +export type BlockState = { + name: string; + state?: LuaTable; +}; +export type EntityDetail = LuaTable & Position; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/types.ts b/projects/typed-peripheral-unlimitedperipheralworks/types.ts new file mode 100644 index 00000000..b5b8acfb --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/types.ts @@ -0,0 +1,8 @@ +export type Position = { x: number; y: number; z: number }; + +export type BlockState = { + name: string; + state?: LuaTable; +}; + +export type EntityDetail = LuaTable & Position; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts new file mode 100644 index 00000000..da0d73c0 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts @@ -0,0 +1,12 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +export type SensorInspector = "dimension" | "biome" | "weather" | "orientation" | "time" | "light" | "calendar" | "chunk"; +/** @noSelf **/ +export interface UltimateSensor extends OperationApi, ConfigurationAPI { + listAnalyzers(): string[]; + listInspectors(): SensorInspector[]; + analyze(name: "dimension"): string[]; + inspect(name: SensorInspector): any; +} +export declare const ultimateSensorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.ts b/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.ts new file mode 100644 index 00000000..cf40d038 --- /dev/null +++ b/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.ts @@ -0,0 +1,25 @@ +import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; +import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; + +export type SensorInspector = + | "dimension" + | "biome" + | "weather" + | "orientation" + | "time" + | "light" + | "calendar" + | "chunk"; + +/** @noSelf **/ +export interface UltimateSensor extends OperationApi, ConfigurationAPI { + listAnalyzers(): string[]; + listInspectors(): SensorInspector[]; + analyze(name: "dimension"): string[]; + inspect(name: SensorInspector): any; +} + +export const ultimateSensorProvider = new IPeripheralProvider( + "ultimate_sensor" +); From 0750c9c2fae4e97f58d6e47c67e82821d61a0cd8 Mon Sep 17 00:00:00 2001 From: SirEdvin Date: Sun, 26 Jul 2026 08:26:47 +0000 Subject: [PATCH 2/3] fix: align peripheral types with runtime --- .../entityLink.d.ts | 6 ++++- .../entityLink.ts | 15 ++++++++++- .../hologramProjector.d.ts | 10 +++---- .../hologramProjector.ts | 10 +++---- .../informativeRegistry.d.ts | 16 ++++++++---- .../informativeRegistry.ts | 20 ++++++++++---- .../integrations/ae2.d.ts | 15 ++++++----- .../integrations/ae2.ts | 16 +++++++----- .../integrations/arsNouveau.d.ts | 2 -- .../integrations/arsNouveau.ts | 5 ---- .../integrations/create/api.d.ts | 7 +---- .../integrations/create/api.ts | 13 +--------- .../integrations/create/filterable_api.d.ts | 6 ++--- .../integrations/create/filterable_api.ts | 6 ++--- .../integrations/deepResonance.d.ts | 3 --- .../integrations/deepResonance.ts | 7 ----- .../integrations/entityLink.d.ts | 20 +++++++------- .../integrations/entityLink.ts | 24 ++++++++--------- .../integrations/gtceu/controllable.d.ts | 3 --- .../integrations/gtceu/controllable.ts | 7 ----- .../gtceu/multiblock_machine.d.ts | 3 ++- .../integrations/gtceu/multiblock_machine.ts | 3 ++- .../integrations/occultism.d.ts | 10 ++++--- .../integrations/occultism.ts | 12 +++++---- .../integrations/powah.d.ts | 21 ++++++++++++--- .../integrations/powah.ts | 26 ++++++++++++------- .../integrations/vanilla.d.ts | 8 +++--- .../integrations/vanilla.ts | 8 +++--- .../mapPedestal.d.ts | 4 +-- .../mapPedestal.ts | 4 +-- .../networkManager.d.ts | 12 ++++++--- .../networkManager.ts | 8 +++--- .../statueWorkbench.d.ts | 10 +++---- .../statueWorkbench.ts | 10 +++---- .../types.d.ts | 1 + .../types.ts | 2 ++ 36 files changed, 193 insertions(+), 160 deletions(-) diff --git a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts index 9e14b1df..087fb84a 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts @@ -1,7 +1,11 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { FluidStorageAPI } from "@siredvin/typed-peripheral-api/fluid_storage"; +import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; import { EntityDetail } from "./types"; +import { AutomobilityAutomobileAPI, ManaAndArtificeConstructAPI } from "./integrations/entityLink"; /** @noSelf **/ -export interface EntityLink extends IPeripheral { +export interface EntityLink extends IPeripheral, Partial, Partial, Partial, Partial, Partial { isEntityFound(): boolean; inspect(): EntityDetail | null; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts index 271da5c9..5e413c4f 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.ts @@ -1,8 +1,21 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; +import { FluidStorageAPI } from "@siredvin/typed-peripheral-api/fluid_storage"; +import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; import { EntityDetail } from "./types"; +import { + AutomobilityAutomobileAPI, + ManaAndArtificeConstructAPI, +} from "./integrations/entityLink"; /** @noSelf **/ -export interface EntityLink extends IPeripheral { +export interface EntityLink + extends IPeripheral, + Partial, + Partial, + Partial, + Partial, + Partial { isEntityFound(): boolean; inspect(): EntityDetail | null; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts index f2713fcd..42cca7aa 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts @@ -1,6 +1,6 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { BlockState, Position } from "./types"; +import { BlockState, Fallible, Position } from "./types"; export type Vector3 = [number, number, number]; export type Quaternion = [number, number, number, number]; export type DisplayOptions = { @@ -38,13 +38,13 @@ export interface HologramProjector extends ConfigurationAPI<{ entityLimit: number; distanceLimit: number; }> { - item(item: object, options?: ItemDisplayOptions): string; - block(blockState: BlockState, options?: DisplayOptions): string; - text(text: object, options?: TextDisplayOptions): string; + item(item: object, options?: ItemDisplayOptions): Fallible; + block(blockState: BlockState, options?: DisplayOptions): Fallible; + text(text: object, options?: TextDisplayOptions): Fallible; destroy(uuid: string): Result; move(uuid: string, position: Position): Result; rotate(uuid: string, xRot?: number, yRot?: number): Result; - list(mode: "owned" | "around"): LuaTable; + list(mode: "owned" | "around"): Fallible>; update(uuid: string, content?: object, options?: DisplayOptions): Result; ride(riderUUID: string, mountUUID: string): Result; unmount(riderUUID: string): Result; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts index e293cbf8..1bdd1bd8 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.ts @@ -1,6 +1,6 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { BlockState, Position } from "./types"; +import { BlockState, Fallible, Position } from "./types"; export type Vector3 = [number, number, number]; export type Quaternion = [number, number, number, number]; @@ -36,13 +36,13 @@ export type ItemDisplayOptions = DisplayOptions & { item_display?: string }; /** @noSelf **/ export interface HologramProjector extends ConfigurationAPI<{ entityLimit: number; distanceLimit: number }> { - item(item: object, options?: ItemDisplayOptions): string; - block(blockState: BlockState, options?: DisplayOptions): string; - text(text: object, options?: TextDisplayOptions): string; + item(item: object, options?: ItemDisplayOptions): Fallible; + block(blockState: BlockState, options?: DisplayOptions): Fallible; + text(text: object, options?: TextDisplayOptions): Fallible; destroy(uuid: string): Result; move(uuid: string, position: Position): Result; rotate(uuid: string, xRot?: number, yRot?: number): Result; - list(mode: "owned" | "around"): LuaTable; + list(mode: "owned" | "around"): Fallible>; update(uuid: string, content?: object, options?: DisplayOptions): Result; ride(riderUUID: string, mountUUID: string): Result; unmount(riderUUID: string): Result; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts index 828b0071..88782fbc 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts @@ -1,11 +1,17 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { FluidDetail, IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface InformativeRegistry extends ConfigurationAPI { list(listName: "list" | "item" | "fluid" | "block" | "itemTags" | "fluidTags" | "blockTags" | "entityTypeTags" | "mods" | "entity"): string[]; - describe(listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string): string[]; - describe(listName: "item", id: string): ItemDetail; - describe(listName: "fluid", id: string): FluidDetail; - describe(listName: "list" | "block" | "mods" | "entity", id: string): LuaTable; + describe(listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string): string[] | null; + describe(listName: "item", id: string): (Omit & { + registryID: string; + }) | null; + describe(listName: "fluid", id: string): { + name: string; + registryID: string; + } | null; + describe(listName: "list", id: string): string | null; + describe(listName: "block" | "mods" | "entity", id: string): LuaTable | null; } export declare const informativeRegistryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts index f41724c7..a2d4eab1 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.ts @@ -1,5 +1,5 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { FluidDetail, IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface InformativeRegistry extends ConfigurationAPI { @@ -19,10 +19,20 @@ export interface InformativeRegistry extends ConfigurationAPI { describe( listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string - ): string[]; - describe(listName: "item", id: string): ItemDetail; - describe(listName: "fluid", id: string): FluidDetail; - describe(listName: "list" | "block" | "mods" | "entity", id: string): LuaTable; + ): string[] | null; + describe( + listName: "item", + id: string + ): (Omit & { registryID: string }) | null; + describe( + listName: "fluid", + id: string + ): { name: string; registryID: string } | null; + describe(listName: "list", id: string): string | null; + describe( + listName: "block" | "mods" | "entity", + id: string + ): LuaTable | null; } export const informativeRegistryProvider = diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts index 4e9e078c..734ee1c7 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts @@ -1,4 +1,4 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Fallible } from "../types"; export type AE2CraftingCPU = { name?: string; capacity: number; @@ -21,16 +21,17 @@ export interface AE2NetworkAPI extends IPeripheral { getAverageEnergyIncome(): number; getChannelEnergyDemand(): number; getChannelInformation(): { - maxChannels: number; - usedChannels: number; + maxChannels?: number; + usedChannels?: number; }; getCraftingCPUs(): AE2CraftingCPU[]; - getCraftableItems(): ItemDetail[]; + getCraftableItems(): (Omit & { + registryID: string; + })[]; getCraftableFluids(): { name: string; }[]; getPatternsFor(mode: "item" | "fluid", id: string): AE2Pattern[]; - getActiveCraftings(): AE2Crafting[]; - scheduleCrafting(mode: "item" | "fluid", id: string, amount?: number, targetCPU?: string): Result; + getActiveCraftings(): Fallible; + scheduleCrafting(mode: "item" | "fluid", id: string, amount?: number, targetCPU?: string): LuaMultiReturn<[true] | [null, string] | [false, string, LuaTable]>; } -export declare const ae2Provider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts index c5c0b31f..d587c5a8 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.ts @@ -1,4 +1,4 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Fallible } from "../types"; export type AE2CraftingCPU = { name?: string; @@ -19,18 +19,20 @@ export interface AE2NetworkAPI extends IPeripheral { getAverageEnergyDemand(): number; getAverageEnergyIncome(): number; getChannelEnergyDemand(): number; - getChannelInformation(): { maxChannels: number; usedChannels: number }; + getChannelInformation(): { maxChannels?: number; usedChannels?: number }; getCraftingCPUs(): AE2CraftingCPU[]; - getCraftableItems(): ItemDetail[]; + getCraftableItems(): (Omit & { registryID: string })[]; getCraftableFluids(): { name: string }[]; getPatternsFor(mode: "item" | "fluid", id: string): AE2Pattern[]; - getActiveCraftings(): AE2Crafting[]; + getActiveCraftings(): Fallible; scheduleCrafting( mode: "item" | "fluid", id: string, amount?: number, targetCPU?: string - ): Result; + ): LuaMultiReturn< + | [true] + | [null, string] + | [false, string, LuaTable] + >; } - -export const ae2Provider = new IPeripheralProvider("ae2"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts index 00250772..0120f91c 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts @@ -1,4 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; import { EntityDetail } from "../types"; /** @noSelf **/ export interface ArsNouveauMobJar extends IPeripheral { @@ -6,4 +5,3 @@ export interface ArsNouveauMobJar extends IPeripheral { entity: EntityDetail; } | object; } -export declare const mobJarProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts index 41d19eed..c0790b81 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.ts @@ -1,11 +1,6 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; import { EntityDetail } from "../types"; /** @noSelf **/ export interface ArsNouveauMobJar extends IPeripheral { inspect(): { entity: EntityDetail } | object; } - -export const mobJarProvider = new IPeripheralProvider( - "mob_jar" -); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts index 8220d70f..545a6fbf 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts @@ -1,5 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { CreateFilterableAPI } from "./filterable_api"; /** @noSelf **/ export interface CreateScrollOptionAPI extends IPeripheral { getScrollValue(): number; @@ -15,10 +13,7 @@ export interface CreateLinearActuatorAPI extends IPeripheral { /** @noSelf **/ export interface CreateBlazeBurnerAPI extends IPeripheral { inspect(): { - fuelType: string; + fuelType: string | null; remainingBurnTime: number; }; } -export declare const createFilterProvider: IPeripheralProvider; -export declare const createScrollProvider: IPeripheralProvider; -export declare const createProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts index f305b62e..5fab113d 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.ts @@ -1,6 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { CreateFilterableAPI } from "./filterable_api"; - /** @noSelf **/ export interface CreateScrollOptionAPI extends IPeripheral { getScrollValue(): number; @@ -14,13 +11,5 @@ export interface CreateLinearActuatorAPI extends IPeripheral { /** @noSelf **/ export interface CreateBlazeBurnerAPI extends IPeripheral { - inspect(): { fuelType: string; remainingBurnTime: number }; + inspect(): { fuelType: string | null; remainingBurnTime: number }; } - -export const createFilterProvider = - new IPeripheralProvider("create_filter"); -export const createScrollProvider = - new IPeripheralProvider("create_scroll"); -export const createProvider = new IPeripheralProvider< - CreateLinearActuatorAPI | CreateBlazeBurnerAPI ->("create"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts index 7792f897..3658288f 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts @@ -1,6 +1,6 @@ /** @noSelf **/ export declare interface CreateFilterableAPI extends IPeripheral { - getFilterName(): string; - setFilterItem(id: string): any; - clearFilterItem(): any; + getFilterName(): string | null; + setFilterItem(id: string): Result; + clearFilterItem(): Result; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.ts index 13f71768..3658288f 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.ts @@ -1,6 +1,6 @@ /** @noSelf **/ export declare interface CreateFilterableAPI extends IPeripheral { - getFilterName(): string; - setFilterItem(id: string); - clearFilterItem(); + getFilterName(): string | null; + setFilterItem(id: string): Result; + clearFilterItem(): Result; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts index 5d5a9660..c665ee46 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts @@ -1,4 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface DeepResonanceCrystal extends IPeripheral { inspect(): { @@ -17,5 +16,3 @@ export interface DeepResonanceGenerator extends IPeripheral { isActive: boolean; }; } -export declare const resonatingCrystalProvider: IPeripheralProvider; -export declare const deepResonanceGeneratorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts index 99fa0aae..3ee9ca05 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.ts @@ -1,5 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; - /** @noSelf **/ export interface DeepResonanceCrystal extends IPeripheral { inspect(): { @@ -15,8 +13,3 @@ export interface DeepResonanceCrystal extends IPeripheral { export interface DeepResonanceGenerator extends IPeripheral { inspect(): { energy: number; lastRfPerTick: number; isActive: boolean }; } - -export const resonatingCrystalProvider = - new IPeripheralProvider("resonating_crystal"); -export const deepResonanceGeneratorProvider = - new IPeripheralProvider("generator"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts index 033bf558..c1dae7ab 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts @@ -1,18 +1,20 @@ import { Position } from "../types"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ManaAndArtificeConstructAPI extends IPeripheral { - move(position: Position): Result; - store(position: Position, direction?: string): Result; - take(position: Position, direction: string | undefined, item: string, amount?: number): Result; - listCommands(): string[]; - diagnose(): LuaTable; - getCommand(): string; + move(ignored: any, position: Position): void; + store(ignored: any, position: Position, direction?: string): void; + take(ignored: any, position: Position, direction: string | undefined, item: string, amount?: number): void; + listCommands(): LuaTable; + diagnose(): string[]; + getCommand(): { + name: string; + isFinished: boolean; + isSuccess: boolean; + isStart: boolean; + }; } /** @noSelf **/ export interface AutomobilityAutomobileAPI extends IPeripheral { rotate(delta: number): void; boost(power: number, time: number): void; } -export declare const constructProvider: IPeripheralProvider; -export declare const automobileProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts index 712a2632..9547c69b 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.ts @@ -1,19 +1,24 @@ import { Position } from "../types"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ManaAndArtificeConstructAPI extends IPeripheral { - move(position: Position): Result; - store(position: Position, direction?: string): Result; + move(ignored: any, position: Position): void; + store(ignored: any, position: Position, direction?: string): void; take( + ignored: any, position: Position, direction: string | undefined, item: string, amount?: number - ): Result; - listCommands(): string[]; - diagnose(): LuaTable; - getCommand(): string; + ): void; + listCommands(): LuaTable; + diagnose(): string[]; + getCommand(): { + name: string; + isFinished: boolean; + isSuccess: boolean; + isStart: boolean; + }; } /** @noSelf **/ @@ -21,8 +26,3 @@ export interface AutomobilityAutomobileAPI extends IPeripheral { rotate(delta: number): void; boost(power: number, time: number): void; } - -export const constructProvider = - new IPeripheralProvider("construct"); -export const automobileProvider = - new IPeripheralProvider("automobile"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts index 89e8fa84..a313b761 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts @@ -1,10 +1,7 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ControllableMachine extends ConfigurationAPI { isWorkingEnabled(): boolean; setWorkingEnabled(value: boolean): void; setSuspendAfterFinish(value: boolean): void; } -export declare const controllableProvider: IPeripheralProvider; -export declare const workableProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts index 8466cf9f..e6391e77 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.ts @@ -1,5 +1,4 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface ControllableMachine extends ConfigurationAPI { @@ -7,9 +6,3 @@ export interface ControllableMachine extends ConfigurationAPI { setWorkingEnabled(value: boolean): void; setSuspendAfterFinish(value: boolean): void; } - -export const controllableProvider = new IPeripheralProvider( - "gtceu:controllable", - () => null -); -export const workableProvider = controllableProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts index 2b8cc342..977b56e4 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts @@ -1,7 +1,8 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; import { Machine } from "./machine"; +import { Fallible } from "../../types"; /** @noSelf **/ export interface MultiblockMachine extends Machine { - getPartNames(): string[]; + getPartNames(): Fallible; } export declare const multiblockMachineProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.ts index c42d1668..7b9e4a6a 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.ts @@ -1,9 +1,10 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; import { Machine } from "./machine"; +import { Fallible } from "../../types"; /** @noSelf **/ export interface MultiblockMachine extends Machine { - getPartNames(): string[]; + getPartNames(): Fallible; } export const multiblockMachineProvider = new IPeripheralProvider( diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts index c7f3e9af..f38636e7 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts @@ -1,5 +1,4 @@ import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface OccultismStorage extends ItemStorageAPI { getMaxSlots(): number; @@ -9,6 +8,11 @@ export interface OccultismStorage extends ItemStorageAPI { /** @noSelf **/ export interface OccultismGoldenBowl extends IPeripheral { isBusy(): boolean; - getCraftingInformation(): LuaTable | null; + getCraftingInformation(): { + pentacle: string; + ritual: string; + itemUseFulfilled: boolean; + sacrificeFulfilled: boolean; + leftTime: number; + } | null; } -export declare const occultismProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts index efbc03e7..9ad88a16 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.ts @@ -1,5 +1,4 @@ import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface OccultismStorage extends ItemStorageAPI { @@ -11,8 +10,11 @@ export interface OccultismStorage extends ItemStorageAPI { /** @noSelf **/ export interface OccultismGoldenBowl extends IPeripheral { isBusy(): boolean; - getCraftingInformation(): LuaTable | null; + getCraftingInformation(): { + pentacle: string; + ritual: string; + itemUseFulfilled: boolean; + sacrificeFulfilled: boolean; + leftTime: number; + } | null; } - -export const occultismProvider = - new IPeripheralProvider("occultism"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts index 5ac74f2a..5977dbec 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts @@ -1,4 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface PowahEnergyStorageAPI extends IPeripheral { getEnergyTransfer(): number; @@ -9,7 +8,23 @@ export interface PowahGeneratorAPI extends PowahEnergyStorageAPI { } /** @noSelf **/ export interface PowahReactorAPI extends PowahGeneratorAPI { - inspect(): LuaTable; + inspect(): { + autoMode: boolean; + currentCarbon: number; + maxCarbon: number; + currentRedstone: number; + maxRedstone: number; + currentUranium: number; + maxUranium: number; + uraniumConsumption: number; + energyProduction: number; + currentSolidCoolant: number; + maxSolidCoolant: number; + coolantTemp: number; + solidCoolantTemp: number; + currentTemp: number; + maxTemp: number; + }; toggleAutoMode(): void; } /** @noSelf **/ @@ -23,5 +38,3 @@ export interface PowahRedstoneControlAPI extends IPeripheral { getRedstoneMode(): string; setRedstoneMode(mode: string): void; } -export declare const powahExtraProvider: IPeripheralProvider; -export declare const powahRedstoneProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts index ab07bfda..d169448c 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.ts @@ -1,5 +1,3 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; - /** @noSelf **/ export interface PowahEnergyStorageAPI extends IPeripheral { getEnergyTransfer(): number; @@ -12,7 +10,23 @@ export interface PowahGeneratorAPI extends PowahEnergyStorageAPI { /** @noSelf **/ export interface PowahReactorAPI extends PowahGeneratorAPI { - inspect(): LuaTable; + inspect(): { + autoMode: boolean; + currentCarbon: number; + maxCarbon: number; + currentRedstone: number; + maxRedstone: number; + currentUranium: number; + maxUranium: number; + uraniumConsumption: number; + energyProduction: number; + currentSolidCoolant: number; + maxSolidCoolant: number; + coolantTemp: number; + solidCoolantTemp: number; + currentTemp: number; + maxTemp: number; + }; toggleAutoMode(): void; } @@ -28,9 +42,3 @@ export interface PowahRedstoneControlAPI extends IPeripheral { getRedstoneMode(): string; setRedstoneMode(mode: string): void; } - -export const powahExtraProvider = new IPeripheralProvider< - PowahEnergyStorageAPI | PowahGeneratorAPI | PowahReactorAPI | PowahEnderCellAPI ->("powah_extra"); -export const powahRedstoneProvider = - new IPeripheralProvider("powah_redstone"); diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts index 0ea501a8..4ab1d842 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts @@ -6,21 +6,21 @@ export interface Lectern extends IPeripheral { hasBook(): boolean; getPageCount(): number; getActivePage(): number; - setActivePage(page: number): Result; + setActivePage(page: number): void; getText(): string[]; isBookEditable(): boolean; addPage(text?: string): Result; removePage(page: number): Result; editPage(page: number, text: string): Result; ejectBook(toName: string): Result; - injectBook(fromName: string, query?: object): Result; + injectBook(fromName: string, query?: string | object): Result; } /** @noSelf **/ export interface Beacon extends IPeripheral { getLevel(): number; getPossiblePowers(): string[]; getPowers(): object[]; - configure(primaryPower: string, fromInventory: string, paymentQuery: object, regenerationSecondary?: boolean): Result; + configure(primaryPower: string, fromInventory: string, paymentQuery: string | object, regenerationSecondary?: boolean): Result; } /** @noSelf **/ export interface NoteBlock extends IPeripheral { @@ -42,7 +42,7 @@ export interface Jukebox extends IPeripheral { replay(): void; stop(): void; ejectDisc(toName: string): Result; - injectDisc(fromName: string, query?: object): Result; + injectDisc(fromName: string, query?: string | object): Result; } export declare const lecternProvider: IPeripheralProvider; export declare const beaconProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts index 979b51bb..73b7f3b1 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.ts @@ -7,14 +7,14 @@ export interface Lectern extends IPeripheral { hasBook(): boolean; getPageCount(): number; getActivePage(): number; - setActivePage(page: number): Result; + setActivePage(page: number): void; getText(): string[]; isBookEditable(): boolean; addPage(text?: string): Result; removePage(page: number): Result; editPage(page: number, text: string): Result; ejectBook(toName: string): Result; - injectBook(fromName: string, query?: object): Result; + injectBook(fromName: string, query?: string | object): Result; } /** @noSelf **/ @@ -25,7 +25,7 @@ export interface Beacon extends IPeripheral { configure( primaryPower: string, fromInventory: string, - paymentQuery: object, + paymentQuery: string | object, regenerationSecondary?: boolean ): Result; } @@ -52,7 +52,7 @@ export interface Jukebox extends IPeripheral { replay(): void; stop(): void; ejectDisc(toName: string): Result; - injectDisc(fromName: string, query?: object): Result; + injectDisc(fromName: string, query?: string | object): Result; } export const lecternProvider = new IPeripheralProvider( diff --git a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts index f1369b23..40a69b0c 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts @@ -1,7 +1,7 @@ import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Position } from "./types"; +import { Fallible, Position } from "./types"; export type MapData = { colors: number[]; scale: number; @@ -13,7 +13,7 @@ export type MapData = { }; /** @noSelf **/ export interface MapPedestal extends ExtendedInventoryAPI, OperationApi { - getData(): MapData; + getData(): Fallible; updateData(): Result; } export declare const mapPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts index 5594f553..fd2c2ce1 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.ts @@ -1,7 +1,7 @@ import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Position } from "./types"; +import { Fallible, Position } from "./types"; export type MapData = { colors: number[]; @@ -11,7 +11,7 @@ export type MapData = { /** @noSelf **/ export interface MapPedestal extends ExtendedInventoryAPI, OperationApi { - getData(): MapData; + getData(): Fallible; updateData(): Result; } diff --git a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts index 1496c8bd..8fff7295 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts @@ -1,21 +1,25 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Fallible } from "./types"; /** @noSelf **/ -export interface NetworkManager extends ConfigurationAPI { +export interface NetworkManager extends ConfigurationAPI<{ + delimiter: string; + range: number; +}> { getGroups(): string[]; addGroup(group: string): Result; removeGroup(group: string): Result; add(group: string, peripheral: string): Result; remove(group: string, peripheral: string): Result; setGroupColor(group: string, color: number): Result; - getGroupColor(group: string): number; + getGroupColor(group: string): Fallible; setDelimiter(delimiter: string): Result; setRange(range: number): Result; get(group: string): LuaMultiReturn; - getDistanceBetween(first: string, second: string): { + getDistanceBetween(first: string, second: string): Fallible<{ x: number; y: number; z: number; - } | null; + }>; } export declare const networkManagerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts index c2a238c4..5d01be51 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.ts @@ -1,22 +1,24 @@ import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; +import { Fallible } from "./types"; /** @noSelf **/ -export interface NetworkManager extends ConfigurationAPI { +export interface NetworkManager + extends ConfigurationAPI<{ delimiter: string; range: number }> { getGroups(): string[]; addGroup(group: string): Result; removeGroup(group: string): Result; add(group: string, peripheral: string): Result; remove(group: string, peripheral: string): Result; setGroupColor(group: string, color: number): Result; - getGroupColor(group: string): number; + getGroupColor(group: string): Fallible; setDelimiter(delimiter: string): Result; setRange(range: number): Result; get(group: string): LuaMultiReturn; getDistanceBetween( first: string, second: string - ): { x: number; y: number; z: number } | null; + ): Fallible<{ x: number; y: number; z: number }>; } export const networkManagerProvider = new IPeripheralProvider( diff --git a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts index 99115ec0..c34e6da0 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts @@ -2,15 +2,15 @@ import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; /** @noSelf **/ export interface StatueWorkbench extends IPeripheral { isPresent(): boolean; - setStatueName(name: string): any; + setStatueName(name: string): void; getStatueName(): string; - setAuthor(author: string): any; + setAuthor(author: string): void; getAuthor(): string; - setLightLevel(level: number): any; + setLightLevel(level: number): void; getLightLevel(): number; - setCubes(cubes: Array): any; + setCubes(cubes: Array): void; getCubes(): Array; - reset(): any; + reset(): void; } /** @noSelf **/ export declare class DummyStatueWorkbench implements StatueWorkbench { diff --git a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts index 5f65e5d8..9583222c 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.ts @@ -8,15 +8,15 @@ let DUMMY_CUBES = []; /** @noSelf **/ export interface StatueWorkbench extends IPeripheral { isPresent(): boolean; - setStatueName(name: string); + setStatueName(name: string): void; getStatueName(): string; - setAuthor(author: string); + setAuthor(author: string): void; getAuthor(): string; - setLightLevel(level: number); + setLightLevel(level: number): void; getLightLevel(): number; - setCubes(cubes: Array); + setCubes(cubes: Array): void; getCubes(): Array; - reset(); + reset(): void; } /** @noSelf **/ diff --git a/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts index 362cdfff..0fa12810 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts @@ -8,3 +8,4 @@ export type BlockState = { state?: LuaTable; }; export type EntityDetail = LuaTable & Position; +export type Fallible = LuaMultiReturn<[T] | [F, string]>; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/types.ts b/projects/typed-peripheral-unlimitedperipheralworks/types.ts index b5b8acfb..dae5e3a6 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/types.ts +++ b/projects/typed-peripheral-unlimitedperipheralworks/types.ts @@ -6,3 +6,5 @@ export type BlockState = { }; export type EntityDetail = LuaTable & Position; + +export type Fallible = LuaMultiReturn<[T] | [F, string]>; From 038190d9515b71fc562b9cdcb1d42e9717deb1ef Mon Sep 17 00:00:00 2001 From: SirEdvin Date: Sun, 26 Jul 2026 10:41:17 +0000 Subject: [PATCH 3/3] chore: ignore generated type declarations --- .../.gitignore | 3 +- .../displayPedestal.d.ts | 11 ---- .../entityLink.d.ts | 12 ----- .../events/networkManagerGroupChange.d.ts | 11 ---- .../hologramProjector.d.ts | 52 ------------------- .../informativeRegistry.d.ts | 17 ------ .../integrations/ae2.d.ts | 37 ------------- .../integrations/arsNouveau.d.ts | 7 --- .../integrations/create/api.d.ts | 19 ------- .../integrations/create/basin.d.ts | 8 --- .../integrations/create/filterable_api.d.ts | 6 --- .../integrations/create/mechanical_saw.d.ts | 7 --- .../integrations/deepResonance.d.ts | 18 ------- .../integrations/easyVillagers.d.ts | 14 ----- .../integrations/emi/base.d.ts | 28 ---------- .../integrations/emi/emiIngredientPaste.d.ts | 9 ---- .../integrations/emi/emiRecipePaste.d.ts | 15 ------ .../integrations/entityLink.d.ts | 20 ------- .../integrations/fluxController.d.ts | 35 ------------- .../integrations/gtceu/controllable.d.ts | 7 --- .../integrations/gtceu/machine.d.ts | 7 --- .../gtceu/multiblock_machine.d.ts | 8 --- .../integrations/gtceu/workable.d.ts | 9 ---- .../integrations/lantern.d.ts | 7 --- .../integrations/magicTome.d.ts | 25 --------- .../integrations/naturesCompass.d.ts | 16 ------ .../integrations/occultism.d.ts | 18 ------- .../integrations/powah.d.ts | 40 -------------- .../integrations/specializedMachines.d.ts | 22 -------- .../integrations/transmutation_table.d.ts | 13 ----- .../integrations/universalShop.d.ts | 15 ------ .../integrations/vanilla.d.ts | 51 ------------------ .../itemPedestal.d.ts | 6 --- .../mapPedestal.d.ts | 19 ------- .../networkManager.d.ts | 25 --------- .../peripheralHub.d.ts | 26 ---------- .../realityForger.d.ts | 22 -------- .../recipeRegistry.d.ts | 13 ----- .../remoteObserver.d.ts | 17 ------ .../statueWorkbench.d.ts | 28 ---------- .../turtle.d.ts | 13 ----- .../types.d.ts | 11 ---- .../ultimateSensor.d.ts | 12 ----- .../universalScanner.d.ts | 8 --- 44 files changed, 2 insertions(+), 765 deletions(-) delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/events/networkManagerGroupChange.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/basin.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/create/mechanical_saw.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/base.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiIngredientPaste.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiRecipePaste.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/machine.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/transmutation_table.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/types.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts delete mode 100644 projects/typed-peripheral-unlimitedperipheralworks/universalScanner.d.ts diff --git a/projects/typed-peripheral-unlimitedperipheralworks/.gitignore b/projects/typed-peripheral-unlimitedperipheralworks/.gitignore index 764059b9..79707304 100644 --- a/projects/typed-peripheral-unlimitedperipheralworks/.gitignore +++ b/projects/typed-peripheral-unlimitedperipheralworks/.gitignore @@ -1,2 +1,3 @@ *.lua -node_modules \ No newline at end of file +*.d.ts +node_modules diff --git a/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts deleted file mode 100644 index 6be5c96f..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/displayPedestal.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface DisplayPedestal extends IPeripheral { - getItem(): ItemDetail | null; - setItem(id: string, name?: string, nbtData?: string): Result; - isLabelRendered(): boolean; - setLabelRendered(value: boolean): void; - isItemRendered(): boolean; - setItemRendered(value: boolean): void; -} -export declare const displayPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts deleted file mode 100644 index 087fb84a..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/entityLink.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { FluidStorageAPI } from "@siredvin/typed-peripheral-api/fluid_storage"; -import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; -import { EntityDetail } from "./types"; -import { AutomobilityAutomobileAPI, ManaAndArtificeConstructAPI } from "./integrations/entityLink"; -/** @noSelf **/ -export interface EntityLink extends IPeripheral, Partial, Partial, Partial, Partial, Partial { - isEntityFound(): boolean; - inspect(): EntityDetail | null; -} -export declare const entityLinkProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/events/networkManagerGroupChange.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/events/networkManagerGroupChange.d.ts deleted file mode 100644 index 16f8623e..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/events/networkManagerGroupChange.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import * as events from "@siredvin/cc-events"; -export declare const NETWORK_MANAGER_GROUP_CHANGE = "network_manager_group_change"; -export declare class NetworkManagerGroupChangeEvent extends events.BaseEvent<[ - string, - "added" | "removed", - string -]> { - getGroup(): string; - getAction(): "added" | "removed"; - getPeripheral(): string; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts deleted file mode 100644 index 42cca7aa..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/hologramProjector.d.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { BlockState, Fallible, Position } from "./types"; -export type Vector3 = [number, number, number]; -export type Quaternion = [number, number, number, number]; -export type DisplayOptions = { - brightness?: number; - glow_color_override?: number; - interpolation_duration?: number; - start_interpolation?: number; - height?: number; - width?: number; - shadow_radius?: number; - shadow_strength?: number; - view_range?: number; - billboard?: string; - transformation?: { - scale?: Vector3; - translation?: Vector3; - left_rotation?: Quaternion; - right_rotation?: Quaternion; - }; -}; -export type TextDisplayOptions = DisplayOptions & { - line_width?: number; - background?: number; - shadow?: boolean; - see_through?: boolean; - default_background?: boolean; - text_opacity?: number; - alignment?: string; -}; -export type ItemDisplayOptions = DisplayOptions & { - item_display?: string; -}; -/** @noSelf **/ -export interface HologramProjector extends ConfigurationAPI<{ - entityLimit: number; - distanceLimit: number; -}> { - item(item: object, options?: ItemDisplayOptions): Fallible; - block(blockState: BlockState, options?: DisplayOptions): Fallible; - text(text: object, options?: TextDisplayOptions): Fallible; - destroy(uuid: string): Result; - move(uuid: string, position: Position): Result; - rotate(uuid: string, xRot?: number, yRot?: number): Result; - list(mode: "owned" | "around"): Fallible>; - update(uuid: string, content?: object, options?: DisplayOptions): Result; - ride(riderUUID: string, mountUUID: string): Result; - unmount(riderUUID: string): Result; -} -export declare const hologramProjectorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts deleted file mode 100644 index 88782fbc..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/informativeRegistry.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface InformativeRegistry extends ConfigurationAPI { - list(listName: "list" | "item" | "fluid" | "block" | "itemTags" | "fluidTags" | "blockTags" | "entityTypeTags" | "mods" | "entity"): string[]; - describe(listName: "itemTags" | "blockTags" | "fluidTags" | "entityTypeTags", tag: string): string[] | null; - describe(listName: "item", id: string): (Omit & { - registryID: string; - }) | null; - describe(listName: "fluid", id: string): { - name: string; - registryID: string; - } | null; - describe(listName: "list", id: string): string | null; - describe(listName: "block" | "mods" | "entity", id: string): LuaTable | null; -} -export declare const informativeRegistryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts deleted file mode 100644 index 734ee1c7..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/ae2.d.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { Fallible } from "../types"; -export type AE2CraftingCPU = { - name?: string; - capacity: number; - storage: number; - isBusy: boolean; -}; -export type AE2Pattern = { - inputs: object[]; - outputs: object[]; -}; -export type AE2Crafting = { - target: object; - amount: number; - progress: number; - CPU?: string; -}; -/** @noSelf **/ -export interface AE2NetworkAPI extends IPeripheral { - getAverageEnergyDemand(): number; - getAverageEnergyIncome(): number; - getChannelEnergyDemand(): number; - getChannelInformation(): { - maxChannels?: number; - usedChannels?: number; - }; - getCraftingCPUs(): AE2CraftingCPU[]; - getCraftableItems(): (Omit & { - registryID: string; - })[]; - getCraftableFluids(): { - name: string; - }[]; - getPatternsFor(mode: "item" | "fluid", id: string): AE2Pattern[]; - getActiveCraftings(): Fallible; - scheduleCrafting(mode: "item" | "fluid", id: string, amount?: number, targetCPU?: string): LuaMultiReturn<[true] | [null, string] | [false, string, LuaTable]>; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts deleted file mode 100644 index 0120f91c..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/arsNouveau.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { EntityDetail } from "../types"; -/** @noSelf **/ -export interface ArsNouveauMobJar extends IPeripheral { - inspect(): { - entity: EntityDetail; - } | object; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts deleted file mode 100644 index 545a6fbf..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/api.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** @noSelf **/ -export interface CreateScrollOptionAPI extends IPeripheral { - getScrollValue(): number; - setScrollValue(value: number): void; -} -/** @noSelf **/ -export interface CreateLinearActuatorAPI extends IPeripheral { - inspect(): { - movementSpeed: number; - isRunning: boolean; - }; -} -/** @noSelf **/ -export interface CreateBlazeBurnerAPI extends IPeripheral { - inspect(): { - fuelType: string | null; - remainingBurnTime: number; - }; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/basin.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/basin.d.ts deleted file mode 100644 index 33455f09..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/basin.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { FluidStorageAPI } from "@siredvin/typed-peripheral-api/fluid_storage"; -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { CreateFilterableAPI } from "./filterable_api"; -/** @noSelf **/ -export interface CreateBasin extends ExtendedInventoryAPI, CreateFilterableAPI, FluidStorageAPI { -} -export declare const basinProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts deleted file mode 100644 index 3658288f..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/filterable_api.d.ts +++ /dev/null @@ -1,6 +0,0 @@ -/** @noSelf **/ -export declare interface CreateFilterableAPI extends IPeripheral { - getFilterName(): string | null; - setFilterItem(id: string): Result; - clearFilterItem(): Result; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/mechanical_saw.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/mechanical_saw.d.ts deleted file mode 100644 index e3c0b4a2..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/create/mechanical_saw.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { CreateFilterableAPI } from "./filterable_api"; -/** @noSelf **/ -export interface CreateMechanicalSaw extends ExtendedInventoryAPI, CreateFilterableAPI { -} -export declare const mechanicalSawProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts deleted file mode 100644 index c665ee46..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/deepResonance.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** @noSelf **/ -export interface DeepResonanceCrystal extends IPeripheral { - inspect(): { - strength: number; - efficiency: number; - power: number; - purity: number; - glowing: boolean; - }; -} -/** @noSelf **/ -export interface DeepResonanceGenerator extends IPeripheral { - inspect(): { - energy: number; - lastRfPerTick: number; - isActive: boolean; - }; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts deleted file mode 100644 index 026345b6..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/easyVillagers.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { EntityDetail } from "../types"; -/** @noSelf **/ -export interface EasyTrader extends IPeripheral { - hasVillager(): boolean; - inspect(): EntityDetail | null; -} -/** @noSelf **/ -export interface EasyAutoTrader extends EasyTrader { - getSelectedOffer(): number; - setSelectedOffer(index: number): Result; -} -export declare const easyTraderProvider: IPeripheralProvider; -export declare const easyAutoTraderProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/base.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/base.d.ts deleted file mode 100644 index 3e7fa69e..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/base.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -export declare interface EmiEmptyIngredient { - type: "empty"; -} -export declare interface EMIMultiIngredient { - candidates: EMIIngredient[]; - amount: number; -} -export declare interface EmiTagIngredient { - type: "tag"; - key: string; - tag_type: "item" | "fluid" | "unknown"; - amount: number; -} -export declare interface EMIItemIngredient { - name: string; - count: number; - chance: number; - type: "item"; - [key: string]: any; -} -export declare interface EMIFluidIngredient { - name: string; - displayName: string; - amount: number; - chance: number; - type: "fluid"; -} -export declare type EMIIngredient = EMIItemIngredient | EMIFluidIngredient | EmiEmptyIngredient | EMIMultiIngredient | EmiTagIngredient; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiIngredientPaste.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiIngredientPaste.d.ts deleted file mode 100644 index c21b58e0..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiIngredientPaste.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import * as events from "@siredvin/cc-events"; -import { EMIFluidIngredient, EMIItemIngredient } from "./base"; -export declare const EMI_INGREDIENT_PASTE = "emi_ingredient_paste"; -export declare class EmiIngredientPasteEvent extends events.BaseEvent<[ - EMIItemIngredient | EMIFluidIngredient -]> { - getIngridient(): EMIItemIngredient | EMIFluidIngredient; - static create(ingredient: EMIItemIngredient | EMIFluidIngredient): EmiIngredientPasteEvent; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiRecipePaste.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiRecipePaste.d.ts deleted file mode 100644 index d44ab374..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/emi/emiRecipePaste.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import * as events from "@siredvin/cc-events"; -import { EMIIngredient } from "./base"; -export declare const EMI_RECIPE_PASTE = "emi_recipe_paste"; -export declare interface EmiRecipe { - inputs: EMIIngredient[]; - outputs: EMIIngredient[]; - catalysts: EMIIngredient[]; - category: string; - extra?: object; - id: string; -} -export declare class EMIRecipePasteEvent extends events.BaseEvent<[EmiRecipe]> { - getRecipe(): EmiRecipe; - static create(recipe: EmiRecipe): EMIRecipePasteEvent; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts deleted file mode 100644 index c1dae7ab..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/entityLink.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Position } from "../types"; -/** @noSelf **/ -export interface ManaAndArtificeConstructAPI extends IPeripheral { - move(ignored: any, position: Position): void; - store(ignored: any, position: Position, direction?: string): void; - take(ignored: any, position: Position, direction: string | undefined, item: string, amount?: number): void; - listCommands(): LuaTable; - diagnose(): string[]; - getCommand(): { - name: string; - isFinished: boolean; - isSuccess: boolean; - isStart: boolean; - }; -} -/** @noSelf **/ -export interface AutomobilityAutomobileAPI extends IPeripheral { - rotate(delta: number): void; - boost(power: number, time: number): void; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts deleted file mode 100644 index fbd1c5ad..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/fluxController.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -export type FluxConnection = { - customName: string; - maxTransferLimit: number; - transferBuffer: number; - transferChange: number; - surgeMode: boolean; - deviceType: string; - isChunkLoaded: boolean; -}; -export type FluxNetwork = { - name: string; - id: number; - color: number; - securityLevel: string; -}; -export type FluxStatistics = { - controllerCount: number; - pointCount: number; - plugCount: number; - storageCount: number; - totalBuffer: number; - totalEnergy: number; - energyInput: number; - energyOutput: number; - averageTick: number; -}; -/** @noSelf **/ -export interface FluxController extends EnergyStorageAPI { - getConnections(): FluxConnection[]; - getNetwork(): FluxNetwork; - getStatistic(): FluxStatistics; -} -export declare const fluxControllerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts deleted file mode 100644 index a313b761..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/controllable.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -/** @noSelf **/ -export interface ControllableMachine extends ConfigurationAPI { - isWorkingEnabled(): boolean; - setWorkingEnabled(value: boolean): void; - setSuspendAfterFinish(value: boolean): void; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/machine.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/machine.d.ts deleted file mode 100644 index 0332d551..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/machine.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface Machine extends ConfigurationAPI { - getRecipeTypes(): string[]; -} -export declare const machineProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts deleted file mode 100644 index 977b56e4..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/multiblock_machine.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Machine } from "./machine"; -import { Fallible } from "../../types"; -/** @noSelf **/ -export interface MultiblockMachine extends Machine { - getPartNames(): Fallible; -} -export declare const multiblockMachineProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts deleted file mode 100644 index 7a3910ee..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/gtceu/workable.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface WorkableMachine extends ConfigurationAPI { - getProgress(): number; - getMaxProgress(): number; - isActive(): boolean; -} -export declare const workableProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts deleted file mode 100644 index 7ea991f7..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/lantern.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface Lantern extends IPeripheral { - isEnabled(): boolean; - toggle(): Result; -} -export declare const lanternProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts deleted file mode 100644 index a494786c..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/magicTome.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -export type SpellDetail = { - name: string; - display: string; - color: number; - sound?: string; - cost: number; -}; -export type ManaDetail = { - current: number; - max: number; - bookTier: number; - glyphBonus: number; -}; -/** @noSelf **/ -export interface MagicTome extends IPeripheral { - getSpells(): LuaTable; - getSelectedSlot(): number; - size(): number; - getSelectedSpell(): SpellDetail; - select(slot: number): void; - getMana(): ManaDetail; - cast(): void; -} -export declare const magicTomeProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts deleted file mode 100644 index f67c5f94..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/naturesCompass.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -export type NatureCompassResult = { - x: number; - z: number; - distance: number; - biome: string; -}; -/** @noSelf **/ -export interface NaturesCompass extends ConfigurationAPI { - getBiomes(): string[]; - scheduleSearch(biome: string): Result; - getState(): string; - getResult(): NatureCompassResult | null; -} -export declare const naturesCompassProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts deleted file mode 100644 index f38636e7..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/occultism.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { ItemStorageAPI } from "@siredvin/typed-peripheral-api/item_storage"; -/** @noSelf **/ -export interface OccultismStorage extends ItemStorageAPI { - getMaxSlots(): number; - getUsedSlots(): number; - isBlacklisted(itemID: string): boolean; -} -/** @noSelf **/ -export interface OccultismGoldenBowl extends IPeripheral { - isBusy(): boolean; - getCraftingInformation(): { - pentacle: string; - ritual: string; - itemUseFulfilled: boolean; - sacrificeFulfilled: boolean; - leftTime: number; - } | null; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts deleted file mode 100644 index 5977dbec..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/powah.d.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** @noSelf **/ -export interface PowahEnergyStorageAPI extends IPeripheral { - getEnergyTransfer(): number; -} -/** @noSelf **/ -export interface PowahGeneratorAPI extends PowahEnergyStorageAPI { - getEnergyGeneration(): number; -} -/** @noSelf **/ -export interface PowahReactorAPI extends PowahGeneratorAPI { - inspect(): { - autoMode: boolean; - currentCarbon: number; - maxCarbon: number; - currentRedstone: number; - maxRedstone: number; - currentUranium: number; - maxUranium: number; - uraniumConsumption: number; - energyProduction: number; - currentSolidCoolant: number; - maxSolidCoolant: number; - coolantTemp: number; - solidCoolantTemp: number; - currentTemp: number; - maxTemp: number; - }; - toggleAutoMode(): void; -} -/** @noSelf **/ -export interface PowahEnderCellAPI extends PowahEnergyStorageAPI { - getChannel(): number; - setChannel(channel: number): void; - getMaxChannel(): number; -} -/** @noSelf **/ -export interface PowahRedstoneControlAPI extends IPeripheral { - getRedstoneMode(): string; - setRedstoneMode(mode: string): void; -} diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts deleted file mode 100644 index 1f689a41..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/specializedMachines.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface ModernIndustrializationCrafter extends IPeripheral { - isBusy(): boolean; - getCraftingInformation(): { - progress: number; - currentEfficiency: number; - maxEfficiency: number; - baseRecipeCost: number; - currentRecipeCost: number; - } | object; -} -/** @noSelf **/ -export interface AlloyForgeryController extends IPeripheral { - inspect(): { - fuel: number; - currentSmeltTime: number; - smeltProgress: number; - }; -} -export declare const miCrafterProvider: IPeripheralProvider; -export declare const alloyForgeryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/transmutation_table.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/transmutation_table.d.ts deleted file mode 100644 index ec14adea..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/transmutation_table.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { InventoryViewAPI } from "@siredvin/typed-peripheral-api/inventory_view"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface TransmutationTable extends ConfigurationAPI, InventoryViewAPI { - getAvailableItems(): (ItemDetail & { - EMC: number; - })[]; - getEMC(): number; - syntize(id: string, amount: number): Result; - transmute(slot: number): Result; -} -export declare const transmutationTableProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts deleted file mode 100644 index bd3d7582..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/universalShop.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -export type ShopItemSetting = { - type: string; - price?: ItemDetail; -}; -/** @noSelf **/ -export interface UniversalShop extends IPeripheral { - getHologramMode(): string; - setHologramMode(mode: string): void; - getPrice(): ShopItemSetting; - setPrice(type: "free" | "single_item", itemHint?: object): Result; - getStock(): ShopItemSetting; - setStock(type: "selected_item" | "single_item", itemHint?: object): Result; -} -export declare const universalShopProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts deleted file mode 100644 index 4ab1d842..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/integrations/vanilla.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { EntityDetail } from "../types"; -/** @noSelf **/ -export interface Lectern extends IPeripheral { - hasBook(): boolean; - getPageCount(): number; - getActivePage(): number; - setActivePage(page: number): void; - getText(): string[]; - isBookEditable(): boolean; - addPage(text?: string): Result; - removePage(page: number): Result; - editPage(page: number, text: string): Result; - ejectBook(toName: string): Result; - injectBook(fromName: string, query?: string | object): Result; -} -/** @noSelf **/ -export interface Beacon extends IPeripheral { - getLevel(): number; - getPossiblePowers(): string[]; - getPowers(): object[]; - configure(primaryPower: string, fromInventory: string, paymentQuery: string | object, regenerationSecondary?: boolean): Result; -} -/** @noSelf **/ -export interface NoteBlock extends IPeripheral { - getNote(): number; - setNote(note: number): void; - getInstrument(): string; - setInstrument(instrument: string): void; - play(): void; -} -/** @noSelf **/ -export interface PoweredRail extends ExtendedInventoryAPI { - isPowered(): boolean; - pushMinecarts(reverse?: boolean): void; - getMinecarts(): EntityDetail[]; -} -/** @noSelf **/ -export interface Jukebox extends IPeripheral { - getDisc(): ItemDetail | null; - replay(): void; - stop(): void; - ejectDisc(toName: string): Result; - injectDisc(fromName: string, query?: string | object): Result; -} -export declare const lecternProvider: IPeripheralProvider; -export declare const beaconProvider: IPeripheralProvider; -export declare const noteBlockProvider: IPeripheralProvider; -export declare const poweredRailProvider: IPeripheralProvider; -export declare const jukeboxProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts deleted file mode 100644 index f9111467..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/itemPedestal.d.ts +++ /dev/null @@ -1,6 +0,0 @@ -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface ItemPedestal extends ExtendedInventoryAPI { -} -export declare const itemPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts deleted file mode 100644 index 40a69b0c..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/mapPedestal.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Fallible, Position } from "./types"; -export type MapData = { - colors: number[]; - scale: number; - banners: { - name?: string; - pos: Position; - color: string; - }[]; -}; -/** @noSelf **/ -export interface MapPedestal extends ExtendedInventoryAPI, OperationApi { - getData(): Fallible; - updateData(): Result; -} -export declare const mapPedestalProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts deleted file mode 100644 index 8fff7295..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/networkManager.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Fallible } from "./types"; -/** @noSelf **/ -export interface NetworkManager extends ConfigurationAPI<{ - delimiter: string; - range: number; -}> { - getGroups(): string[]; - addGroup(group: string): Result; - removeGroup(group: string): Result; - add(group: string, peripheral: string): Result; - remove(group: string, peripheral: string): Result; - setGroupColor(group: string, color: number): Result; - getGroupColor(group: string): Fallible; - setDelimiter(delimiter: string): Result; - setRange(range: number): Result; - get(group: string): LuaMultiReturn; - getDistanceBetween(first: string, second: string): Fallible<{ - x: number; - y: number; - z: number; - }>; -} -export declare const networkManagerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts deleted file mode 100644 index 90ba4d40..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/peripheralHub.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface PeripheralHub extends IPeripheral { - getNamesRemote(): string[]; - isPresentRemote(name: string): boolean; - getTypeRemote(name: string): string | null; - hasTypeRemote(name: string, type: string): boolean; - getMethodsRemote(name: string): string[] | null; - callRemote(name: string, method: string, ...args: any[]): LuaMultiReturn; -} -/** @noSelf **/ -export interface PeripheralProxy extends PeripheralHub { - setTextStyle(value: string): Result; - setBoxStyle(value: string): Result; -} -/** @noSelf **/ -export interface PeripheraliumHub extends PeripheralHub { - isUpgrade(slot: number): boolean; - equip(slot: number): Result; - unequip(upgradeID: string): Result; - getUpgrades(): string[]; -} -export declare const peripheralProxyProvider: IPeripheralProvider; -export declare const peripheralHubProvider: IPeripheralProvider; -export declare const peripheraliumHubProvider: IPeripheralProvider; -export declare const netheritePeripheraliumHubProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts deleted file mode 100644 index 7c6c2a7f..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/realityForger.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { BlockState, Position } from "./types"; -export type RealityFlags = { - playerPassable?: boolean; - lightPassable?: boolean; - skyLightPassable?: boolean; - invisible?: boolean; - lightLevel?: number; -}; -export type RealityBatch = [Position[], BlockState, RealityFlags?]; -/** @noSelf **/ -export interface RealityForger extends ConfigurationAPI<{ - interactionRadius: number; -}> { - detectAnchors(): Position[]; - clearAnchors(positions?: Position[]): Result; - forgeReality(blockState: BlockState, flags?: RealityFlags): Result; - forgeRealityPieces(positions: Position[], blockState: BlockState, flags?: RealityFlags): Result; - batchForgeRealityPieces(batch: RealityBatch[]): Result; -} -export declare const realityForgerProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts deleted file mode 100644 index f5f70512..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/recipeRegistry.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { EmiRecipe } from "./integrations/emi/emiRecipePaste"; -/** @noSelf **/ -export interface RecipeRegistry extends ConfigurationAPI { - getTypes(): string[]; - get(recipeID: string): LuaTable | null; - getEMI(recipeID: string): EmiRecipe | null; - getRaw(recipeID: string): LuaTable | null; - list(types: string | string[]): string[]; - search(itemID: string, types: string | string[]): LuaTable[]; -} -export declare const recipeRegistryProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts deleted file mode 100644 index 8e12f1a5..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/remoteObserver.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -import { Position } from "./types"; -export type RemoteObserverConfiguration = { - maxRange: number; - textStyle: string; - boxStyle: string; -}; -/** @noSelf **/ -export interface RemoteObserver extends ConfigurationAPI { - setTextStyle(value: string): Result; - setBoxStyle(value: string): Result; - addPosition(position: Position): Result; - removePosition(position: Position): Result; - getPositions(): Position[]; -} -export declare const remoteObserverProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts deleted file mode 100644 index c34e6da0..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/statueWorkbench.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface StatueWorkbench extends IPeripheral { - isPresent(): boolean; - setStatueName(name: string): void; - getStatueName(): string; - setAuthor(author: string): void; - getAuthor(): string; - setLightLevel(level: number): void; - getLightLevel(): number; - setCubes(cubes: Array): void; - getCubes(): Array; - reset(): void; -} -/** @noSelf **/ -export declare class DummyStatueWorkbench implements StatueWorkbench { - isPresent(): boolean; - setStatueName(name: string): void; - getStatueName(): string; - setAuthor(author: string): void; - getAuthor(): string; - setLightLevel(level: number): void; - getLightLevel(): number; - setCubes(cubes: Cube[]): void; - getCubes(): Cube[]; - reset(): void; -} -export declare const statueWorkbenchProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts deleted file mode 100644 index a94df87f..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/turtle.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { EnergyStorageAPI } from "@siredvin/typed-peripheral-api/energy_storage"; -import { ExtendedInventoryAPI } from "@siredvin/typed-peripheral-api/inventory_extended"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface TweakedTurtle extends ExtendedInventoryAPI, EnergyStorageAPI { - turnOn(): void; - shutdown(): void; - reboot(): void; - getID(): number; - isOn(): boolean; - getLabel(): string | null; -} -export declare const tweakedTurtleProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts deleted file mode 100644 index 0fa12810..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/types.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -export type Position = { - x: number; - y: number; - z: number; -}; -export type BlockState = { - name: string; - state?: LuaTable; -}; -export type EntityDetail = LuaTable & Position; -export type Fallible = LuaMultiReturn<[T] | [F, string]>; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts deleted file mode 100644 index da0d73c0..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/ultimateSensor.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -export type SensorInspector = "dimension" | "biome" | "weather" | "orientation" | "time" | "light" | "calendar" | "chunk"; -/** @noSelf **/ -export interface UltimateSensor extends OperationApi, ConfigurationAPI { - listAnalyzers(): string[]; - listInspectors(): SensorInspector[]; - analyze(name: "dimension"): string[]; - inspect(name: SensorInspector): any; -} -export declare const ultimateSensorProvider: IPeripheralProvider; diff --git a/projects/typed-peripheral-unlimitedperipheralworks/universalScanner.d.ts b/projects/typed-peripheral-unlimitedperipheralworks/universalScanner.d.ts deleted file mode 100644 index 890a338d..00000000 --- a/projects/typed-peripheral-unlimitedperipheralworks/universalScanner.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { ConfigurationAPI } from "@siredvin/typed-peripheral-api/configuration"; -import { OperationApi } from "@siredvin/typed-peripheral-api/operations"; -import { ScanApi } from "@siredvin/typed-peripheral-api/scan"; -import { IPeripheralProvider } from "@siredvin/typed-peripheral-base"; -/** @noSelf **/ -export interface UniversalScanner extends ScanApi, OperationApi, ConfigurationAPI { -} -export declare const universalScannerProvider: IPeripheralProvider;