Jump to content

A little noobi help? ^.^


Recommended Posts

Guest Ravenholtz
Posted

Sooo, i lend some stuff ( ;) ) from a script here at the forum and modified it to work for me but i need to learn the opposite of what i have done

I come from v2 and just started working with v3.

---------

HotKeySet("{PAUSE}", "TogglePause")

HotKeySet("!{PAUSE}","Quit")

Dim $Paused

TogglePause()

While

Start()

WEnd

func Start()

send("t")

send("1")

sleep(3100)

send("1")

sleep(3100)

send("5")

sleep(6200)

send("5")

EndFunc

Func TogglePause()

$Paused = NOT $Paused

While $Paused

WEnd

Start()

EndFunc

func Quit()

Exit

EndFunc

------------

This script does the start() func between when i press "Pause" button and when i press "Pause" again.

So far so good, But what i really need is for it to do some thing like this:

Start script

wait for a button press "Pause"

On Button press "Pause" do start() func.

Go back and wait for "Pause" again

Anyone?

Posted (edited)

Sooo, i lend some stuff ( ;) ) from a script here at the forum and modified it to work for me but i need to learn the opposite of what i have done

I come from v2 and just started working with v3.

------------

This script does the start() func between when i press "Pause" button and when i press "Pause" again.

So far so good, But what i really need is for it to do some thing like this:

Start script

wait for a button press "Pause"

On Button press "Pause" do start() func.

Go back and wait for "Pause" again

Anyone?

CODE

---------

HotKeySet("{PAUSE}", "Start")

HotKeySet("!{PAUSE}","Quit")

Dim $Paused

TogglePause()

While

Start()

WEnd

func Start()

send("t")

send("1")

sleep(3100)

send("1")

sleep(3100)

send("5")

sleep(6200)

send("5")

EndFunc

Func TogglePause()

$Paused = NOT $Paused

While $Paused

WEnd

Start()

EndFunc

func Quit()

Exit

EndFunc

WinWaitActive("3874938743")

Try the above code and see if it does what you want. Edited by ligenza
Guest Ravenholtz
Posted

Ty my friend! Worked like a charm! ;)

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...