Sign in to follow this  
Followers 0
omglol

Auto Button Presser

15 posts in this topic

ok, i've got this:

; ----------------------------------------------------------------------------
;
; AutoIt Version: 3.1.0
; Author:        A.N.Other <myemail@nowhere.com>
;
; Script Function:
;   Template AutoIt script.
;
; ----------------------------------------------------------------------------

; Script Start - Add your code below here

while 1
send("s")
sleep(200)
wend

i want the code to basically non-stop press the letter S every .2 seconds or so, this is the pick-up button in an online game.

if i make it a .exe it doesn't work, and I also want to add that i can start the script with the Home button and stop it with End.

Share this post


Link to post
Share on other sites



What exactly do you need help with?

Share this post


Link to post
Share on other sites

What exactly do you need help with?

this doesn't work, when it needs to pick up an item, wich needs to be done with pressing the letter S on my keyboard, it doesn't, it only spams the message bar with the letters S.

so what i need is, an auto item pickup script.

Share this post


Link to post
Share on other sites

this doesn't work, when it needs to pick up an item, wich needs to be done with pressing the letter S on my keyboard, it doesn't, it only spams the message bar with the letters S.

so what i need is, an auto item pickup script.

Then learn how to code, and try the tutorial I gave you from the other post in the Scripts and Scraps forum. Only effort put forward is rewarded 99% of the time in this forum. If you want someone to write it for you, then go to rentacoder.com and bid for it.

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

To start and stop w/ home and end, look into hotkeyset

Tutorial:

Add this to top of code:

HotKeySet("{HOME}", "Start")
HotKeySet("{END}", "Stop")
oÝ÷ Øh¯z+l¢kax-¡Ú0)^ÜÛ¢¼¨ºÚ)­ë,d{&®¶­s`¥vÆR¥6ÆVW3¥vVæ@ oÝ÷ ØƤ{*.­ÊzØ^²Ö«µû§rب«­¢+Ø)Õ¹MÑÉÐ ¤(íe½ÕÈ
½!É)¹Õ¹(

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

i did read that tutorial, i've just started and i don't have a clue where to begin.

Edit: thanks paulie, now i need to get that code :D, will the one i started with work?

Edited by omglol

Share this post


Link to post
Share on other sites

i did read that tutorial, i've just started and i don;t have a clue where to begin.

The completed code above (thats in the "So all together") is where to start

Copy that into your script, and where i said

;Your code Here

You put the code that actually does whatever you need it to do

Note:

sending keys in games might not work, because some games prevent other programs from sending keys or mouse movements intentionally to stop cheaters

Share this post


Link to post
Share on other sites

i did read that tutorial, i've just started and i don't have a clue where to begin.

Edit: thanks paulie, now i need to get that code :D, will the one i started with work?

Read? That was an interactive tutorial :wacko: ...

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

That one gave an error and quit

Share this post


Link to post
Share on other sites

That one gave an error and quit

If you "read" the instructions before you just downloaded and gave it a go, it requires AutoIt Beta, which it provided the option to download as well.

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

To send the key "S" instead of the letter, use:

Send("{S}")

Everything you need to know is in the help file.. very easy script to write. :D

Share this post


Link to post
Share on other sites

By message bar, do you mean a text area? You have to click out of the text area so that it does not have the focus.

If you want AutoIt to only send to the game, use the info tool to find the control to ControlSend(..., "s") to the game area.

Share this post


Link to post
Share on other sites

To send the key "S" instead of the letter, use:

Send("{S}")

Everything you need to know is in the help file.. very easy script to write. :D

I don't think that thats correct

you only need the {}'s if its a special key like {HOME} or {ESC}

because it sends the key {ESC} with the brakets but just types "esc" without them

and you want it to push "s", and "s" is not a special key

Share this post


Link to post
Share on other sites

#15 ·  Posted (edited)

I don't think that thats correct

you only need the {}'s if its a special key like {HOME} or {ESC}

because it sends the key {ESC} with the brakets but just types "esc" without them

and you want it to push "s", and "s" is not a special key

You may be right.. the help file doesn't make clear if it sends an actual S or the action associated with "S", whatever that may be.

From what I gather (I may be wrong), Send("S") would send an uppercase S to the window. Send("{S}") would actually invoke the action involved with pressing S on the keyboard, instead of sending the letter to the window.

Kinda confusing. :D

Edited by Somniis

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