SWG Wiki
Line 221: Line 221:
 
it will restart the progress. If you remove the /pause 2.2 the crafting tool on Slot 1 won't be
 
it will restart the progress. If you remove the /pause 2.2 the crafting tool on Slot 1 won't be
 
fast enough to finish the prototype.''
 
fast enough to finish the prototype.''
  +
  +
'''Note 4''' ''Edit; Fixed some typos. Also this Macro was made for Structure Traders crafting
  +
Stations. Of course it can be used for anything else too. But be sure to change the /pause value
  +
if the item uses multiple different resources.''
   
 
/ui action toolbarSlot00;
 
/ui action toolbarSlot00;
Line 269: Line 273:
 
/ui action toolbarSlot05;
 
/ui action toolbarSlot05;
 
/pause 1;
 
/pause 1;
/ui action DefaultButton;
+
/ui action defaultButton;
 
/pause 4;
 
/pause 4;
 
/nextCraftingStage;
 
/nextCraftingStage;

Revision as of 01:11, 2 August 2008

Overview

The following article about creating macros is based on a post by JoeCrimson on the SWG Craft website / forums. Further edits have been made for some slight adjustments found to be true in the live game today.

Original Article

JoeCrimson's Post on Crafting Macros

First of all there isn't an AFK macro for crafting, but this can really speed things up for you.

Here's what you'll need to get this to work right:

  • pad and pencil (or a REALLY good memory)
  • half an hour or so to set up macro
  • 4 to 5 or more crafting tools depending on how long it takes to make whatever you're trying to make

Here are the commands and a description of how they work:

  • /ui action toolbarSlot00
    • THE 'S' NEEDS TO BE CAPITALIZED!!! The UI will not give you an error message if you don't capitalize it, you'll just sit there and wonder what went wrong!!! This triggers one of the toolbar buttons, depending on the number (00 - 11 for the bottom row, left to right, and 12 - 23 for the top row)
  • /selectDraftSchematic 0
    • Capitalization, oddly not required, but stay in the habit of capitalizing new words, it's a good programming practice . Selects a draft schematic based on the number after the command (note the space in there). The ordering of the draft schematic seems to be based on phases of the moon, and other strange esoteric stuff, so that's why you need the paper and pencil. It's time consuming, but the best way to do this, is to type out /ui action toolbarSlot00;/selectDraftSchematic 0; and run that from the chat prompt, stepping selectDraftSchematic manually as you go, and closing the crafting window after each time. This prevents pressing enter from triggering the next crafting stage and messing you up ("Gee, why is the Advanced Biological Effects Controller draft schematics number 5 - 28, that's weird." And don't look at me like I'm stupid, it was an honest mistake).
  • /nextCraftingStage
    • As above, capitalization not required. This moves crafting to the next stage of the session (like pressing enter).
  • /createPrototype
  • /createPrototype Practice No Item
    • These two commands are the same, except for the 'Practice No Item' switch at the end. This command ends the crafting session, and makes the item (or practices on it).

The completed macro comes together something like this (annotated version follows):

/ui action toolbarSlot00; 
/selectDraftSchematic 0; 
/pause 7; 
/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 

Notes and annotated version of macro:

  • First, if you do this with one crafting tool, it isn't worth the time. On average, with a schematic that takes 29 seconds to make (Micronutrient Supplement, /selectDraftSchematic 8 for me), I can make 5 or more in the time it takes me to do 4 manually. Get good crafting tools, if you critically fail while doing this, it's probably going to take you a couple of minutes to move your crafting button out of the spot it's in and let the macro cycle through to the end.
  • Second, yes, those commands are there multiple times for a reason. Put them in just like that if you want the macro to work right.
  • Third, this macro will not let you automate the experimentation portion of crafting, nor will it stop on the experimentation portion of the crafting process. This is due to /nextCraftingStage not actually SHOWING the next stage, but just going to it in memory. This macro is 100% useless for experimenting IMHO.


Annotated version:

