Controls, Key bindings
8 years ago
Jamaica

Greets!

I'm interested in what gear to use, and how to configure it to control GTa2 comfortably.

Some related questions:

Which hardware is the best? (keyboard/mouse/controller/etc.) Are some keyboards better than others? (like mechanical types) How to bind your keys for efficient usage? (no blocking keys obviously, but other than that) What about using scripts? (like autohotkey)

Cheers, Mr. Assman

Jamaica

Here is my story:

I use a decent Microsoft keyboard with keys binded to near the arrow keys. Unfortunately my keystrokes are too long, thus it's really hard to make delicate movements. Driving high speed on the sidewalk, or aiming precisely at a certain direction is troublesome. To overcome my limitations I created a script in autohotkey, which I post at the bottom.

(Apologise for my limited scripting knowledge, but I'm new to this. I use modified sample scripts from other sites. Any correction/tip is appreciated.)

The script contains a toggle button for turning itself on/off (if you want to go back to windows): press "F12" to suspend/unsuspend script

It contains a script for sending the smallest amount of "keystroke" of certain keys: pressing "a" sends one press of "left arrow key" pressing "d" sends one press of "right arrow key"

Also I added a toggle rapid fire button for kill frenzies: pressing "f" once acts like the "right shift" button is pressed every 100ms. press "f" once again to stop rapid fire

The keys can be customized in the script text.

; AUTOHOTKEY SCRIPT STARTS HERE: ; Toggle Suspend Hotkey ; for turning on/off the whole script f12:: Suspend return

; Send the smallest amount of a target character ; hotkey: a:: ; target character: Send {left}

Sleep, 100 return

; hotkey: d:: ; target character: Send {right}

Sleep, 100 return

; Toggle Rapidfire toggle = 0 #MaxThreadsPerHotkey 2

; hotkey: f:: Toggle := !Toggle While Toggle{

; NOTE#1: right shift may cause a warning of stuck keyboard button in windows
; NOTE#2: if you change this to an alphanumeric character, you may be surprised what it does outside the gaming environment
; fire button:
    Send {RShift}

    Sleep, 100
}

return

Germany

Hello, Mr. Assman. To answer your questions:

  1. Use keyboard, controllers don´t even seem to work properly with that game on PC.

  2. I don´t know, maybe. I played on different keyboards, like also on an inbuilt one on my laptop too, doesn´t really matter, as long as the response time is good and it feels comfortable.

  3. Use the standard layout, it´s very good as it is. All buttons are next to each other, besides the honk/fart button which is tab. I see how that might be annoying, but the rest is placed good. No need for WASD, this game doesn´t need to use mouse, so you can have both of your hands on the keyboard.

  4. No scripts, pressing buttons for as long as needed and getting the right feeling for it is a skill too, which differs a good from a worse player. Besides that, making a program do extra inputs for you sounds like tool assistance much, although i don´t see how it would help you, but that´s not the point anyway.

Jamaica

Hello Molotok, thanks for the quick response!

I created this script to get Token 17 in Industrial district (Token 49 is similar too). This one requires a long precise jump with a cop car, near the russian green phones. (see: http://gta.wikia.com/File:Industrial.jpg for token numbers) The hard part is that you have to approach the ramp in a specific angle. You have to adjust at the very last second! Nevertheless I can do it after 5-10 tries (without script).

The challenge here is to push a key for the shortest amount of time. This requires skill & feeling your keyboard (just as you said), but trying out different keyboards might also help.

The toggle rapidfire button is just for fun. You can "poop" a long line of vehicle land mines if you wish, and other silly stuff. It's not a very useful one, I agree.

I really enjoyed watching your videos, I hope you can complete a 100% run for each district.

Mr. Assman

Germany

You can actually get this token 17 (and also some others) with this easy trick (Select molotovs or grenades and press rapidly, before the animation is finished, the fire button after a jump and then let the animation finish at the point you want to be. You will get elevated at the height you started from):

http://www.dropbox.com/s/q7d4q8qq8od3gfj/ind_token17.avi?dl=0

I would use this in a speedrun, but for token 49 the fast car would be more convenient. About the 100%: don´t know when/if they will be finished, but maybe one day. )

Jamaica

Yeah, I would prefer the flying glitch too, it's much more reliable. However I'd like to test out some keyboards. I wanted to do some tests a long time ago, so this seems a good opportunity to do so. Unfortunatelly I mostly have budget keyboards, so that's what I'm gonna test on :P.

I have constructed two tests for testing keyboards for gaming (for GTa2 especially). Although I mostly had negative results, I'll publish them here, so someone might learn from it:

A) TEST DESCRIPTIONS:

