# GoldScreen Methods to interact with the gold‑crafting **Gold Screen** interface. ```{figure} ../../images/goldscreen_interface.png ``` ```{note} Credits to Flight and Skunkworks ``` - - - (EGoldItem)= ## EGoldItem enum ```pascal EGoldItem = enum(GOLD_RING..ZENYTE_BRACELET); ``` Enum of all jewellery items that can be crafted on the {ref}`GoldScreen`. - - - (TGoldScreen)= ## TGoldScreen type Main record to interact with the {ref}`GoldScreen` interface. - - - ## GoldScreen.SetupInterface ```pascal procedure TGoldScreen.SetupInterface(); ``` Internal method used to setup the {ref}`TGoldScreen` coordinates. Automatically called for you on the `GoldScreen` variable. - - - ## GoldScreen.IsOpen ```pascal function TGoldScreen.IsOpen(): Boolean; ``` Returns `True` if the gold‑crafting interface is visible. - - - ## GoldScreen.WaitOpen ```pascal function TGoldScreen.WaitOpen( time: Integer = TICK; interval: Integer = -1 ): Boolean; ``` Waits up to `time` ms for the interface to appear. - - - ## GoldScreen.Close ```pascal function TGoldScreen.Close(PressEscape: Boolean = False): Boolean; function TGoldScreen.Close(escapeProbability: Single = -1): Boolean; overload; ``` Closes the interface via its close button or by pressing **Escape**. - - - ## GoldScreen.SetQuantity ```pascal function TGoldScreen.SetQuantity(amount: Integer): Boolean; ``` Selects the desired quantity button (1/5/10/X/All). Pass `0` or any negative value for "All". - - - ## GoldScreen.CanCraft ```pascal function TGoldScreen.CanCraft(Item: EGoldItem): Boolean; ``` Returns `True` if the given item icon is available for crafting. - - - ## GoldScreen.IsHighlighted ```pascal function TGoldScreen.IsHighlighted(Item: EGoldItem): Boolean; ``` Returns `True` if the given item is currently highlighted. - - - ## GoldScreen.CraftItem ```pascal function TGoldScreen.CraftItem( gold: EGoldItem; amount: Integer; useSpace: Boolean ): Boolean; function TGoldScreen.CraftItem( gold: EGoldItem; amount: Integer = QUANTITY_ALL; spaceProbability: Single = -1 ): Boolean; overload; ``` Sets the `amount` then crafts the requested item. If `useSpace = True` and the item is highlighted it presses **Space**, otherwise it clicks the item icon. - - - ## GoldScreen variable Global {ref}`TGoldScreen` variable.