script opens all backpacks around pg, searchs for iron metal, dull/shadow hammers, +10/+15 hammers (other hammers are ignored), crafts diamond maces and smelts them. demon maces are stored in main pack. no setup required.
important not: script smelts all non-demon diamond maces in main pg's backpack
1/2
important not: script smelts all non-demon diamond maces in main pg's backpack
1/2
codice:
set %packtype ZJF_LKF_HKF_HIF_BUD_ELN_CUD_JIF set %craftype CFR set %IngCol 0 set %HammerCOl1 2419 set %HammerCOl2 2406 set %HammerCOlq 2 set %NeedASH #true set %Category 9 set %Number 8 set %Prop1 demon set %PropQ 1 set #lpc 1000 event macro 31 0 wait 10 event macro 8 1 wait 20 finditem %packtype G_ , 2 while #findkind <> -1 { for #findindex 1 #findcnt { set #lobjectid #findid event macro 17 0 ignoreitem #findid OpenedPack wait 15 } wait 10 } wait 10 event macro 8 7 wait 20 ignoreitem reset OpenedPack loop: ignoreitem reset smelted finditem %craftype C_ , #backpackid if #findkind = -1 { gosub restock ENK 200 for %i 1 10 { if %NeedASH gosub UpdateASH gosub UpdateRunic gosub s7MakeAnything Smith %Category %Number %ActiveRunic if #result = #false { gosub UpdateRunic if #result = #false break } wait 5 } } finditem %craftype C_ , #backpackid if #findkind = -1 { pause goto loop } while #findkind <> -1 { repeat event property #findid wait 1 until weapon in #property set %Save #false for %i 1 %PropQ { if %Prop . %i in #property set %Save #true } if %Save { ;exevent drag #findid ;exevent dropc %secure ;wait 10 Ignoreitem #findid Save } else { set %ItemToIgnore #findid gosub s7MakeAnything Smith smelt #findid ignoreitem %ItemToIgnore smelted wait 5 } finditem %craftype C_ , #backpackid } goto loop sub UpdateRunic set %RunicFound #false repeat finditem TLH C_ , #backpackid if #findkind <> -1 { for #findindex #findcnt 1 { set %NeededCol #false for %iH 1 %HammerCOlq { if #findcol = %HammerCOl . %iH set %NeededCol #true } if %NeededCol = #false { ignoreitem #findid BadFindCol continue } else { set %RunicFound #true set %ActiveRunic #findid break } } } if %RunicFound = #false { finditem TLH C if #findkind = -1 break for #findindex 1 #findcnt { set %NeededCol #false for %iH 1 %HammerCOlq { if #findcol = %HammerCOl . %iH set %NeededCol #true } if %NeededCol = #false { ignoreitem #findid BadFindCol continue } else { exevent drag #findid exevent dropc #backpackid wait 10 break } } } until %RunicFound return %RunicFound sub UpdateASH finditem OLH C_ , #charid while #findkind = -1 { set %ASHfound #false finditem OLH C if #findkind = -1 break if #findkind <> -1 { for #findindex 1 #findcnt { repeat event property #findid wait 1 until weight in #property if +60 in #property || +30 in #property { ignoreitem #findid BadFindCol continue } if +15 in #property || +10 in #property { set %ASHfound #true break } } } if %ASHfound { exevent drag #findid exevent droppd wait 10 } finditem OLH C_ , #charid } return sub restock set %tot 0 finditem %1 C_ , #backpackid if #findkind <> -1 { for #findindex 1 #findcnt { if #findcol <> %IngCol { ignoreitem #findid BadFindCol continue } set %tot %tot + #findstack } } if %tot >= %2 return set %need %2 - %tot need: if %need > 0 { finditem %1 C for #findindex #findcnt 1 { if #findcol <> %IngCol { ignoreitem #findid BadFindCol continue } if #findbagid <> #backpackid break } if #findstack < %need set %take #findstack else set %take %need set %need %need - %take exevent drag #findid %take exevent dropc #backpackid wait 10 if %need > 0 goto need } return
Commenta