Test 1, Measure DEPRESS TIME with Passmark Keyboard Test (30 day trial version, http://www.passmark.com/products/keytest.htm). Depress time means the time passed between pushing and releasing a button. The shorter time you can get, the finer your steering is in driving games. In this test I put my right index and middle finger on the left arrow key, then try to press it as gently as possible to reach the lowest depress time possible. I do this 20 times in succession, write it down, then calculate the average and standard deviation in excel. Unfortunatelly this software doesn't create a log file/statistics about which keys you press, so you have to do it manually. Otherwise I would have made a bigger sample.

Test 2, STUNT: Jump the ramp towards Token 17 in Industrial The ramp is near the Russian green phones. First get a cop car. Start on the Krishna/Russian border, or a little further. That will give you enough space to reach maximum speed. When you reach the ramp turn slightly right. The jump is only successful, if the cop car stays on the roof of the house (and doesn't blow up). The trick is to aim the very left side of the rooftop. First I practiced a little with each keyboard (30-60 minutes each), then made 20 jumps in succession. I use arrow keys to drive. My right index finger turns left, middle finger accelerates, and ring finger turns right. In this test I heavily used the aid of debug keys (transport back to starting point, repair vehicle, get rid of police). Otherwise it would have taken days.

B) TEST KEYBOARDS AND RESULTS:

Mitsumi KFK-EA4XT keyboard (DIN connector converted to PS/2, ~1997) Thoughts: very old, keys are moving too hard, too unreliable Test Results: Depress Time: 65,4 +/- 36,6 ms (deviation is way too high to be reliable) Stunt Success: 5/20

Smart Ez-9900 keyboard (PS/2, 2003) Test Results: Depress Time: 34,0 +/- 10,1 ms (best of all keyboards) Stunt Success: 8/20 (best of all)

Clevo laptop (embedded keyboard, 2003) Test Results: Depress Time: 71,3 +/- 15,1 ms Stunt Success: 7/20

Microsoft Comfort Curve Keyboard 2000 (USB2.0, ~2009) Thoughts: this is my current keyboard, pretty good for typing Test Results: Depress Time: 69,2 +/- 13,0 ms Stunt Success: 5/20

Acer Netbook (embedded keyboard, 2013) Thoughts: arrow keys have half the size of a normal key, not comfortable Test Results: Depress Time: 64,9 +/- 17,7 ms Stunt Success: 6/20

Script (works with autohotkey) Test Results: Depress Time: 1,0 +/- 0,0 ms (no keyboard can match this) Stunt Success: 7/20

C) Conclusions

#1 Take everything with a grain of salt. This isn't rocket science.

#2 The goal here was to find a reliable test that can decide which keyboard is the better. I think I've failed. The difference between keyboards is much smaller than I thought. To come up with distinguishable results you may have to continue this test up to a 100 trials or more, which is a waste of time (considering its only a special task).

#3 Tried googling "keyboard test software for gaming", or "keyboard gaming reliability tests" and so on, with no relevant results. There are tons of software which tests touch-typing precision, but none for gaming apparently.

#4 I've been disappointed with my Microsoft keyboard. Considering that I've been using it for quite a while, and I practised the most with it, I expected better results. Quite reliable and comfortable for typing, but not for gaming.

