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 

not registering mouse clicks
Goto page Previous  1, 2, 3  Next
 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
PurloinedHeart



Joined: 04 Apr 2008
Posts: 209
Location: Canada

PostPosted: Sat May 31, 2008 6:41 pm    Post subject: Reply with quote

I'm not sure, if all else fails, you can always write the script the
"long" way Laughing
Back to top
View user's profile Send private message
Z Gecko
Guest





PostPosted: Sat May 31, 2008 8:41 pm    Post subject: Reply with quote

you could also use alternative script/click recorders for ahk.

for instance this one (it records only left/middle/right-clicks):
Code:

;Simple Click Recorder Script
; This Script will record Left/Middle/Right Mouseclicks to be used as an ahk-script itself!

;Start of the autoexecution-section
#InstallMouseHook
SetBatchLines -1
Suspend, On
PrevTime = 0
TTMode = off
HelpMessage =
(
Press "Pause" to start/stop the click-recording.
Press "Escape" to show/update the GUI!
Press "Ctrl+Alt+M" to toggle the CoordMode.
Press "Ctrl+Alt+T" enable/disable a Tooltip showing your last action.
)
CurrCoordMode = relative
ScriptVar .= "CoordMode`, Mouse `, relative" . "`n"
CoordMode, Mouse , relative
Gui, Add, Text, w350, %HelpMessage%
Gui, Add, Text, w350 Center Cwhite, Your Script so far:
Gui, Add, Edit, w350 r35 vScriptDisplay
Gui, Add, Button, gCopytoClip, Copy to Clipboard
Gui, Add, Button, x+20 gClearScript, Clear Script

MsgBox, %HelpMessage%
;End of the autoexecution-section
return


;Hotkey to Show/Refresh the Gui that displays the created script

Esc::
Suspend, Permit
GuiControl, , ScriptDisplay, %ScriptVar%
Gui,Show, ,Simple AHK-Script Recorder
return


;Hotkey to enable/disable the click-recording Hotkeys

Pause::
Suspend
if A_IsSuspended = 1
   LastLine = Click Recording: OFF
else
   LastLine =  Click Recrding: ON
Gosub, affirmate
return


;Hotkey to Toggle the showing of affirmation-tooltips

^!T::
Suspend, Permit
if TTMode = on
   TTMode = off
else
   TTMode = on
LastLine := "ToolTip: Mode: " . TTMode
Gosub, affirmate
return

;the show tooltip subrutines

affirmate:
if TTMode = on
{
   ToolTip, %LastLine%
   SetTimer, RemoveToolTip, 1000
}

GuiControl, , ScriptDisplay, %ScriptVar%
return
RemoveToolTip:
SetTimer, RemoveToolTip, Off
ToolTip
return



;Hotkey to change the CoordMode of recording AND recorded script

!^M::
Suspend, Permit
if CurrCoordMode = relative
{
   CoordMode, Mouse , screen
   CurrCoordMode = screen
   ScriptVar .= "CoordMode`, Mouse `, screen" . "`n"
   LastLine := "CoordMode`, Mouse `, screen" . "`n"
}
else
{
   CoordMode, Mouse , relative
   CurrCoordMode = relative
   ScriptVar .= "CoordMode`, Mouse `, relative" . "`n"
   LastLine := "CoordMode`, Mouse `, relative" . "`n"
}
Gosub, affirmate
return


;Simple Click recording hotkeys for Left/Middle/Right-click

~LButton::
MouseGetPos, CurrPosX, CurrPosY
CurrTime := A_TickCount
if PrevTime > 1
{
   ElapsedTime := CurrTime - PrevTime
   ScriptVar .= "Sleep`, " . ElapsedTime . "`n"
}
ScriptVar .= "Click " . CurrPosX . "`, " . CurrPosY . "`n"
LastLine := "Click " . CurrPosX . "`, " . CurrPosY . "`n"
PrevTime := CurrTime
Gosub, affirmate
return


~RButton::
MouseGetPos, CurrPosX, CurrPosY
CurrTime := A_TickCount
if PrevTime > 1
{
   ElapsedTime := CurrTime - PrevTime
   ScriptVar .= "Sleep`, " . ElapsedTime . "`n"
}
ScriptVar .= "Click right " . CurrPosX . "`, " . CurrPosY . "`n"
LastLine := "Click right " . CurrPosX . "`, " . CurrPosY . "`n"
PrevTime := CurrTime
Gosub, affirmate
return


~MButton::
MouseGetPos, CurrPosX, CurrPosY
CurrTime := A_TickCount
if PrevTime > 1
{
   ElapsedTime := CurrTime - PrevTime
   ScriptVar .= "Sleep`, " . ElapsedTime . "`n"
}
ScriptVar .= "Click middle " . CurrPosX . "`, " . CurrPosY . "`n"
LastLine := "Click middle " . CurrPosX . "`, " . CurrPosY . "`n"
PrevTime := CurrTime
Gosub, affirmate
return


; Gui Handling Subroutines

CopytoClip:
Gui, Submit, Nohide
Clipboard := ScriptDisplay
MsgBox, Script copied to Clipboard
return

ClearScript:
ScriptVar =
CurrCoordMode = relative
ScriptVar .= "CoordMode`, Mouse `, relative" . "`n"
CoordMode, Mouse , relative
GuiControl, , ScriptDisplay, %ScriptVar%
return
Back to top
Guest






PostPosted: Sun Jun 01, 2008 2:55 am    Post subject: Reply with quote

his is what i have so far..