/ui action toolbarSlot00; * Activates button in the F1 position 
/selectDraftSchematic 8; * Selects draft schematic 8 
/pause 7; *6-7 seconds is the minimum
...unless you're very fast with the mouse
...run it this  way once or twice, and then adjust as you see fit
...or it's probably going to waste time by trying to go to the next stage of crafting. 
/nextCraftingStage; *forwards UI to the next step of crafting (hidden) 
/nextCraftingStage; *see above 
/nextCraftingStage; *If you don't know what this does by now, there's no helping you 
/createPrototype Practice No Item; *finishes the item 
/createPrototype Practice No Item; *closes the crafting session window 

Okay, other than that, just repeat and have it target a different crafting tool in a different slot of the toolbar, until you've used all the tools you have. After that, set it to trigger itself again, and it'll keep running through till you move the button from the position it's in.


Here is an update to this post to streamline the proccess even more. For this I have been using four crafting tools, using higher quality tools to cut down on critical failures. What I have done is simply added two more commands at the end of this one and created the macro four times. I will show you exactly what I am using and then explian the additions so you can modify to your needs.

First of all I created four macros crafting_1 - crafting_4.

Crafting_1: 
/ui action toolbarSlot12; 
/selectDraftSchematic 144; 
/pause 6; 
/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 
/pause 3; 
/ui action toolbarSlot01; 
Crafting_2: 
/ui action toolbarSlot13; 
/selectDraftSchematic 144; 
/pause 6; 
/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 
/pause 3; 
/ui action toolbarSlot02; 
Crafting_3: 
/ui action toolbarSlot14; 
/selectDraftSchematic 144; 
/pause 6; 
/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 
/pause 3; 
/ui action toolbarSlot03;
Crafting_4: 
/ui action toolbarSlot15; 
/selectDraftSchematic 144; 
/pause 6; 
/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 
/pause 3; 
/ui action toolbarSlot00;

The set up, expand your tool bar so you can see both rows. Now place Crafting_1 in the top F1 slot of the bar than place Crafting_2 in the top slot of F2 and so on... Now place each of your four crafting tools in the bottom slot of possitions F1 - F4.

Once this is done simply hit F1 and start crafting. You will have 6 seconds to select your resources before the macro moves on. *side note* You can select the resources by double clicking on them, don't drag and drop it takes too much time. The macro then finishes the crafting session. Next there is a 3 second pause before the last command. The last command in this macro is to start the next macro in line, Crafting_4's last command is to start Crafting_1.

The end resalt is once you hit that first key you shouldn't have to hit another key until you want to stop the loop. Now you just sit back nad double click your way to the next level!

One last bit of info is on time control. The overall length of time each macro takes is 9-11 seconds. The item I am grinding to get xp, takes 30 seconds for the crafting tool to create. So when tool 1 starts to produce the item I have three more tools to go through before I get back to tool 1, so at 10 seconds for each tool it takes me total of 30 seconds before I get back to tool 1. Tihs works out prefectly for me, but what is if your item takes 40 seconds to make? Well it is a pretty simple salution create macro Crafting_5 and add a fifth crafting tool. But what if your item only takes 25 seconds to make? Well you could leave it as is but we want to be as efficient as possible, so I would recommend dropping the 3 second pause to a 2 second pause.

Edits for current game

I've used the following edits in my crafting grind macros:

Crafting_1: 
/ui action toolbarSlot00;
/pause .5
/selectDraftSchematic 144; 
/pause 6; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item;++
/pause 3; 
/macro Crafting_2; 

The reasons for my edits are as follows:

  • That first pause is needed becuase sometimes the macro runs faster than the crafting tool can boot. So the selectDraftSchematic command will fail and the rest of the macro fails. The half second pause avoids that.
  • I've only needed two /nextCraftingStage commands. Probably a post-NGE change in the process.
  • That last pause delay should be adjusted based on how long it takes your tool to complete the craft. Basically the idea is that by the time Crafting_5 is calling Crafting_1, the first craft tool needs to be ready.
  • Rather than putting all 5 macros and all 5 tools on the toolbar, I just put the 5 crafting tools in slots 1-5 and then have each macro call the next one. Saves me some toolbar space.

