Make

The “Make” menu is the chatbox menu that pops up when you attempt to craft certain items in OldSchool RuneScape. TRSMake is the record SRL has to handle it.


const MAKE_QUANTITY_ALL

-1 is the value we reserve for the “All” quantity. This constant simply exists so we have a human readable version that makes sense.

When using TRSMake methods you can use either -1 or MAKE_QUANTITY_ALL for the “All” quantity.


Make.Setup

procedure TRSMake.Setup; override;

Internal setup method automatically called by SRL on startup. You will probably never need to use this directly.


Make.SetupAlignment

procedure TRSMake.SetupAlignment(Mode: ERSClientMode); override;

Internal method automatically called by SRL on startup used to setup the interface coordinates. You will probably never need to use this directly.


Make.GetItemButtons

function TRSMake.GetItemButtons: TRSButtonArray;

Internal method used to get the interface buttons. This is used by all other methods that interact with buttons. You will probably never need to call this directly.

Example

Debug(Make.GetItemButtons());

Make.GetQuantityButtons

function TRSMake.GetQuantityButtons(): TRSButtonArray;

Internal method used to get the interface quantity buttons. This is used by all other methods that interact with the quantity buttons. You will probably never need to call this directly.

Example

Debug(Make.GetQuantityButtons());

Make.IsOpen

function TRSMake.IsOpen(): Boolean;
function TRSMake.IsOpen(WaitTime: Int32; Interval: Int32 = -1): Boolean; overload;

Checks if the make interface is open. You can optionally specify a WaitTime to wait for it to open.

Example

WriteLn Make.IsOpen();

Make.FindHint

function TRSMake.FindHint(): TPointArray;

Returns the hint tooltip has a TPointArray

Example

Debug(Make.FindHint());

Make.GetFreeSpace

function TRSMake.GetFreeSpace(): TPointArray;

Get a TPointArray of the chatbox that does not have a single point in any of the make item buttons.

Example

Debug(Make.GetFreeSpace());

Make.SetQuantity

function TRSMake.SetQuantity(Amount: Int32): Boolean;

Attempts to set a quantity.

Example

WriteLn Make.SetQuantity(MAKE_QUANTITY_ALL);

Make.SelectHelper

function TRSMake.SelectHelper(var Item: TRSMakeItem; Quantity: Int32; UseKeyboard: Boolean = True): Boolean;
function TRSMake.SelectHelper(Button: TRSButton; Quantity: Int32; UseKeyboard: Boolean = True): Boolean; overload;

Internal helper method that handles selecting a button and quantity with or without the keyboard. You probably will never need to use this directly.


Make.Select

function TRSMake.Select(Index: Int32; Quantity: Int32; UseKeyboard: Boolean = True): Boolean;
function TRSMake.Select(Item: String; Quantity: Int32; UseKeyboard: Boolean = True): Boolean; overload;

Select a Index of the available buttons or the button with Item text on it when hovered.

Example

WriteLn Make.Select('Maple longbow', MAKE_QUANTITY_ALL, True);

Make.Draw

procedure TRSMake.Draw(Bitmap: TMufasaBitmap); override; overload;

Internal debug method. Used by SRL.Debug().

Example

SRL.Debug();

var Make

Global Make variable.