CoordMode, Mouse, Screen
MouseClick, left, 1655, 966
MouseClick, left, 1655, 966
Sleep, 100
MouseClick, left, 1623, 962
MouseClick, left, 1623, 962
Sleep, 100
MouseClick, left, 1584, 959
MouseClick, left, 1584, 959
Sleep, 100
MouseClick, left, 1593, 959
MouseClick, left, 1593, 959
Sleep, 100
MouseClick, left, 54, 422
Sleep, 100
Back to top
Zed Gecko



Joined: 23 Sep 2006
Posts: 101

PostPosted: Sun Jun 01, 2008 3:31 am    Post subject: Reply with quote

Quote:
his is what i have so far..

this is actually a working script, so you could run it directly. Smile
but you are probably better off, wrapping it in a hotkey.
for example, like this:
Code:

^!t:: ; creating a "Ctrl+Alt+T" Hotkey
CoordMode, Mouse, Screen
MouseClick, left, 1655, 966
MouseClick, left, 1655, 966
Sleep, 100
MouseClick, left, 1623, 962
MouseClick, left, 1623, 962
Sleep, 100
MouseClick, left, 1584, 959
MouseClick, left, 1584, 959
Sleep, 100
MouseClick, left, 1593, 959
MouseClick, left, 1593, 959
Sleep, 100
MouseClick, left, 54, 422
return ; end of the "Ctrl+Alt+t"-hotkey section

_________________
1) All my code can be reused in ANY way. 2) Please check the help and the forum-search, before posting questions; the answer is out there...
Back to top
View user's profile Send private message
Guest






PostPosted: Sun Jun 01, 2008 3:48 am    Post subject: Reply with quote

neither is working. when i have my documents open, i see the mouse move, but it doesn't do anything. when my documents isn't open, all it does is bring the game up to the top
Back to top
Zed Gecko



Joined: 23 Sep 2006
Posts: 101

PostPosted: Sun Jun 01, 2008 3:57 am    Post subject: Reply with quote

what do you mean with "when i have my documents open"?

Do you know how to create and launch a script?
http://www.autohotkey.com/docs/Tutorial.htm#Create
_________________
1) All my code can be reused in ANY way. 2) Please check the help and the forum-search, before posting questions; the answer is out there...
Back to top
View user's profile Send private message
Guest






PostPosted: Sun Jun 01, 2008 4:17 am    Post subject: Reply with quote

i mean the folder "my documents"
Back to top
Z Gecko
Guest





PostPosted: Sun Jun 01, 2008 4:30 am    Post subject: Reply with quote

So, do u mean:
you have saved a script with above contents in your "my documents"-folder.
you have started it with a double-click in the explorer on the script.
and you pressed the Ctrl+Alt+T hotkey, and you saw the mouse move but it click.

if so: are really shure? did you try to put something clickable at the coordinates in your script? 1584, 959 are high numbers, are you shure the active window big enough?

i suggest to start with simple script, that clicks something on the desktop, to check if this works first!

and give more information, nobody here is good at mind reading.
Back to top
Guest






PostPosted: Sun Jun 01, 2008 4:35 am    Post subject: Reply with quote

well, the game is fullscreen. tried DXWnd as suggested earlier, bu it still was fullscreen. and i know i'm new to this, but i'm explaining as best as i can....i'm telling you exactly what it's doing, what's open, etc. ask me for information and i'll give it to you. don't be a smartass Razz
Back to top
Z Gecko
Guest





PostPosted: Sun Jun 01, 2008 4:41 am    Post subject: Reply with quote

so please answer then:
Q1:
Quote:
you have saved a script with above contents in your "my documents"-folder.
you have started it with a double-click in the explorer on the script.
and you pressed the Ctrl+Alt+T hotkey, and you saw the mouse move but it click.

Q1:
Quote:
did you try to put something clickable at the coordinates in your script? 1584, 959 are high numbers, are you shure the active window big enough?

and
Q3:
did you open the game window and pressed the hotkey?
if yes, what happened?
Q4:
when "when my documents isn't open, all it does is bring the game up to the top", what windows were open?
Back to top
Guest






PostPosted: Sun Jun 01, 2008 4:45 am    Post subject: Reply with quote

A1: yes, it's saved in my documents, started with a doubleclick, and if mydocuments is still open, i can see the mouse move.

A2: yes, because the game is fullscreen, and that is near the bottom right corner

A3: when i open the game, and press the hotkey, nothing happens

A4: only the game was open, because it returned to fullscreen. everything else was in the background
Back to top
Z Gecko
Guest





PostPosted: Sun Jun 01, 2008 4:52 am    Post subject: Reply with quote

OK, then please check first,
if the hotkey is working on the desktop.
minimize all windows, to see only the desktop
and place a desktop-icon at coordinates, the script is clicking.
test and report if it the Mouseclicks work there.
Back to top
Guest






PostPosted: Sun Jun 01, 2008 4:59 am    Post subject: Reply with quote

works on the desktop
Back to top
Guest






PostPosted: Sun Jun 01, 2008 5:02 am    Post subject: Reply with quote

i know it does work on this game, because my giuld leader uses it, is the one who told me about it, and has been trying to get it to work for me. only thing we can figure is there must be some setting i neet to select/deselect because i'm on vista, or maybe running it in compatability mode which i'm about to try
Back to top
Z Gecko
Guest





PostPosted: Sun Jun 01, 2008 5:05 am    Post subject: Reply with quote

Ok, so itīs game-related.
this is often in issue, please read Why do Hotstrings, Send, and Click have no effect in certain games? !
Back to top
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Goto page Previous  1, 2, 3  Next
Page 2 of 3

 
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