Renwin

++ The second /createPrototype line is required only for crafting with a station.

PracticeIt & MakeIt

One of the pains in the grind macro is that each skill up you earn that gives you new recipes changes the order of them. So the selectDraftSchematic command has to keep being adjusted. For this reason, I created two other macros as follows and put them on my toolbar:

PracticeIt:
++/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype Practice No Item; 
/createPrototype Practice No Item; 
MakeIt:
++/nextCraftingStage; 
/nextCraftingStage; 
/nextCraftingStage; 
/createPrototype; 
/createPrototype; 

What this lets me do is boot the crafting tool by choosing one that's not busy. If I haven't made the item atleast once, I'll have to manually select the schematic. If I have, the tool will default to that schematic and all I have to do is hit 'Next'. I load in the resources required, then hit either the MakeIt or PracticeIt macro to complete the process. It saves several button clicks and dialog boxes without having to re-select the schematic number again as I'm levelling up.

PracticeIt finishes the crafting session without making an item (which gives better xp). MakeIt creates the item and puts it in your inventory when the tool is finished. Renwin ++ Repeated attempts with the above without this line done while standing at a crafting station failed. With its addition repeated attempts show success.


I too had made these macros a while back by taking the original macros from the top and editting them. ( did it for the same reason as Renwin stated) I didn't think to put them on here however, which I should have. Thank you Renwin for doing this. It will help crafters a lot.

Aetaiwa Eesa-FarStar

Other notes

  • If you don't feed the tool any resources, the macro just happily goes on its way without any error dialog boxes or anything. This allows you to chat if you need to without having the end the macro
  • If you're new to macros ... the way to stop a looping macro (or set of them) is to use the /dump command.

Dealman


Non-bugged Macro

(AutoCraft)

How to Use: You can use a maximum of 12 Tools for this macro. If you think it takes long time until it goes until next stage after putting the resources, you can change the parameter value "/pause 6;" to 4/5.

Also, if you got more than 1 tool, which I higly suggest, you copy the whole code and paste it again. You only need to change the "/ui action toolBarSlot##;" parameter. The value 00 represents the first slot at your ActionBar. 01 for 2nd Slotand so on. Also the /pause 2; at the end IS needed. If you skip that /pause 2; it will jump over the tool after the one recentley used. So it uses Slot 1, 3, 5 and so on. And jumps over Slot 2, 4 etc. The parameter "/macro AutoCraft;" restarts the macro after it used the last tool.

Note: To stop the macro type /Dump.

/ui action toolbBarSlot00; /pause 1; /ui action defaultButton; /pause 6; /ui action defaultButton; /pause 1; /ui action defaultButton; /pause 1; /nextCraftingStage; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice No Item; /createPrototype Practice No Item; /pause 2; /macro AutoCraft;

The perfect macro using 7 tools (Looping)

Note This Macro will use your Primed crafting item. It's mentioned above how to Prime an item. Anyhow, you open your tool - Select your desired item the macro shall create - And press ESC/Go back. The Macro will now use choose this item when started.

Note 2 Make sure you don't place same crafting tool in 2 slots, otherwise it will mess up.

Note 3 This macro will use 7 tools and directly after the last tools have been used it will restart the progress. If you remove the /pause 2.2 the crafting tool on Slot 1 won't be fast enough to finish the prototype.

Note 4 Edit; Fixed some typos. Also this Macro was made for Structure Traders crafting Stations. Of course it can be used for anything else too. But be sure to change the /pause value if the item uses multiple different resources.

/ui action toolbarSlot00; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot01; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot02; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot03; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot04; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot05; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2; /ui action toolbarSlot06; /pause 1; /ui action defaultButton; /pause 4; /nextCraftingStage; /nextCraftingStage; /createPrototype Practice noitem; /createPrototype Practice noitem; /pause 2.2; /macro AutoCraft

Dealman