D) To sum it up

You can play this game with pretty much any keyboard you have. On the long run however, you may want to test out for yourself which one is right. (pretty much the same what Molotok said 3 posts ago)

What is your opinion of testing keyboard for gaming (or for GTa2)? What kind of tests would you prefer?

Mr. Assman

Jamaica

Hi there!

It just came to my mind that GTa2 moves 30 frames per second, which is 33ms per frame. This could very well mean, that input signs that are shorter than 33ms are treated the same. So I'm gonna test this.

I have created a script which makes a button push for a certain period of time. I have tested this with 9 different values + with my original script (I pasted the script below).

First I measured the depress time for every script value with PassMark KeyboardTest. I got these values respectively: 1.1 ms 9.0 ms 23.3 ms 40.6 ms 54.6 ms 56.5 ms 71.5 ms 85.8 ms 101.0 ms 116.7 ms Note that measured values are differ from the times in the script by 10-15ms (that's why I had to measure them with PassMark). Also these values are averages of 20-20 measured value, and have standard deviation of 5ms.

Second I started spinning with Claude. I counted how many button pushes does it take to make a full 360 degree turn. From this I calculated the degrees of 1 turn, see on the chart below:

http://i.imgur.com/mktwco6.png

Conclusions:

#1: There is no difference in rotation between input times 1ms and 39ms (all of them make a 5 degree turn, or it takes 72 pushes to make a full circle). This means that if you are capable of making 33-39ms pushes with your keyboard, you can play GTa2 to a full extent.

#2: PassMark KeyboardTest measures depressing time very accurately, or at least it measures similarly as GTa2. Therefore we can use it later for benchmarking keyboards.

#3: Key 5 must be a measurement error or some weird bug. I have no idea why it's out of range.

#4: The formula for rotation is ( time/3 - 8 ) degrees if the time is greater than 39ms, and 5 degrees if the time is less than 39ms.

Cheers, Mr. Assman

SCRIPT FOR AUTOHOTKEY

; Custom function to hold down the Left Arrow key button for a given time of milliseconds HoldLeftFor(time_in_ms) { Send, {Left down} Sleep, time_in_ms Send, {Left up} Sleep, 100 }

; Mapping the custom function to keys 1-9 1::HoldLeftFor(0) ; Measures a 9.0ms key push on my system 2::HoldLeftFor(1) ; Measures a 23.3ms key push on my system 3::HoldLeftFor(30) ; Measures a 40.6ms key push on my system 4::HoldLeftFor(40) ; Measures a 54.6ms key push on my system 5::HoldLeftFor(50) ; Measures a 56.5ms key push on my system 6::HoldLeftFor(60) ; Measures a 71.5ms key push on my system 7::HoldLeftFor(70) ; Measures a 85.8ms key push on my system 8::HoldLeftFor(90) ; Measures a 101.0ms key push on my system 9::HoldLeftFor(100) ; Measures a 116.7ms key push on my system

0:: ; One tiny-tiny "tap" of the Left Arrow key Send, {Left} ; Measures a 1.1ms key push on my system Sleep, 100 return

Germany

My opinion on testing keyboards for GTA 2 is as said before and what your test showed: it doesn´t matter what kind of keyboard you use, as long as you get the timing right with it. Hardware doesn´t matter for this game unless you run it on a Pentium or something. xD

I prefer speedrun related tests. Useful would be a program which outputs distances, speed and times in a log file while you are running the game and test different routes.

Jamaica

Ah, good old pentium. Back then when you destroyed J-Lab the system would immediately run out of resources, and you could watch the glorious fiery explosion in slow-mo :)

For speedrun tests, there is a "Log Routefinder" option in debug mode, which I believe does saves your coordinates at any given frame. It's saved into a textfile, into GTA2/test/warning.log. All you need is to somehow decode this information.

Germany

