I want to execute a primary weapon move every 3 seconds so I don't get the penalty for doing them back to back.
I'll use pixel scanning to determine the condition of the icon...
gosub set_pixel 1 ArmorIgnore 35 0
sub set_pixel
event macro %3 %4
display ok Move mouse to your %2 Button.$You have 2 seconds
wait 2s
savePix #cursorX #cursorY %1
wait 5
display ok Pixel saved as # %1 $Do NOT move that icon!
return
That sets cmppix 1 to the active Armor Ignore icon.
What I want to do is keep checking that, amongst other things, and when it toggles to False (the icon is no longer red) set a 3 second timer. During this 3 second timer I don't want to recheck the icon at all. At the end of the 3 second timer I want to activate Armor Ignore again, which is easy enough. During that 3 second period the rest of the script must continue.
I'm thinking I'll need a "pixel checker" in the main loop with a timer attached.
set %timer_primary ( #sCnt2 + 60 )
gosub check_primary
sub check_primary
cmppix 1 f ; icon is NOT active
{
if %timer_primary > #sCnt2
return
event macro 35 0
set %timer_primary ( #sCnt2 + 60 )
wait 5
}
return
I'm coffee lagged and can't determine if that is what I'm looking for? It seems like it.... Check the pixel, if it's NOT lit up that means I just armor ignored.
Anyways, need a fresh set of eyes on this, I'm not even sure I'm in the ballpark here.
Ultimate would be to include a different cmppix while waiting for the armor ignore

, like 3 lightning strikes - 1 armor ignore pattern.