EN Runtime API 04 Gumps and Menus - LIHACHTETAN/ClassicUO-Bad-Newbie-CSharp-Scripts-IDE GitHub Wiki

Українська · Русский · English · Deutsch · Français · Italiano · Español · 繁體中文 · 日本語 · 한국어

Runtime API - Gumps and menus

Home · C# · IDE · UO API · A–Z · Examples · Languages

Each team opens a card with C#-signatures, parameters and several independent examples.

UO.AutoMenu

Menus & Context Menus

Registers a persistent menu hook: when a server menu with a suitable caption appears, the client selects the appropriate item. The call does not open the menu and does not wait for it synchronously.

UO.CancelAllMenuHooks

Menus & Context Menus

Removes all registered automatic hooks from old client server menus.

UO.CancelGump

Gump windows

Closes the selected server gump via a compatible resolver CloseSimpleGump.

UO.CancelMenu

Menus & Context Menus

Removes all registered automatic hooks from old client server menus.

UO.CloseClientGump

Gump windows

Removes local server gumps whose ServerSerial matches the passed ID.

UO.CloseMenu

Menus & Context Menus

Cancels all active old server menus via CancelForYoko.

UO.CloseSimpleGump

Client UI

Locally closes a server gump that is allowed to be closed by a strict index.

UO.GetGump

Gump windows

Reads one field of the selected server gump. Allows you to explicitly set the window selector.

UO.GetGumpButtonsDescription

Gump windows

Returns descriptions of regular server gump buttons.

UO.GetGumpCount

Gump windows

Short version GetGumpsCount: number of active server gumps.

UO.GetGumpFullLines

Gump windows

Returns descriptions of all living elements, including nested server gumps.

UO.GetGumpID

Gump windows

Reads the GumpID window type ID from the server gump index.

UO.GetGumpInfo

Gump windows

Returns a consistent snapshot of the identifiers and elements of a single server gump.

UO.GetGumpsCount

Gump windows

Returns the number of active server gumps.

UO.GetGumpSerial

Gump windows

Reads the serial of the window instance/owner by the server gump index.

UO.GetGumpShortLines

Gump windows

Returns descriptions of text elements and buttons of the server gump.

UO.GetLastMenuItems

Menus & Context Menus

Reads the items of the already open old server menu.

UO.GetMenuItems

Menus & Context Menus

Reads the items of the already open old server menu.

UO.GetMenuItemsEx

Menus & Context Menus

Reads the items of the already open old server menu.

UO.GumpAutoCheckBox

Gump windows

Sets the value of the element once in the first suitable server gump; if the element does not exist yet, saves the wait.

UO.GumpAutoRadiobutton

Gump windows

Sets the value of the element once in the first suitable server gump; if the element does not exist yet, saves the wait.

UO.GumpExists

Gump windows

Checks for the presence of a server gump using one selector or an exact serial/GumpID pair.

UO.GumpObject

Gump windows

Selects an existing server gump for subsequent calls.

UO.InfoGump

Diagnostics & Introspection

Opens a detailed inspector of the server window: GumpID, Serial, position, dimensions, pages, buttons and ButtonID, text, input fields and radio buttons. Without an argument, the previously selected or last active server gump is selected. The argument is resolved by GumpID/serial, then by list index. Only -1 means selected/last window; other negative int retain the 32-bit ID, such as 0x87654321. The inspected window becomes selected for SendGumpSelect(buttonId). If there is no suitable window, the client reports this; the command does not return anything.

UO.InfoGumps

Diagnostics & Introspection

Without an argument, opens a list of active server windows, their indexes, GumpID, serial and sizes. Client interior windows are not included in this list. The form InfoGumps(gump) opens the detailed inspector of the specified window, like InfoGump(gump). The list reflects the status at the time of opening.

UO.IsGump

Gump windows

Checks if there is at least one active server gump.

UO.IsGumpCanBeClosed

Gump windows

Checks whether local right-click closing of server gump is allowed.

UO.LastGump

Gump windows

Reads one field of the selected server gump. Uses the window selected by this script or the last element of the current list.

UO.MenuHookPresent

Menus & Context Menus

Reads the presence of registered menu hooks.

UO.MenuPresent

Menus & Context Menus

MenuPresent directly calls WaitingMenu.

UO.NumGumpButton

Gump windows

Activates an existing server gump button based on the strict window index and exact ButtonID.

UO.NumGumpCheckBox

Gump windows

Sets the state of the flag in the server gump by index.

UO.NumGumpRadiobutton

Gump windows

Sets the state of a radio button in a server gump by index.

UO.ReqVirtuesGump

Quests & Virtues

Requests a character's virtues window.

UO.SelectGump

Gump windows

Selects an existing server gump for subsequent calls.

UO.SendGumpSelect

Gump windows

Sends the ButtonID for the selected server gump.

UO.SetGump

Gump windows

Changes the field of an existing server gump.

UO.WaitGump

Gump windows

Registers a sequence of one-time responses to buttons. The script continues running immediately; the absence of a window does not cause a 30-second delay.

UO.WaitGumpCheck

Gump windows

Changes up to three checkbox fields of the current gump.

UO.WaitGumpEntry

Gump windows

Changes up to three textentry fields of the current gump.

UO.WaitingForMenu

Menus & Context Menus

The required number of server menu appearances is limited.

UO.WaitingMenu

Menus & Context Menus

Reads _world.ServerMenus.Snapshot().Length != 0.

UO.WaitMenu

Menus & Context Menus

Registers up to three one-time menu hooks.