Jump to content
Bixby Sayz

Grand Exchange routines

Recommended Posts

A few routines for the Grand Exchange I wrote for use in one of my own scripts. Also includes collecting/checking status of trades from a Banker. Threw in a function I use for looking up ge prices just because.

 

Didn't post the actual code before because it wasn't completed and I had to uncouple it from my custom routines to make it standalone.

 

If someone is in a position to field test it in their own scripts that would be awesome.

 

Note: One thing I agonized over is the return value of collecting all items. Suppose you have multiple trades, one of which is 0 percent complete. Collecting will succeed for the others, but fail for that one. Was the collect all successful?

 

Edit: Do you think get percent complete (for a trade) would be of any use, or just fluff?

 

[sCAR]{=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

UnOfficial SCAR Include

Runescape 2

Grand Exchange routines

--------------------------------------------------------------------------------

* const Amount Indexes

By: Bixby Sayz

* const Price Indexes

By: Bixby Sayz

* const Npc Indexes

By: Bixby Sayz

* function GELookupPrice(ItemId: Integer): Integer;

By: Bixby Sayz

* function GEScreen: Boolean;

By: Bixby Sayz

* function GEBuyScreen: Boolean;

By: Bixby Sayz

* function GESellScreen: Boolean;

By: Bixby Sayz

* function GECloseBuySellScreen: Boolean;

By: Bixby Sayz

* function GEFindNpc(WhichNpc: Integer; out Loc: TPoint): Boolean;

By: Bixby Sayz

* function GEOpenGE: Boolean;

By: Bixby Sayz, Wanted

* function GECloseGE: Boolean;

By: Bixby Sayz

* function GEOpenGETutor(DoTutorial: Boolean): Boolean;

By: Bixby Sayz, Wanted

* function GEMember: Boolean;

By: Bixby Sayz

* function GEGetSlotBounds(GESlot: Integer): TBox;

By: Bixby Sayz

* function GEGetProgressBarBounds(GESlot: Integer): TBox;

By: Bixby Sayz

* function GESlotFree(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GEFindFreeSlot(out GESlot: Integer): Boolean;

By: Bixby Sayz

* function GETradeFinished(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GETradeCancelled(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GECollectItems(GESlot: Integer; Noted: Boolean): Boolean;

By: Bixby Sayz

* function GECollectAllItems(Noted: Boolean): Boolean;

By: Bixby Sayz

* function GECancelTrade(GESlot: Integer; Noted: Boolean): Boolean;

By: Bixby Sayz

* function GEBuyItem(ItemName: string; Amount, Price: Integer): Boolean;

By: Bixby Sayz

* function GESellItem(InvSlot, Amount, Price: Integer): Boolean;

By: Bixby Sayz

* function GEBankerGEScreen: Boolean;

By: Bixby Sayz

* function GEBankerCloseGE: Boolean;

By: Bixby Sayz

* function GEBankerGetSlotBounds(GESlot: Integer): TBox;

By: Bixby Sayz

* function GEBankerGetProgressBarBounds(GESlot: Integer): TBox;

By: Bixby Sayz

* function GEBankerTradeFinished(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GEBankerTradeCancelled(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GEBankerSlotFree(GESlot: Integer): Boolean;

By: Bixby Sayz

* function GEBankerCollectItems(GESlot: Integer; Noted: Boolean): Boolean;

By: Bixby Sayz

* function GEBankerCollectAllItems(Noted: Boolean): Boolean;

By: Bixby Sayz

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=}[/sCAR]

GrandExchange.scar

Edited by Bixby Sayz
Link to comment
Share on other sites

UnOfficial SCAR Include

Yes, unofficial. The template is taken from the official OSI includes, but it is not officially part of the OSI includes. Merely something I cooked up.

 

Good catch btw. Thought for sure everyone would overlook that seemingly minor detail.

Link to comment
Share on other sites

Yes, unofficial. The template is taken from the official OSI includes, but it is not officially part of the OSI includes. Merely something I cooked up.

 

Good catch btw. Thought for sure everyone would overlook that seemingly minor detail.

 

Thought it was funny. You do know you only posted the file header and none of the functions right?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
  • Create New...