Page 1 of 2

Patek's Reagent Buying Macro (PRB) - Fully Automated & Free!

Posted: Sat Nov 15, 2014 10:33 pm
by Patek
Afternoon all,

I'd like to introduce you all to the Patek Reagent Buying Macro (PRB)!

The macro is a fully automated "one click" reagent buyer that goes to all 27 mage and reagent shops in Britannia/T2A and can buy millions upon millions of gp a day worth of regs if you let in run non-stop. It runs on 118 cross-linked macros (+1 installer macro) that call each other automatically.

I've decided to share my automated reagent buying macro for any and all who might be interested purely for the fun of it. I wrote the macro from scratch about a year ago and then created the package version a few months back and mulled over when to release it. Now seems as good of a time as any though so here we are :). UOSA has given me many good memories (hopefully more still to come) so this is my way of giving back to the community in some small way.

Macro includes:
- Fully automated recall to and from all mage shops including T2A with included fail-over redundancies throughout
- Fully automated walking of stores (to hit all vendors) and buying
- Fully automated de-stocking and re-stocking at bank
- Built in danger avoidance and threat detection with automatic emergency recalls including redundancy
- Very high server save tolerance
- Tweakable reagent buyers to get less or more of a specific reagent
and so on... [it basically does everything with one click]

The link below contains a .zip container with the below listed package contents:
https://mega.co.nz/#!l0ZW0RJZ!vO_Ho_6LC ... oxYdzTZcXM

The package includes the following:
- 118 macros for reagent buying
- 1 macro for installation
- Step-by-Step installation doco
- 27 pictures showing each store and the relevant rune marking points in each
- Razor player .xml file for reagent buyer (for pre-configured agents)

The installation document contains the following:
- List of items you'll need to get started
- Detailed Step-by-Step instructions for initial configuration, even for those with very limited Razor knowledge
- Macro configuration details to get the most out of the macros
- Helpful hints on configuration and general reg buying and the structure of the macro
- Other useful bits and pieces

Please check the updates below as several potential issues have been identified that may save you a lot of headache :). I'll amend all these in a new version soon.

Notes:
1. Magincia has been excluded from my macro as the mage shop there can cause client crashes (no idea why, but i've tested it a lot to no avail).
2. The macro has multiple layers of danger avoidance and threat detection but nothing is guaranteed. Don't worry though, you'll die rarely if at all and the guide has ways of minimising grief losses to minuscule amounts.
3. The idea that reagent providers on the server are out-bought or over-bought is actually incorrect, there's tonnes to go around. If you're thinking about trying it do it, you'll be amazed at how much you get in a short amount of time.
4. A commented version of this macro exists but wasn't included because I wanted to keep things neat. Removing comments sped the macro up about 50 - 70% (I do A LOT of comments), but if you'd like some commented files to get an idea of how the macro works let me know and i'll get them up.
5. I'm releasing this for everyone to be able to enjoy the server more and to help level the playing field for newer guys or those who just aren't Razor scripting types, not to for any negative reasons. All I ask in return is that you enjoy it :)

If anyone has comments or questions feel free to post in this thread or just PM me and ill try get back to you relatively quickly.

Take care all, have fun and happy gaming!

Update #1
The installation directory structure can be a catch cause I probably didn't detail it fully. All the files in the "Macro Files" directory get put into Razor\Macros\PRB. Don't copy the actual PRB folder from the zip into Razor\Macros otherwise it'll look like Razor\Macros\PRB\Macro Files\ and the macro-to-macro links wont work.


Update #2
If any issues are experienced (as detailed in a post below) a good idea is to save the PRB-Item-IDs.txt file and start with a fresh copy of the macro files from the .zip. Simply delete the existing \PRB directory in Razor\Macros, copy in a fresh lot of macros from the .zip into a new \PRB directory and go through the find-replace steps from the installation doco with the PRB-Item-IDs you've collected and try running again :).


Update #3
The PRB-Item-IDs file lists a variable called PRBBAG where the actual macro files list RBBAG (there could instances or PRBBAG as well, so just make sure when replacing that step to replace over RBBAG and PRBBAG). The profile file is PRBBAG, so its a bit confusing. This discrepancy is just a small error and Ill create a new version of the macros soon with everything sorted and uniform


Update #4
If your macro isn't restocking gold from the bank using Restock Agent-1 then check that you have a Gold counter created in Razor with the name "Gold". This is included in the profile that comes in the .zip, but it may need to be recreated if it doesn't work. A way to check if the gold counter is working is to create a new macro in Razor and insert Special Constructs->Insert "if" Conditional and check that "Gold" is in the list of thing you can check against.


