From 91108d392c4c5800204dd4674ce9247495ac98e0 Mon Sep 17 00:00:00 2001 From: Vitaly Date: Sat, 6 Jan 2024 22:57:09 +0530 Subject: [PATCH] Add `maxCatchupTicks`, improve `supportFeature` typing (#3277) --- index.d.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/index.d.ts b/index.d.ts index be8fd1158..18c6416b9 100644 --- a/index.d.ts +++ b/index.d.ts @@ -10,6 +10,7 @@ import { Entity } from 'prismarine-entity' import { ChatMessage } from 'prismarine-chat' import { world } from 'prismarine-world' import { Registry } from 'prismarine-registry' +import { IndexedData } from 'minecraft-data' export function createBot (options: { client: Client } & Partial): Bot export function createBot (options: BotOptions): Bot @@ -26,6 +27,8 @@ export interface BotOptions extends ClientOptions { difficulty?: number chatLengthLimit?: number physicsEnabled?: boolean + /** @default 4 */ + maxCatchupTicks?: number client?: Client brand?: string defaultChatPatterns?: boolean @@ -204,7 +207,7 @@ export interface Bot extends TypedEmitter { connect: (options: BotOptions) => void - supportFeature: (feature: string) => boolean + supportFeature: IndexedData['supportFeature'] end: (reason?: string) => void