View Full Version : Stuck setting up movement keys
Rampage
12-09-2008, 08:11 AM
I have read the guide but i dont really see this in it
I only dualbox,2 windows,wow1 and wow 2
Now im trying to set it so if i press Up/down/left/right on wow1,it will only send the key to wow2
<Label w1 Local SendWinM wow1>
<Label w2 Local SendWinM wow2>
<KeyList MoveList Up,Down,Left,Right>
<Hotkey MoveList>
<If ActiveWinIs wow1><SendLabel w2><Key %Trigger%>
<Else If ActiveWinIs wow2> <SendLabel w1><Key %Trigger%>
<Else><SendFocusWin><Key %trigger%>
Kinda new to this..Any suggestion?This does break my follow but my 2nd char doesnt seem to move
olipcs
12-09-2008, 08:27 AM
Hi!
There is a command in HKN for movementkey, named <MovementHotkey> ('http://hotkeynet.com/ref/movementhotkey.html') .
With this you could do the task described above with:
<Label w1 Local SendWinM wow1>
<Label w2 Local SendWinM wow2>
<Label focus Local SendFocusWin>
<MovementHotkey up,down,left,right>
<If ActiveWinIs wow1><SendLabel w2><Key %Trigger%>
<Else If ActiveWinIs wow2> <SendLabel w1><Key %Trigger%>
<Else><SendLabel focus><Key %trigger%>
(this would do the following:
1. If you play on WoW1 and press the arrow-keys, its sends the corresponding arrow-key to WoW2
2. If you play on WoW2 and press the arrow-keys, its sends the corresponding arrow-key to WoW1
3. If you play neither WoW1 or WoW2 and press the arrow-keys, its sends the corresponding arrow-key to the window with the focus. )
Rampage
12-09-2008, 08:35 AM
I had originally set this but it gave me an error
<MovementHotkey up,down,left,right>
<If ActiveWinIs wow1><SendLabel w2><Key %Trigger%>
<Else If ActiveWinIs wow2> <SendLabel w1><Key %Trigger%>
<Else><SendFocusWin><Key %trigger%>
I'll try yours in a min or so and report if it works.thanks:D
olipcs
12-09-2008, 08:40 AM
hi, glad i could help.
The reason, why your version was giving you an error is the following:
Only PassThrough ('http://hotkeynet.com/ref/passthrough.html'), SendLabel ('http://hotkeynet.com/ref/sendlabel.html'), Key ('http://hotkeynet.com/ref/key.html'), If ('http://hotkeynet.com/ref/if.html'),Else ('http://hotkeynet.com/ref/else.html'), Endif ('http://hotkeynet.com/ref/endif.html') can be used inside of an <MovementKey> (stated on the MovementKey-Reference).
Thats why using <SendFocusWin> giving you an error.
Luckily Freddie was so kind to allow us to define a label for the FocusWin like:
<Label focus Local SendFocusWin>
so we can use the <SendLabel>-command in the <MovementKey> :)
Freddie
12-09-2008, 02:46 PM
The original hotkey should have generated this error message:
Movement hotkeys can contain only <Passthrough>, <SendLabel>, and <Key>
Did that not happen? Or was it impossible to figure out what the message meant? (Btw I need to update the message to include If-Else-EndIf.)
Freddie
12-09-2008, 03:16 PM
I changed the error message. The original definition will now generate this message:
<SendFocusWin> is not allowed in movement hotkeys. You can use <SendLabel>, <Key>, <PassThrough> and non-command keywords like <If>, <Toggle>, and <ApplyTemplate>.
Hopefully this will be easier to understand.
vBulletin® v4.2.2, Copyright ©2000-2025, Jelsoft Enterprises Ltd.