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 

All day trying to remap two keys, please help

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Vickery
Guest





PostPosted: Sat Apr 05, 2008 2:37 am    Post subject: All day trying to remap two keys, please help Reply with quote

I thought that what I want to do would be fairly simple, but I've spent most of the day reading the help files and trying things, then hours more doing forum searches, and still no success. Sad My goal is to remap the orbit and pan controls in 3ds Max to some unused keys on my keyboard.

The way Max's navigation works is like this:

Press and hold middle mouse button while moving mouse = pans view
Press and hold middle mouse button + alt while moving mouse = orbits view

Instead I want to have something like this:

Press and hold Ctrl+Alt+J while moving mouse = pans view
Press and hold Ctrl+Alt+K while moving mouse = orbits view

If I can get that working I can then map Ctrl+Alt+J and Ctrl+Alt+K to the programmable buttons on my G11 keyboard which will be much easier on the arthritis I have in my hands.

I'm not a coder so I'm having a hard time with this. I almost had it working at one point but it sputtered and jerked and wasn't usable. I just want to do this one thing but I can't figure out the exact correct syntax to use. Can anyone help?
Back to top
Z Gecko
Guest





PostPosted: Sat Apr 05, 2008 6:31 am    Post subject: Reply with quote

try
Code:

^!j::Send {MButton down}
^!j Up::Send {MButton up}
Back to top
Vickery
Guest





PostPosted: Sat Apr 05, 2008 1:08 pm    Post subject: Reply with quote

Thank you for trying to help, but that's the same thing I came up with on my own which produced the jerking and sputtering problem.

Actually as far the pan goes, just doing this

Code:
#z::MButton


produces the desired result. But I can't get it to work with Alt+the Middle Button modifier for the orbit. This is what I tried

Code:
#x::!MButton


but it just ignores the ! and pans the same as the first example.

(By the way, I switched to #z and #x for the input keys because for some reason ^!j caused it to zoom rather than pan. (?) Weird. I don't understand why that would happen. It doesn't matter though because I'll be remapping them to Logitech G11 programmable keys anyway, so any keys will do.)
Back to top
TheLeO



Joined: 11 Jun 2005
Posts: 168
Location: England ish

PostPosted: Sat May 03, 2008 10:49 am    Post subject: Reply with quote

I've got a g11 myself,

its a problem with the keyboard itself, when you press the gbuttons
it will send a quick ctrl alt j and then repeat it, hence it's so jerky...

There would be a way, but it's a little complicated,

Try this.....

map one of your Gbuttons to something like

ctrl alt f1


and have this in your script
Code:


^!f1::
GetKeyState, state, Mbutton
if  state = D
Sendinput, {Mbutton Up}
Else if state = U
Sendinput, {Mbutton down}
Return



hope it work,

btw, if it does, or have you get stuck on something, pm me to let me know whats going on...

leo.


[edit,]

oh, i just read the post you did after the first one. nevermind
_________________
And i say: where there is a problem , there is a solution.(well some where that is.)
::
I Have Spoken
::
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
[VxE]



Joined: 07 Oct 2006
Posts: 1243

PostPosted: Sat May 03, 2008 12:16 pm    Post subject: Reply with quote

Code:
$#z::
Send {LAlt Down}{MButton Downtemp}
KeyWait, z
Send {MButton Up}{LAlt up}
return
How about that ?
_________________
My Home Thread [New: Vector Function Library]
More Common Answers: 1. It's in the FAQ 2. Ternary ( ? : ) guide 3. Post code with [code][/code] tags
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   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