Post by Ravenclaw on Aug 25, 2013 21:38:32 GMT -8
Made using AssistUO v1.0.0 RC8 Build 11 (www.runuo.com/products/assistuo)
You need to be sitting in a place where you can tinker and next to a forge/anvil and a trash barrel for this macro to work. Tinker tools and metal must be in your pack and the tinker tool should be set to the type of metal you are using.
If you find it stops working, it may be because you have a small amount of a different type of ingots in your pack and that is the pile it's looking at. Even if you set the ingot type on the tool remove the small quantities of other types(Iron, dull copper, etc..) from your pack and then it will read the correct ingot stack.
***UPDATED: Aliases can be set now for item to be created and tinker tool button to be pressed. No longer need to edit script outside of "SET ALIASES" area to change what gets made and handled.
***UPDATED: The script will now also automatically make more tinker tools if you are down to only one.
***UPDATED: Dec. 24, 2013 - Find items in backpack and trashes them better now. (Use Backpack as Tinkerbag)
You need to be sitting in a place where you can tinker and next to a forge/anvil and a trash barrel for this macro to work. Tinker tools and metal must be in your pack and the tinker tool should be set to the type of metal you are using.
If you find it stops working, it may be because you have a small amount of a different type of ingots in your pack and that is the pile it's looking at. Even if you set the ingot type on the tool remove the small quantities of other types(Iron, dull copper, etc..) from your pack and then it will read the correct ingot stack.
***UPDATED: Aliases can be set now for item to be created and tinker tool button to be pressed. No longer need to edit script outside of "SET ALIASES" area to change what gets made and handled.
***UPDATED: The script will now also automatically make more tinker tools if you are down to only one.
***UPDATED: Dec. 24, 2013 - Find items in backpack and trashes them better now. (Use Backpack as Tinkerbag)
//++++++++++++++++++++++++++++
//STAGE 0 SET ALIASES
//++++++++++++++++++++++++++++
//Prompt for Trashcan Alias
If not findalias 'trashcan'
sysmsg 'PLEASE TARGET THE TRASHCAN' '32'
promptalias 'trashcan'
endif
//Prompt for Tinkerbag
If not findalias 'tinkerbag'
sysmsg 'PLEASE TARGET THE BACKPACK' '32'
promptalias 'tinkerbag'
endif
//Set Tinker Item Here
if listexists 'tinkeritem'
@clearlist 'tinkeritem'
else
@createlist 'tinkeritem'
endif
@pushlist 'tinkeritem' 0x1849
//Set Tinkertool Button Value Here
if listexists 'tinkerbtn'
@clearlist 'tinkerbtn'
else
@createlist 'tinkerbtn'
endif
@pushlist 'tinkerbtn' 51
//++++++++++++++++++++++++++++
//STAGE 1 Check For Tools, Ingots and Weight and Smelt Items if needed
//++++++++++++++++++++++++++++
//Check tinker tools and make more if needed.
if counttype! 0x1eb8 'any' 'backpack' == 1
sysmsg 'MAKING TINKER TOOLS!' '32'
For 3
usetype! 0x1eb8 'any' 'backpack'
waitforgump 0x38920abd 15000
replygump 0x38920abd 36
waitforgump 0x38920abd 15000
replygump 0x38920abd 184
waitforgump 0x38920abd 15000
replygump 0x38920abd 0
Endfor
endif
//Check for Ingots
if not @findtype 0x1bf2 'any' 'backpack' 4
sysmsg 'NEED MORE INGOTS!' '32'
stop
endif
//clear journal for clean read
clearjournal
//Check Weight and take action if too heavy
if weight >= maxweight
//If not near an anvil
//***Adjust Tinkered Items Here 1 of 10***
while @findtype tinkeritem[] 'any' 'backpack'
usetype! 0x13e3 'any' 'backpack'
waitforgump 0x38920abd 5000
replygump 0x38920abd 14
waitfortarget 5000
//***Adjust Tinkered Items Here 2 of 10***
targettype! tinkeritem[]
waitforgump 0x38920abd 5000
if @ingump 0x38920abd 'near an anvil'
sysmsg 'MOVE NEXT TO AN ANVIL TO SMELT ITEMS' '32'
replygump 0x38920abd 0
stop
endif
//If items cannot be smelted then trash them
if @ingump 0x38920abd 'melt that down into ingots'
sysmsg 'CANNOT SMELT THESE ITEMS, TRASHING INSTEAD' '32'
//***Adjust Tinkered Items Here 3 of 10***
while @findtype tinkeritem[] 'any' 'backpack'
//***Adjust Tinkered Items Here 4 of 10***
//movetype tinkeritem[] 'tinkerbag' 'trashcan'
moveitem 'found' 'trashcan'
pause 1000
endwhile
endif
replygump 0x38920abd 0
endwhile
//Check if after smelting there is enough Ingots to Continue
//Findtype is Ingots
if not @findtype 0x1bf2 'any' 'backpack' 4
sysmsg 'NEED MORE INGOTS!' '32'
stop
endif
//++++++++++++++++++++++++++++
//STAGE 2 If Weight and Ingots are good then make Item
//++++++++++++++++++++++++++++
else
//Open Tinker Tool and make Tinkered Item
if @findtype 0x1eb8 'any' 'backpack'
usetype! 0x1eb8 'any' 'backpack'
waitforgump 0x38920abd 5000
replygump 0x38920abd 22
waitforgump 0x38920abd 5000
replygump 0x38920abd tinkerbtn[]
waitforgump 0x38920abd 5000
pause 1000
//++++++++++++++++++++++++++++
//STAGE 2.5 Check GUMP after item is created for messages before continuing
//++++++++++++++++++++++++++++
//Checks the gump to see if container is full and dropping items
//***Adjust Tinkered Items Here 5 of 10***
if @findtype tinkeritem[] 'any' 'ground' '1' '3'
sysmsg 'BACKPACK IS FULL! OR ITEM ON GROUND' '32'
//***Adjust Tinkered Items Here 6 of 10***
while @findtype tinkeritem[] 'any' 'backpack'
usetype! 0x13e3
waitforgump 0x38920abd 5000
replygump 0x38920abd 14
waitfortarget 5000
//***Adjust Tinkered Items Here 7 of 10***
targettype! tinkeritem[]
waitforgump 0x38920abd 5000
if @ingump 0x38920abd 'near an anvil'
sysmsg 'MOVE NEXT TO AN ANVIL TO SMELT ITEMS' '32'
replygump 0x38920abd 0
stop
endif
//If items cannot be smelted then trash them
if @ingump 0x38920abd 'melt that down into ingots'
sysmsg 'CANNOT SMELT THESE ITEMS, TRASHING INSTEAD' '32'
//***Adjust Tinkered Items Here 8 of 10***
while @findtype tinkeritem[] 'any' 'backpack'
//***Adjust Tinkered Items Here 9 of 10***
moveitem 'found' 'trashcan'
//movetype tinkeritem[] 'tinkerbag' 'trashcan'
pause 1000
endwhile
endif
endwhile
//Check if any items are on the ground.
//***Adjust Tinkered Items Here 10 of 10***
if @findtype tinkeritem[] 'any' 'ground' '1' '3'
moveitem 'found' 'trashcan'
endif
//Check if after smelting there is enough Ingots to Continue
//Findtype is Ingots
if not @findtype 0x1bf2 'any' 'backpack' 4
sysmsg 'NEED MORE INGOTS!' '32'
stop
endif
endif