You mean the enhanced gta2 manager where you can select the debug tab? There is such an option "log routefinder", but it doesn´t do anything and there is also no folder named test, only in the 11.44 version, but it doesn´t do anything there too.

Jamaica

I was wrong about the "Log Routefinder" option. It seems to generate the same 330 lines (in Industrial), no matter what. So it's only a list of the junctions I guess, a check at the beginning, not frame-by-frame logging.

More about the log options:

I have version 11.44 and I also installed GTA2 Game Hunter, so that could be it. In my test folder I have 17 replay files, an error.log, a don't-delete-this-folder.txt and a warning.log.

There are 4 loggin options in debug mode. I've tested this a little in Industrial. The data is dumped to the warning.log file, when you close the game. It overwrites the previous content.

#1 Log Routefinder: logs all the junctions (not per frame, just the list of all the junctions :( ) sample line: (first number is the juncion ID) Junc: 329 (173, 250) n 326 s 0 w 0 e 0

#2 Log Random: every random number generated by RNG, about 30-40 per frame sample line: (first number is the frame) 5: random (get_int) 164

#3 Log Input: all the input made by the user sample line: (first number is the frame) 39: control_status = 2928645

#4 Log DInput: some sort of input check in the beginning, always 5 lines the whole game sample line: (first number is the frame) 21: input num_items = 1 dwOfs = 12; data = 0

Jamaica

I overlooked one option: "Do Mission Logging" in debug mode. This saves any mission related events into test/MISSLOG.txt. Sample lines: 5499: 1523 5499: 790 5500: 1523 5500: 790 5501: 1246 5501: 1523 5501: 790

format: #Frame: #eventID1 #Frame: #eventID2 #Frame: #eventID3

The number of columns change in time. Usually there is one column for each active mission, and one for the whole game. If I plot the data in excel you can see the intervals:

http://i.imgur.com/NG3iA4G.jpg (imported the text into excel with TAB, space and semicolon as separators, and created a scatter plot chart)

I started Zaibatsu green mission: Wheeler Dealing, then followed the same route as you did in your 100% run. I picked up the token and completed the same kill frenzy. As it shows on the chart, tokens and wasted/busted events don't show up in the log file.

The Pros: Logging of all the mission events with frame precision.

The Cons: We don't know which ID number is for which mission. First an ID number - Mission event lookup table must be constructed, which takes a lot of time.

Germany

Thats´interesting, does this option start when the level is loaded and end when you are on "area complete" or menu screen? Then it could be used to frame precisely measure time for the runs. Currently we use start of first non-black frame and end of first black frame, so would be interesting to know the difference, although i know that when you first start the game the first time the level is loaded slightly longer and you might already do some input while the screen is still black.

Jamaica

To display the elapsed frames since the start of the level, turn on "Show Cycle" in debug mode. It is the most useful feature for time measurement. With this on I've managed to pause the game at frame -1 (eg. the frame number display wasn't even on yet).

In the mission log file each row is one frame, hence it's easy to plot this in excel. You can treat each mission as a sequence of numbers, one number per each (mission) frame.

For the "game column", the starting sequence of eventIDs are these for the first 6 frames: 1283, 1284, 1369, 772, 774, 795, then 795 repeats until wheeler dealing starts (the tutorial mission doesn't change it), during the mission its 790 continuously, after the mission ends its 795 again.

Starting the wheeler dealing mission adds a new column and a new sequence of numbers: 938, 1594, 1595, 1383, 1385, 1386, 1387 (briefing message displayed at this moment), 1388, 1389, 1391, 1393, then 1393 repeats until the briefcase is collected, and so on. As you can see the mission has some initialization phase before it reaches its "wait until briefcase is collected" state.

Game stats
Followers
155
Runs
445
Players
26
Latest threads
Posted 5 years ago
2 replies
Posted 5 years ago
0 replies
Posted 5 years ago
19 replies
Posted 5 years ago
0 replies
Posted 6 years ago
24 replies