Remap Grave / Tilde key

Discussions about stuff that isn't Hardware. Keep it legal, or at least vague enough to cover my ass if the lawyers gets on my case.
User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Remap Grave / Tilde key

Postby Mort » Tue Jul 24, 2012 12:20 pm

The AutoHotkey method
(WARNING:This works, but it seems that Punkbuster detects AutoHotKey running and assumes you are using it to create cheat macros. What a bunch of dicks)

Using a free utility called AutoHotkey I got the remapping to work. You can download it from here:
http://www.autohotkey.com/

*and/or* just download the following script and .exe I created
GraveRemap.zip

I don't think you need to download the full program if you just use the compiled version in the attachment.

In the zip file is the Autohotkey script to remap the key, and "GraveRemap.exe". Just run that before you run BF3, or add it to your Windows startup and it should take care of things. It's also possible to make it work *only* when BF is running. I'm not going to bother writing it to do that though unless someone actually needs it. You can always just close the program to "undo" the change.


(WARNING - While the following idea is good, it doesn't work in Battlefield)
I'm keeping this method here for interest even though it doesn't work in BF3

I finally got fed up with hitting the grave key and opening the Battlefield console whenever I tried to switch to my primary weapon (1) in Battlefield, so I worked out how to remap the key instead.

The attached file has two .reg files. Grave-kill.reg and Grave-restore.reg
  • Grave-kill.reg will create a scancode mapping to change the Grave/Tilde key to be the same as the 1 key so if I do hit it by mistake, it will still switch to primary weapon anyway. Unfortunately you need to restart Windows after making the change for it to take effect.
  • Grave-Restore.reg will delete the key and restore it back to normal function. Again a restart is required to take effect.

I can't actually recall the last time I used the grave or tilde keys so I don't see it as being a problem. If you do need to use the keys then you can:
  • Always change back using "grave-restore" and reboot
  • Use the Windows "on-screen" keyboard (press your Windows key and start typing "keyboard")
  • Use the ALT and number pad keys (Hold the ALT key while typing the number using your number pad)
    Alt-96 = `
    Alt-126 = ~

grave-remap.zip


grave-kill.reg

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,02,00,29,00,00,00,00,00


grave-restore.reg

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=-



Other interesting links:
List of ALT-numpad ascii codes
RandyRants Sharpkeys utility to remap keyboard keys
An Explanation of the ScanCode map reg key on howtogeek.com
You do not have the required permissions to view the files attached to this post.
Image

User avatar
Piers
Comfortable with my sexuality
Comfortable with my sexuality
Posts: 1408
Joined: Fri Dec 02, 2005 7:57 am
Location: Horse country

Re: Remap Grave / Tilde key

Postby Piers » Wed Jul 25, 2012 12:09 am

Nice one, I'm constantly doing that and it takes a moment (too long, usually) to realise what's happened.
Image

User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Re: Remap Grave / Tilde key

Postby Mort » Sat Jul 28, 2012 1:52 am

Hmm, it would appear this may not work as well as I thought. For some reason now the grave key is opening the console again, but once it's opened that key then acts as the remapped 1! key and you can't close the console!! The only way to get out is to switch to desktop and kill the BF3 application!

Will need to test some more, it might just be something related to Win8 or my keyboard.

Piers, have you used this, and does it work for you?
Image

User avatar
Piers
Comfortable with my sexuality
Comfortable with my sexuality
Posts: 1408
Joined: Fri Dec 02, 2005 7:57 am
Location: Horse country

Re: Remap Grave / Tilde key

Postby Piers » Sat Jul 28, 2012 1:45 pm

I'm just about to try it out, thanks for the warning...
Image

User avatar
Piers
Comfortable with my sexuality
Comfortable with my sexuality
Posts: 1408
Joined: Fri Dec 02, 2005 7:57 am
Location: Horse country

Re: Remap Grave / Tilde key

Postby Piers » Sat Jul 28, 2012 2:11 pm

Definitely doesn't work... :( I'm logging off and fixing it back to normal.
Image

User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Re: Remap Grave / Tilde key

Postby Mort » Sat Jul 28, 2012 6:07 pm

OK, got a better solution.. I've updated the first post with the AutoHotKey method which worked when I tested it.
Image

User avatar
Piers
Comfortable with my sexuality
Comfortable with my sexuality
Posts: 1408
Joined: Fri Dec 02, 2005 7:57 am
Location: Horse country

Re: Remap Grave / Tilde key

Postby Piers » Sat Jul 28, 2012 7:09 pm

We used autohotkey to fix something in BF before - was it BC2? - to do crouching or something.
Image

User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Re: Remap Grave / Tilde key

Postby Mort » Sat Jul 28, 2012 10:10 pm

dunno, I can't find any mention of it on the forums before, so if there was then you must have kept it to yourself. :)
Image

User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Re: Remap Grave / Tilde key

Postby Mort » Sun Jul 29, 2012 12:39 am

Oh FFS!

It looks like AutoHotKey is a BANNED program for BF3 that Punkbuster picks up. If it sees it running for more than 20 minutes it kicks you. At least that's not as bad as what it did in February when they first enabled the detection, it BANNED everyone who had it running.

So if you get kicked with this error "RESTRICTION: Disallowed Program/Driver 89262" it might be because of this

So we're screwed on that one as well....

I've sent a support ticket to PB to clarify, not sure if I'll get a response or not. It seems like 2 days ago someone started a DDos attack on them and their systems are offline. They are "thrilled" because to them it means they must be doing a really good job if someone wants to go to the effort of shutting them down. Considering how long PB has been around for, it hasn't changed a single bit as far as actual information about what it is doing goes.
Image

User avatar
Piers
Comfortable with my sexuality
Comfortable with my sexuality
Posts: 1408
Joined: Fri Dec 02, 2005 7:57 am
Location: Horse country

Re: Remap Grave / Tilde key

Postby Piers » Tue Jul 31, 2012 10:18 am

I was going to say that autohotkey was banned for BF2 but forgot to, so I'm not surprised.
Image

User avatar
Mort
Alpha-Forum Whore
Alpha-Forum Whore
Posts: 4232
Joined: Thu Dec 01, 2005 10:40 pm

Re: Remap Grave / Tilde key

Postby Mort » Tue Jul 31, 2012 1:05 pm

I got a reply from EvenBalance - "Windows8 is not a currently supported OS..."

There should be another keymapper type thing around that will work, that PB hasn't blocked yet. Considering how much they obviously *hate* macro recorders I'm surprised I'm even allowed to play BF3 with a G19 keyboard!
Image


Return to “Software”

Who is online

Users browsing this forum: CommonCrawl [Bot] and 0 guests