Go Back   Flash Flash Revolution > Flash Flash Revolution > FFR General Talk
Register FAQ Community Calendar Today's Posts Search

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 04-30-2006, 07:00 PM   #1
jwcgator
RIP ffrtokens
FFR Veteran
 
jwcgator's Avatar
 
Join Date: May 2005
Location: Florida
Posts: 2,220
Send a message via AIM to jwcgator
Smile Mapping Keys in FFR (WITH IMAGES) !!!!UPDATE 6/11/07!!!


use ffr built in keymapping.

but continue to read if you want to use a pad or R2/Resonance

NOTE: I have updated the actual code that you put into the ahk script, it allows you to suspend the script and unsuspend the script at a single keypress. Scroll down to see it


Tired of having to use <V86 as a pseudo-spread setup in FFR? Tired of having to get accustomed to 2 different setups between Stepmania and FFR? Well, you've come to the right thread. In this thread I'm going to be teaching you how to use a program called Autohotkey for your key mapping pleasures.

TABLE OF CONTENTS

A. Setting up Autohotkey
B. Setting up the Autohotkey script
C. Running the Autohotkey Script
D. Closing the Autohotkey script
E. Other Cool Stuff
F. Troubleshooting

A. Setting up Autohotkey

Step 1: Download Autohotkey
Step 2: Install the program by double clicking the AutoHotkeyInstall.exe that you downloaded. (It would be wise that you restart the computer after installation)

B. Setting up the Autohotkey script

Step 1: Right click on the desktop, go to New, then click on New Autohotkey Script.


Step 2: Right click the New Autohotkey Script.ahk on your desktop and click Edit Script.


NOTE: THOSE CODES WILL NOT WORK ON RESONANCE OR R2, ONLY ON R1.

Step 3. Add the following code to your script:
Code:
a::Send {left}
s::Send {down}
k::Send {up}
l::Send {right}

;Do not delete this, it allows you suspend and unsuspend the script at any ;time with 
;a simple press of the ` button (next to the number on on the number row ;above the letters on your keyboard

`::Suspend
Step 4: Edit the letters before the ::'s to your choosing. The arrow setup for FFR is (LEFT)(DOWN)(UP)(RIGHT) For example, I have my script set up as
Code:
;
; AutoHotkey Version: 1.x
; Language:       English
; Platform:       Win9x/NT
; Author:         A.N.Other <myemail@nowhere.com>
;
; Script Function:
;	Template script (you can customize this template by editing "ShellNew\Template.ahk" in your Windows folder)
;

m::Send {left}
,::Send {down}
.::Send {up}
/::Send {right}

;Do not delete this, it allows you suspend and unsuspend the script at any ;time with 
;a simple press of the ` button (next to the number on on the number row ;above the letters on your keyboard

`::Suspend
Step 5: SAVE IT.

C. Running the Autohotkey Script

Just Double click the New Autohotkey Script.ahk. Simple as that.

D. Closing the Autohotkey script

Right click on the green H in the task bar and click Exit.


E. Other Cool Stuff

SUSPEND HOTKEYS:
add this to your code if you havent already:

;Do not delete this, it allows you suspend and unsuspend the script at any ;time with
;a simple press of the ` button (next to the number on on the number row ;above the letters on your keyboard

`::Suspend

MAKING AN EXE:
This is very useful. Right click on the script and click Compile Script. This will make a portable EXE that you can put on other computers and use as FFR hotkeys without installing AutoHotKey Numerous times.


F. Troubleshooting

My script isn't running or I get an error message when I start up the script!
-Make sure that the syntax is correct. Look at the example above and make sure it looks like that.

It won't exit!
-Yes it will. If for some odd reason it wont exit when you click exit(and make sure you're doing it right!) then just delete the script on the desktop.


Well that's about it. The reason I omitted using a pad is because no one wants to use a pad on FFR anyways lol. If you really want to, Figure it out yourself. If you want to use this somewhere else please ask permission because I worked hard on this.

If anyone sees anything wrong please tell me and I will fix it ASAP


*EDIT - An AHK code that works on R2/Resonance (thanks to the DtTvB)

Code:
#SingleInstance Force
JustEval(name, state) {
  Global
  If (jl%name% != "" && jl%name% != state) {
    jl%name% := state
    Return "Changed"
  }
  jl%name% := state
  Return "I"
}
Checkstate(name, state, key) {
  If (JustEval(name, state) != "I") {
    If (state) {
      Send {%key% Down}
    } Else {
      Send {%key% Up}
    }
  }
  jl%name% := state
}
JoyGet(b) {
  Global Joynumber
  Return GetKeyState("Joy" . b)
}
KGet(b) {
  Global Joynumber
  Return GetKeyState(b)
}
Loop {
  Checkstate("l", KGet("d"), "left")
  Checkstate("d", KGet("f"), "down")
  Checkstate("u", KGet("j"), "up")
  Checkstate("r", KGet("k"), "right")
}
`::Suspend
This code uses loop to check if a key is pressed and released.
This way it can work with freezes.


MRichards' Simple Alternative for Key Remapping
http://www.flashflashrevolution.com/...ad.php?t=77100

I've uploaded a very simple program to remap the cursor keys for FFR. I know this duplicates the work of jwcgator (AutoHotKey), but this is much simpler to set up, and has a minimum of timing delay:

http://www.latent.demon.co.uk/ffr_keymap.html

Screenshot:
http://www.latent.demon.co.uk/images...screenshot.jpg

The program defaults to remapping FFR R1, and can remap the cursors for other windows or programs too. It also supports dancepads, joypads, guitar controllers etc. Unfortunately, R2 and Resonance use low level keyboard access and it doesn't work with them.

Minimum Specification

Works in Windows XP and Windows Vista (may need to use "Run as Administrator" in Vista).
I'm afraid I'm not a Mac or Linux programmer, sorry guys...

NOTE:
To get the absolute minimum of timing delay, the program injects a message hook directly into the target window. This is flagged up as a potential attack by many firewalls and spyware programs - because accessing another window's messages could indicate unauthorised activity. In fact, the program is harmless and simply needs access to the keyboard messages to do its job. However, to be open, I've put the entire project and source code on the above site, so it can be checked and compiled by those who know how.
__________________

Last edited by jwcgator; 05-24-2008 at 09:53 PM.. Reason: Update
jwcgator is offline   Reply With Quote
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 03:42 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright FlashFlashRevolution