Logout

The file holds functions and procedures that are in the logout-tab.


type TRSLogoutWS

Type that holds the methods for the in-game worldswitcher located on the logout tab


type TRSLogout

The type that holds functions and properties of the Runescape logout-tab.


var Logout

Variable that stores functions and properties of the Runescape logout interface.


Logout.Open

function TRSLogout.Open(): Boolean;

Opens the interface


Logout.IsOpen

function TRSLogout.IsOpen(Tab:ELogoutSubtab=lsTabNone; maxWait:Int32=0): Boolean;

Checks if the interface is already open. Can also be used to check if a specific “subtab” is open.


Logout.ClickLogout

function TRSLogout.ClickLogout(attemts:Int32=3; tryTime:Int32=20000): Boolean;

Clicks the logout button, by default retires 3 times over 20 seconds.


Logout.SwitchToWorld

function TRSLogout.SwitchToWorld(World: Integer): Boolean;

Jumps to the given world.


Logout.WorldSwitcher.GetCurrentWorld

function TRSLogoutWS.GetCurrentWorld: Int32;

Reads and returns the current world.


Logout.WorldSwitcher.isOpen

function TRSLogoutWS.isOpen: Boolean;
function TRSLogoutWS.IsOpen(WaitTime: Int32): Boolean; overload;

Returns if the in-game worldswitcher is open. Optional overload to wait up to WaitTime for worldswitcher to be open.


Logout.WorldSwitcher.Open

function TRSLogoutWS.Open: Boolean;

Opens the in-game worldswitcher


Logout.WorldSwitcher.Close

function TRSLogoutWS.Close: Boolean;

Closes the worldswitcher (returns back to the logout button)


Logout.WorldSwitcher.ClickWorld

function TRSLogoutWS.ClickWorld(World, WorldColor: Int32): Boolean;

Attempts to click a world [Using a simple bitmap search].


Logout.WorldSwitcher.Scroll

function TRSLogoutWS.Scroll(Down: Boolean): Boolean;

   Returns true if world-switcher was scrolled [By checking for pixelshift].

Logout.WorldSwitcher.SwitchTo

function TRSLogoutWS.SwitchTo(World: Int32): Boolean;

Uses the in-game world switcher to switch to World. Returns true if succesfully switched [By reading current world].

Example

if Logout.WorldSwitcher.SwitchTo(302) then
  WriteLn('Switched to world 302');