Problem with Iskeypressed and Bluetooth keyboards?

Started by Ryan Timothy B, Fri 02/01/2009 01:19:00

Previous topic - Next topic

Ryan Timothy B

My brother finally played my Road Racer game, and he immediately told me that he broke my game.

I've tested it out with the debugger on his computer and using his Bluetooth keyboard. 
If individually pressed Iskeypressed comes up for Space (32), Left (375), Right (377) and finally Up (372).

Now for some odd reason while holding UP + RIGHT and then I press SPACE, 32 doesn't come up on the debugger.
If I press UP + SPACE then I press RIGHT, 377 doesn't come up on the debugger.

It only seems to have a problem with UP+RIGHT+SPACE, in any combination.  Which ever key is pressed last in the combination is the one left out.  LEFT or DOWN key don't seem to have any problems at all.

So in other words, no parking brake while pressing Up and Right at the same time.  Or no Right while pressing Up and Space at the same time.

For my controlling actions I am running Iskeypressed in the Globalscript in the Repeatedly Execute, for each control.  I assign it to a boolean (each direction has their own boolean).  Perhaps this is an issue, I don't know.

I don't even know if it's the keyboard alone that is causing these problems.  Perhaps Bluetooth has a problem with multiple keys at once, or it's simply something internally wrong with AGS.  I do not know.

If anyone has experienced these problems, know what I'm talking about, or know how to help me.  It would be greatly appreciated! :)

Or if there is anyway I could test to see what this problem is, let me know.

Oh, and I'm using Version 3.1

Gilbert

It's probably the keyboard.

Most keyboards have some restriction on how keys can be pressed simultaneously. like for example, restrict to at most 3 keys or don't register some of the keys when a certain combination of keys are used together.

The problem is, different keyboards may behave differently. Therefore, things that works for you may not work for others.

My advice is, if a game is to be designed for playing with a keyboard, try to make it so the player never needs to press too many keys at the same time, or, provide an option to customise the keys, so the player can change the keys if in case some specific combination of keys wouldn't work for them.

Ryan Timothy B

I was expecting that response.  :-\

Sounds like I'll have to assign keys then...
That's never fun.  I thought I was finally done with Road Racer.  Hehe

Thanks a bunch Gilbet.

Nickydude

I have a wired keyboard and have the same problem, seems to be with the SPACE key as I can register UP+LEFT+CTRL, but not UP+LEFT+SPACE.
Best Regards,
Nickydude
www.madladdesigns.co.uk

AGS Beginner's Guide - All you'll ever need!

Ryan Timothy B

Quite a few people are telling me they have had keyboards that do this.
That's insane how the companies let something like that slide.  Look at how many games require multiple direction keys and space.  Perhaps this is why most games jumped to using W-A-S-D?  Also more buttons for one hand to be able to press at once, and they aren't directional keys, meaning they probably have more priority. 

That also confuses me though why they use W-A-S-D when your baby finger is stuck being able to use only TAB, CAPS, and SHIFT.  I always configure it to use E-S-D-F and then your baby finger is able to use Q, A and Z (obviously for less important things like a flashlight in games where you don't need a flashlight too often) since it's very hard for your baby finger to operate to Q and Z while holding down the E-S-D-F.  And then your finger is on F where the little indent is, and you can never loose the location of the keys.

Still can't believe it though.  Look at a game like Worms2 demo.  You cannot configure keys (perhaps in the regedit? I dunno), and you're required to use pretty much all the directional keys at once Plus the space bar.

SMF spam blocked by CleanTalk