;Si ves ke falla porque intenta hacer otro objeto antes de 
; que acabe el otro, cambia el wait 4s por algo mas

ignoreitem reset


;Apuntamos los lingotes de iron

set %vendo SI
call apuntar RMK 0
if %1 = -1
 {
  set %vendo NO
  exit
  }
set %LingotesID #LOBJECTID

set #LOBJECTID %MartilloID
key %LastObject
set #LTARGETID %MartilloID
set #LTARGETKIND 1
target 4s
key %LastTarget
wait 10
BucleDeTinker:

 msg $,waitmenu Herrero Armas Armas Swords Espadas daga$

 set #LOBJECTID %LingotesID
 key %LastObject
 wait 145 

findetinker:
     ;Se esta haciendo un savegame
     if WRDSV_A_EN in #SYSMSG
        wait 25s
 if #contkind in WNF_AECB
    {
     click 46 57 r
     wait 10
     goto findetinker
    }
 
;comprobamos el numero de lingotes
  finditem %lingotesID
  if #findkind = -1
       exit
  if #findstack < 4
       exit
goto BucleDeTinker