Update #5
When doing the replace step make sure to do RUNEONET2A and RUNETWOT2A before RUNEONE and RUNETWO so they don't get replaced by accident.


- Patek

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sat Nov 15, 2014 11:43 pm
by Capitalist
:O why give this out?! :D

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sat Nov 15, 2014 11:46 pm
by Storx
for the ppl to dumb to make their own =/

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Nov 16, 2014 4:35 am
by Patek
I didnt know Treysta was having a break, otherwise id have released it sooner heh. Cant let the server go without cheap bulk regs - think of the madness!

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Nov 16, 2014 9:45 am
by Treysta
Good resource Patek! +1

(This is probably Hicha's favorite thread in a while)

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Nov 16, 2014 4:14 pm
by azheman
The zip contained nothing but gay porn.

Buyer beware

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Fri Jan 01, 2016 11:29 pm
by Patek
Just a bump to remind people this is here.

One thing i've noticed bout the installation, when doing the replace step make sure to do RUNEONET2A and RUNETWOT2A before RUNEONE and RUNETWO so they don't get replaced by accident.

Also, if anything doesnt work lemme know on forums or in IRC.

Cheers all

- Patek

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Jan 03, 2016 1:05 am
by Patek
Ok, had another message about an issue thats actually a Razor bug of sorts, but can affect the macro.

Symptoms of this happening are the macro just looping when you run any of the component parts. So if you ran PRB-Bank-00 or PRB-Buy-01 for example it'd just loop over and over and never progress.

When Razor starts a macro it actually checks the macro for internal macro-to-macro links and if it can't find the macro on the other end it will delete the line. The PRB Reagent Buyer has tonnes of these links in every file, so if you start UO even once while the PRB stuff isnt in the right directory it may wipe all those lines in that macro.

Way to fix it is sledgehammer'ish but simple.
1. Save your PRB-Item-ID file that contains all your unique numbers to a safe directory.
2. Delete the Macros\PRB directory from Razor.
3. Make sure you're out of UO and Razor completely.
4. Get a fresh copy of the PRB macros from the zip and place them in the Razor\Macros\PRB folder
5. Re-do the find-replace sections of the installation file.
6. Try the macro again :)

(I may amend the installation instructions in future to finish the PRB-Item-IDs prior to moving the PRB macro into the Razor directory, but for now, if you're having an issues try a fresh copy of the PRB macros with the Item IDs you put into the PRB-Item-IDs file as the first troubleshooting step).

The folder within the Razor\Macros\ MUST be \PRB otherwise links wont work.

Any questions let me know and happy macro'in :)

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Jan 03, 2016 4:20 am
by Mens Rea
Thank you Patek, works great!

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Mon Jan 04, 2016 5:02 pm
by Roser
It's truly a masterful work!

The setup takes a bit of time but it is well worth it, just follow the instructions and reap the benefits!

My first rounds of reg buying went flawlessly, I burned through 120k gold very fast.

Cheers Patek!

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sat Feb 25, 2017 11:20 pm
by randale
The runes have to be marked manually, right? Marking the runes isn't part of it, is it? You certainly can't carry 153 runes, or 153 anything of seperate items at the same time.

Another thing is it takes up ALL your organizer agents, and some restocks, etc. Though, I don't know why they made razor that way. Why didn't they just make it so you could have an unlimited number of those- as many as your hard drive can hold?

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Sun Feb 26, 2017 6:40 am
by Mens Rea
Read the instructions.

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Mon Feb 27, 2017 12:43 am
by Patek
randale wrote:The runes have to be marked manually, right? Marking the runes isn't part of it, is it? You certainly can't carry 153 runes, or 153 anything of seperate items at the same time.

Another thing is it takes up ALL your organizer agents, and some restocks, etc. Though, I don't know why they made razor that way. Why didn't they just make it so you could have an unlimited number of those- as many as your hard drive can hold?
Runes - You have to manually mark all the runes, however they're held in runebooks that sit inside your bank. You only carry around a single runebook (thats a copy of one of the bank held ones). When marking just do it one or two runebook's worth at a time.

Restock/Organizer - You can have multiple profiles that each have their own restock and organizer agents. I include the profile you need inside the PRB files, so you just select that in Razor and use it, then select your own when you're not buying regs.

As for razor limits - You can bend these in some places, but you'd be amazed at how much stuff you can cram into the available number if you get creative :)


- Patek

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Mon Feb 27, 2017 1:23 am
by Capitalist
Come back to us, lover!

Re: Patek's Reagent Buying Macro (PRB) - Fully Automated & F

Posted: Mon Feb 27, 2017 1:41 am
by Mens Rea
Patek is too polite, it said all of that in the instructions.