Problem with keys

For discussion of ports to POSIX based systems, especially using GNUStep.

Moderators: winston, another_commander, Getafix

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Problem with keys

Post by Rustybolts » Tue Apr 27, 2010 4:25 pm

Oolite 1.73.4
Ubuntu 9.10 Acer 5332 Laptop

Unable to use certain keys to play game, for example
TAB key - energy bomb have to remap sorry works
# key - wont function
/ key -wont function
haven't tested following keys but assume will have similar problems
~ @ ' : ; ? > < , . + - { } [ ] \ |
has any one else reported this or is having similar problem?
With limited amount of spare keys on keyboard this is quite annoying.
Last edited by Rustybolts on Wed Apr 28, 2010 3:43 pm, edited 1 time in total.
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
Commander McLane
Intergalactic Spam Assassin
Intergalactic Spam Assassin
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane » Wed Apr 28, 2010 1:45 pm

First and obvious question: Are you sure that your keyconfig.plist has these keys correctly defined?

User avatar
Diziet Sma
---- E L I T E ----
---- E L I T E ----
Posts: 6310
Joined: Mon Apr 06, 2009 12:20 pm
Location: Aboard the Pitviper S.E. "Blackwidow"

Post by Diziet Sma » Wed Apr 28, 2010 2:05 pm

You can download a default keyconfig.plist here. http://www.box.net/shared/1hu9xgy4b9

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 3:34 pm

Yes its an old oxp i created which has been tested on previous occasions.
If i change the event that is defined for keypress "#" to a letter say "l" it works, if i change it back again it does not respond.
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
Thargoid
Thargoid
Thargoid
Posts: 5510
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid » Wed Apr 28, 2010 4:29 pm

Second and obvious question - are you sure your keyboard (and it's driver as appropriate) are correctly configured, so the keys you are physically pressing are generating the symbols you think they are?

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 5:23 pm

All keys respond in linux as they should in programs (except Oolite) Open Office Firefox etc and correspond to appropriate key pressed.
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 5:29 pm

Just checked on Freedoom (Doom clone if you haven't played it) and rebinded run key to the # key and it works perfectly OK.
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
Phantom Hoover
Dangerous
Dangerous
Posts: 100
Joined: Mon Mar 22, 2010 9:06 pm

Post by Phantom Hoover » Wed Apr 28, 2010 6:16 pm

IIRC Oolite uses the American keyboard layout, so it might be that.

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 6:38 pm

Phantom Hoover wrote:IIRC Oolite uses the American keyboard layout, so it might be that.

Code: Select all

key_next_compass_mode			= "#";
When pressing the key that corresponds to # key on my keyboard on every other package it generates a # symbol so should that make a difference? :?
If it did surely other uk keyboard users would have this problem (was working ok on windows with uk keyboard)
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton » Wed Apr 28, 2010 6:56 pm

What Phantom Hoover says is correct (except under Mac OS X). "#" should correspond to shift-3 (the US keyboard location of #), regardless of logical or physical keyboard layout.

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 7:27 pm

Ahruman wrote:What Phantom Hoover says is correct (except under Mac OS X). "#" should correspond to shift-3 (the US keyboard location of #), regardless of logical or physical keyboard layout.
On my keyboard shift-3 is £ in game this works but i want to use uk # key.
When i was running windows it if i told it to use the uk # key it would use that key. :?
Image
You should really incorporate a redefine keys setup from inside of Oolite
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
Phantom Hoover
Dangerous
Dangerous
Posts: 100
Joined: Mon Mar 22, 2010 9:06 pm

Post by Phantom Hoover » Wed Apr 28, 2010 8:32 pm

Is the American layout because it was written for the Mac? It would seem a worthwhile thing to fix, given that a majority of the users are likely to be Windows users from the UK.

User avatar
Rustybolts
---- E L I T E ----
---- E L I T E ----
Posts: 293
Joined: Sun Jun 07, 2009 6:22 pm
Location: UK

Post by Rustybolts » Wed Apr 28, 2010 8:41 pm

It was working fine on my Windows / Oolite install, I now solely use Linux and it appears to be a problem.
STE.+ Firefly/Dragonfly + BlackJacksbullion v.1.23 link below.
http://www.mediafire.com/?sharekey=ca16 ... f6e8ebb871
Image

User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton » Wed Apr 28, 2010 9:33 pm

Phantom Hoover wrote:Is the American layout because it was written for the Mac?
No, it’s an SDL thing.

The SDL position is essentially correct: binding keys by position rather than key value is the Right Thing for games. The problem here is that key configuration involves fiddling with files in the first place. I do want to switch to a decent in-game configuration screen, but we don’t have the infrastructure in place and we need to prioritise working towards a “stable” release.

User avatar
Kaks
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 3009
Joined: Mon Jan 21, 2008 11:41 pm
Location: The Big Smoke

Post by Kaks » Thu Apr 29, 2010 8:43 am

Looking at the US layout, there is actually no key corresponding to your keyboard's "#" so I'm afraid you're momentarily out of luck there. It's entirely possible that "#" was added as a purely windows hack, so we might be able to transfer that bit of the code to linux.

However, "/" is in exactly the same position in both layouts, so I've no idea why it's not working, will try to investigate & report back...
Hey, free OXPs: farsun v1.05 & tty v0.5! :0)

Post Reply