# RSClient Methods relating to targeting the RS client and detecting client states. - - - ## ERSClient ```pascal ERSClient = enum(UNKNOWN, LEGACY, RUNELITE, OFFICIAL); ``` Enum that represent the client type. - - - ## ERSMode ```pascal ERSMode = enum(UNKNOWN, FIXED, RESIZABLE_CLASSIC, RESIZABLE_MODERN); ``` Enum that represent the client mode. - - - ## ERSPopoutPanel ```pascal ERSPopoutPanel = enum(UNKNOWN, DISABLED, ENABLED); ``` Enum that represent the state of the popout panel on the official client. - - - ## TRSClient Record representing the RuneScape client ({ref}`RSClient`. - - - ## RSClient.GetClient ```pascal function TRSClient.GetClient(): ERSClient; ``` Returns the client type being used. Example: ```pascal WriteLn RSClient.GetClient(); ``` - - - ## RSClient._Bounds ```pascal function TRSClient._Bounds(img: TImage): TBox; function TRSClient._Bounds(): TBox; overload; ``` Internal helper methods to figure out the client bounds when we are on the `ERSClient.OFFICIAL` client. You should never have to use this directly. Example: ```pascal ShowOnTarget(RSClient._Bounds()); ``` - - - ## RSClient.GetPopoutPanelState ```pascal function TRSClient.GetPopoutPanelState(img: TImage): ERSPopoutPanel; function TRSClient.GetPopoutPanelState(): ERSPopoutPanel; overload; ``` Internal helper methods to figure out if the "Popout" panel is open or not when we are on the `ERSClient.OFFICIAL` client. You should never have to use this directly. Example: ```pascal WriteLn RSClient.GetPopoutPanelState(); ``` - - - ## RSClient.Bounds ```pascal property TRSClient.Bounds: TBox; ``` Dynamic client bounds to handle different client quirks. Example: ```pascal ShowOnTarget(RSClient.Bounds); ``` - - - ## RSClient.GetMode ```pascal function TRSClient.GetMode(): ERSMode; ``` Returns the client mode. Example: ```pascal WriteLn RSClient.GetMode(); ``` - - - ## RSClient.ModeChanged ```pascal function TRSClient.ModeChanged(): Boolean; ``` Returns true if the client mode changed. - - - ## RSClient.WaitModeChange ```pascal function TRSClient.WaitModeChange(time: Integer = 600; interval: Integer = -1): Boolean; ``` Waits `time` milliseconds for the client mode to change - - - ## RSClient.IsLoggedIn ```pascal function TRSClient.IsLoggedIn(): Boolean; ``` Returns true/false whether there's a player logged in or not. Example: ```pascal WriteLn RSClient.IsLoggedIn(); ``` - - - ## RSClient.WaitLoggedIn ```pascal function TRSClient.WaitLoggedIn(time: Integer = 2000; interval: Integer = -1): Boolean; ``` Waits `time` milliseconds for the players to be logged in. Example: ```pascal WriteLn RSClient.WaitLoggedIn(); ``` - - - ## RSClient variable Global {ref}`TRSClient` variable.