Sign in to follow this  
Followers 0
DemonSlayer

Pausing script so it will push a button, then resuming.

4 posts in this topic

I am trying to make a script to push 1, 2, 3, 1, 2, 3, 4 for me, simple enough. Well, i want it to push 8 every 150 seconds. I was thinking of making it do 1, 2, 3, 1, 2, 3, 4, 8 but that would waste time as i have a 4 second delay in it. I was also thinking of just copy/pasting the 1, 2, 3, 1, 2, 3, 4 parts until the script goes for 150 seconds, then adding the 8 at the end. But that would be 300+ lines long just to do something really simple. Any way around this :S thanks for any help.

Share this post


Link to post
Share on other sites



Well, when I posted this I was talking with my friend about it and we didn't know what to do. I was at a total loss on how to do it so I hadn't really started the script, I just knew what I wanted. But after working and thinking and combing through the help file and doing the syntax check production I have an idea on what I'm doing. I dont know if it will work as the game server is down atm so I cant test and I'm still having syntax check errors on my toggle pause. I've never had pause work right ~_~

CODE
$pausekey = "{F11}"

$exitkey = "{ESC}"

Sleep (5000)

While 1

$begin = TimerInit()

send1231234()

Send("4")

Sleep(3000);delay 3 sec

;resume loop

Wend

Func send1231234()

Do

Send ("{1}")

Sleep (2000)

Send ("{2}")

Sleep (2000)

Send ("{3}")

Sleep (2000)

Send ("{1}")

Sleep (2000)

Send ("{2}")

Sleep (2000)

Send ("{3}")

Sleep (2000)

Send ("{4}")

Sleep (3000)

Until TimerDiff($begin) > 155000

EndFunc

Func TogglePause()

$Paused = NOT $Paused

While $Paused

sleep(100)

ToolTip('Script is "Paused"',0,0)

WEnd

ToolTip("")

EndFunc

Func Terminate()

Exit 0

EndFunc

Share this post


Link to post
Share on other sites

Have your loop handle the 1,2,3,4 stuff and let an AdLibEnable() function interrupt that periodically with your 8.

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0