Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.

Sub main
/declare NPCName string outer MobName
/declare GiveItem string outer ItemGiveName
:mainLoop
/if (${Spawn[npc ${NPCName}].ID}) {
/if (${Target.ID}) /squelch /target clear
/delay 2s !${Target.ID}
/squelch /target id ${Spawn[npc ${NPCName}].ID}
/delay 2s ${Target.Name.Find[${NPCName}]}
/if (${Target.Name.Find[${NPCName}]}) {
/echo ${NPCName} found attempting to give him the ${GiveItem}
/if (${Cursor.ID}) /autoinventory
/delay 2s !${Cursor.ID}
/shift /itemnotify in Pack${Math.Calc[${FindItem[${GiveItem}].ItemSlot}-22]} ${Math.Calc[${FindItem[=${GiveItem}].ItemSlot2}+1]} leftmouseup
/delay 2s ${Cursor.ID}
/click left target
/delay 2s ${Window[GiveWnd].Open}
/if (${Window[GiveWnd].Open}) {
/notify GiveWnd GVW_Give_Button leftmouseup
/altactivate 331
/endm
}
}
}
/delay 10s
/goto :mainLoop
/return
Sub Main
/declare NPCName string outer "MobName"
/declare ItemName string outer "ItemGiveName"
:checkSpawnLoop
/if (${Spawn[${NPCName} npc].ID} && ${Target.ID}!=${Spawn[${NPCName} npc].ID}) {
/squelch /target id ${Spawn[${NPCName} npc].ID}
/goto :checkDistance
}
:checkCursor
/if (!${Cursor.Name.Equal[${ItemName}]}) {
/autoinv
/itemnotify ${FindItem[${ItemName}].InvSlot} leftmouseup
}
/goto :checkSpawnLoop
:checkDistance
/if (${Target.Distance}<5) /stick 5
:giveItem
/if (${Target.ID}==${Spawn[${NPCName} npc].ID} && ${Cursor.Name.Equal[${ItemName}]} && ${Target.Distance}<5) {
/click left target
}
/delay 5
/goto :giveitem
:waitTradeWnd
/if (${Window[TradeWnd]}) {
/notify TradeWnd TRDW_Cancel_Button LeftMouseUp
/delay 2s
/goto :gtfo
}
/delay 5
/goto :waitTradeWnd
:gtfo
/alt activate 331
/delay 120s
/camp desktop
Sub Main
/declare NPCName string outer "MobName"
/declare ItemName string outer "ItemGiveName"
:checkSpawnLoop
/if (${Spawn[${NPCName} npc].ID} && ${Target.ID}!=${Spawn[${NPCName} npc].ID}) {
/squelch /target id ${Spawn[${NPCName} npc].ID}
/goto :checkDistance
}
:checkCursor
/if (${Cursor.Name.NotEqual[${ItemName}]}) {
/autoinv
/itemnotify "${ItemName}" leftmouseup
}
/goto :checkSpawnLoop
:checkDistance
/if (${Target.Distance}<10) /stick 10
:giveItem
/if (${Target.ID}==${Spawn[${NPCName} npc].ID} && ${Cursor.Name.Equal[${ItemName}]} && ${Target.Distance}<12) {
/click left target
}
/delay 5
/goto :giveitem
:waitTradeWnd
/if (${Window[TradeWnd]}) {
/notify TradeWnd TRDW_Cancel_Button LeftMouseUp
/if !${Window[TradeWnd]} /goto :gtfo
}
/delay 5
/goto :waitTradeWnd
:gtfo
/alt activate 331
/delay 120s
/camp desktop
"Unmatched bracket or invalid character following bracket found in index: handin.mac@7 (Main): /if (${Spawn[${NPCName} npc].ID} && ${Target.ID}!=${Spawn[${NPCName} npc].ID}) {" this still happening not sure how one would even fix this but I keep getting it
Sub Main
/declare NPCName string outer "MobName"
/declare ItemName string outer "ItemGiveName"
:checkSpawnLoop
/if (${Spawn[${NPCName}.ID}] && ${Target.ID}!=${Spawn[${NPCName}].ID}) {
/squelch /target id ${Spawn[${NPCName}].ID}
/goto :checkDistance
}
:checkCursor
/if (${Cursor.Name.NotEqual[${ItemName}]}) {
/autoinv
/itemnotify "${ItemName}" leftmouseup
}
/goto :checkSpawnLoop
:checkDistance
/if (${Target.Distance}<10) /stick 10
:giveItem
/if (${Target.ID}==${Spawn[${NPCName}].ID} && ${Cursor.Name.Equal[${ItemName}]} && ${Target.Distance}<12) {
/click left target
}
/delay 5
/goto :giveitem
:waitTradeWnd
/if (${Window[TradeWnd]}) {
/notify TradeWnd TRDW_Cancel_Button LeftMouseUp
/if !${Window[TradeWnd]} /goto :gtfo
}
/delay 5
/goto :waitTradeWnd
:gtfo
/alt activate 331
/delay 120s
/camp desktop
