How to make a toggle with same floating button trigger?

PockyDot

New member
I am trying to make an auto-clicker toggle where if I click on the Floating Button trigger that I made, the macro will start. When it is already active and I click on the button trigger again, the macro will stop. How can I do this, if this is even possible? Thanks.
 

Snurre

Well-known member
You could use a variable (feks "running")and check it with an if when the button is triggered

If running=false
-Run macro
-Set var running=true
Else if running=true
-Stop macro
-Set var running=false
 
Top