Sign in to follow this  
Followers 0
Patftw

Problem with Sending Hotkeys

6 posts in this topic

#1 ·  Posted (edited)

While 1; Start looping continuously
Mouseclick("Right"); click the right mouse button
send("{Space}"); Hit spacebar
Send ("{`}"); hit `
Sleep(1000); sleep for 1 second
Wend;

This script is supposed to hit Spacebar, ` and to right click every second. But for some reason it only right clicks all the time. And i think sending the hotkey to the game isnt working aswell.

Is there a command to "hit" the Key somehow. Like making the Computer think that theres a Person actually hitting the Key all the time.

And im a newb in AutoIT, but im sure you guys gonna help me.

Thanks in advance.

Pat

Edited by Patftw

Share this post


Link to post
Share on other sites



Anyone got any ideas?

Share this post


Link to post
Share on other sites

Send("{SPACE DOWN}")

Sleep(100)

Send("{SPACE UP}")

Share this post


Link to post
Share on other sites

Thanks for your answer Generator

Btw is there some kind of Tutorial for AutoIT? A Tutorial which includes everything. Cause i`m making a bot for a game at the moment. I need a command to press a special key when my HP reaches for example 50 % of my HP.

For example a command that if the pixels turn from red to darkred (I ll find out the Farbcode for the exact color) then its going to press F1 for example.

Thanks in advance.

Share this post


Link to post
Share on other sites

The help file that is included in SciTe Editor is a very good place to look only a few tuts but you can search the help file and find almost everything you should need

Share this post


Link to post
Share on other sites

Thanks for your answer Generator

Btw is there some kind of Tutorial for AutoIT? A Tutorial which includes everything. Cause i`m making a bot for a game at the moment. I need a command to press a special key when my HP reaches for example 50 % of my HP.

For example a command that if the pixels turn from red to darkred (I ll find out the Farbcode for the exact color) then its going to press F1 for example.

Thanks in advance.

1. its AutoIt

2. look at AutoIt 1-2-3 and both helpfiles and online documents

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