Jump to content

Help with a script


Recommended Posts

Sorry for double post but I cant find edit post lol..

Anyway, I want to create a code that presses Space 5 times then presses 5 once.

I tried it like this :

While 1

Send("{SPACE}")

Sleep(250)

Send("{SPACE}")

Sleep(250)

Send("{SPACE}")

Sleep(250)

Send("{SPACE}")

Sleep(250)

Send("{SPACE}")

Sleep(250)

Send("{5}")

Wend

But, dunno why, it presses "5" not every 5 "spaces" but like every second. I dont understand ><

Link to comment
Share on other sites

The 250 you have in sleep is 250 milliseconds

It's probably pressing the space so fast that whatever is recieving the space can't catch them all

The While 1 simply means "While true" or loop always.

Edited by kaotkbliss

010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Link to comment
Share on other sites

Send("{SPACE 5}")

If you want to slow down the keystrokes you can use

Opt("SendKeyDelay", 45) ; typing delay 45 milliseconds

010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Link to comment
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
 Share

  • Recently Browsing   0 members

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