AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Macro for game

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Misc



Joined: 29 Aug 2009
Posts: 15

PostPosted: Sun Aug 30, 2009 10:47 am    Post subject: Macro for game Reply with quote

Code:
#NoEnv
SendMode Input

_auto := true

~LButton::autofire()
Numlock::_auto := ! _auto
F1::ExitApp

autofire()
{
global _auto
if _auto
{
Loop
{
if GetKeyState("LButton", "P")
{
SendInput {LButton DownTemp}
Sleep 10
mouseXY(0, 6)
SendInput {LButton Up}
Sleep 45
}
else
break
} ;; loop
} ;; if
} ;; autofire()

mouseXY(x,y)
{
DllCall("mouse_event",uint,1,int,x,int,y,uint,0,int,0)
}


Its works good but when i shoot it brings the mouse downward right
i want it to go downward left
Is it possible?

[Title edited. Please write descriptive titles for your topics. ~jaco0646]
Back to top
View user's profile Send private message
R3TR0



Joined: 26 Aug 2009
Posts: 38
Location: Canada

PostPosted: Sun Aug 30, 2009 1:06 pm    Post subject: Re: Help with this script Reply with quote

Misc wrote:
Its works good but when i shoot it brings the mouse downward right i want it to go downward left
Is it possible?



Yeah I copied one of the other no recoil scripts and played with the ints in the dll call. no / less recoil and the added bonus of single fire at the rate of auto.

Code:

~lbutton::
loop
{
GetKeyState,updn, LButton, P
if updn = U
break

MouseClick, left,,, 1, 0, D
sleep, 5
MouseClick, left,,, 1, 0, U
DllCall("mouse_event", uint, 1, int, -3, int, 2, uint, 1, int, 1)
}
RETURN
Back to top
View user's profile Send private message
Misc



Joined: 29 Aug 2009
Posts: 15

PostPosted: Sun Aug 30, 2009 5:06 pm    Post subject: Reply with quote

Thanx man im going to try this right now
Back to top
View user's profile Send private message
Misc



Joined: 29 Aug 2009
Posts: 15

PostPosted: Sun Aug 30, 2009 7:05 pm    Post subject: Re: Macro for game Reply with quote

Misc wrote:
Code:
#NoEnv
SendMode Input

_auto := true

~LButton::autofire()
Numlock::_auto := ! _auto
F1::ExitApp

autofire()
{
global _auto
if _auto
{
Loop
{
if GetKeyState("LButton", "P")
{
SendInput {LButton DownTemp}
Sleep 10
mouseXY(0, 6)
SendInput {LButton Up}
Sleep 45
}
else
break
} ;; loop
} ;; if
} ;; autofire()

mouseXY(x,y)
{
DllCall("mouse_event",uint,1,int,x,int,y,uint,0,int,0)
}


Its works good but when i shoot it brings the mouse downward right
i want it to go downward left
Is it possible?

[Title edited. Please write descriptive titles for your topics. ~jaco0646]


Hey how to change this up and make it go down or somewhere else each time i click it instead of holding it
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group