From 8898d0af567ef416ec2f0432f3ba729097058ba4 Mon Sep 17 00:00:00 2001 From: Sadret Date: Fri, 18 Feb 2022 21:59:44 +0100 Subject: [PATCH] Close #16251: Adjust openrct2.d.ts to actual API implementation --- distribution/changelog.txt | 3 +++ distribution/openrct2.d.ts | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/distribution/changelog.txt b/distribution/changelog.txt index 98b13687cd..4c7c4a01b7 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -18,6 +18,9 @@ - Improved: [#10664, #16072] Visibility status can be modified directly in the Tile Inspector's list. - Improved: [#16251] Plugin API handles null values better. - Improved: [#16251] openrct2.d.ts: mark 'callback' argument of queryAction and executeAction as optional. +- Improved: [#16251] openrct2.d.ts: change 'network.status' to 'network.mode' in network API docs. +- Improved: [#16251] openrct2.d.ts: added previously undocumented GroupBoxWidget.text property. +- Improved: [#16251] openrct2.d.ts: removed unused LabelWidget.onChange property. - Improved: [#16258] Increased image limit in the engine. - Improved: [#16408] Improve --version cli option to report more compatibility information. - Change: [#16077] When importing SV6 files, the RCT1 land types are only added when they were actually used. diff --git a/distribution/openrct2.d.ts b/distribution/openrct2.d.ts index 2ce5e01f6b..cf8ef865af 100644 --- a/distribution/openrct2.d.ts +++ b/distribution/openrct2.d.ts @@ -1529,7 +1529,7 @@ declare global { /** * Network APIs - * Use `network.status` to determine whether the current game is a client, server or in single player mode. + * Use `network.mode` to determine whether the current game is a client, server or in single player mode. */ interface Network { readonly mode: NetworkMode; @@ -2291,13 +2291,13 @@ declare global { interface GroupBoxWidget extends WidgetBase { type: "groupbox"; + text?: string; } interface LabelWidget extends WidgetBase { type: "label"; text?: string; textAlign?: TextAlignment; - onChange?: (index: number) => void; } type TextAlignment = "left" | "centred";