The Crafting object holds all functions and information needed for...drumroll...crafting!
this is a work in progress..
Accessing the Crafting functions
Example:
localsynth=Crafting:SynthInfo()
if ( synth ) thend("Current Step: "..tostring(synth.step).." Current Durability: "..tostring(synth.durability))
end
Crafting Functions
:CanCraftSelectedItem()
Returns if the currently selected Item in the CraftingLog can be crafted (boolean).
:CraftSelectedItem()
Crafts the selected Item in the CraftingLog (boolean).
:IsCraftingLogOpen()
Returns if the CraftingLog is opened (boolean).
:ToggleCraftingLog()
Opens/Closes the CraftingLog (boolean).
:EndSynthesis()
Finishes and closes the Quick-Synthesis Window (boolean).
:SynthInfo()
Returns a lua table which holds all synthesis relevant information (lua table).
--the 'd' command is a global command for printing out information into the consolelocalsynth=Crafting:SynthInfo()
d(synth.step) -- current stepd(synth.stepmax) -- max stepd(synth.itemid) -- currently crafted [[Item]] -IDd(synth.durability) -- current durabilityd(synth.durabilitymax) -- max durabilityd(synth.progress) -- current progressd(synth.progressmax) -- max progressd(synth.quality) -- current qualityd(synth.qualitymax) -- max qualityd(synth.qualitypercent) -- current quality in a percentd(synth.description) -- condition