The Ur-Quan Masters Discussion Forum

The Ur-Quan Masters Re-Release => Technical Issues => Topic started by: Kola on February 12, 2008, 08:36:59 pm



Title: Joypad works on menus but not ingame???
Post by: Kola on February 12, 2008, 08:36:59 pm
Bizzare.  I can scroll through all menus IE mellee, single player etc what ships I want etc etc but once im in game I cant use my Joypad.

What am I doing wrong?


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on February 13, 2008, 09:17:13 am
Bizzare.  I can scroll through all menus IE mellee, single player etc what ships I want etc etc but once im in game I cant use my Joypad.
First of all, have you selected joystick 1 as the controller for Player One (Setup/Configure Controls)? Next, have you made sure the configuration for the joystick is actually correct (Setup/Configure Controls/Edit Controls)? Finally, have you made sure UQM can see your joypad (see stderr.txt in the UQM directory for the debug log)?


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on February 13, 2008, 11:37:10 am
Hi there.

Yes to all three, this is why this prob is bizzare.   UQM must be able to see my Joypad as it works fine for everything except in game.


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on February 13, 2008, 01:03:37 pm
Strange, indeed. Can you post your keys.cfg or flight.cfg file (whichever is newer if you have both)?


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on February 13, 2008, 02:04:17 pm
Certainly m8.  You couldn't tell me how to do that could you?


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on February 13, 2008, 02:21:26 pm
You will find the relevant file in your settings directory (http://uqm.stack.nl/wiki/The_Ur-Quan_Masters_Technical_FAQ#Where_are_my_settings_stored.3F). This is the file we need to see; uploading it to e.g. a web or FTP server and posting a link here, or opening the file in your favourite text editor (Notepad should do) and cutting-and-pasting into a (long) post will both accomplish this.


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 10, 2008, 07:33:33 pm
Looked under program files/ the urquan masters and dont have those files you mention.  I dont seem to even have the  settings directory here. 


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 11, 2008, 09:06:51 am
Looked under program files/ the urquan masters and dont have those files you mention.  I dont seem to even have the  settings directory here. 
That's not the settings directory. Did you actually follow the link to the FAQ?


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 11, 2008, 12:24:16 pm
I click the link on your sig for the FAQ but its dead.


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 11, 2008, 02:08:41 pm
I click the link on your sig for the FAQ but its dead.
First of all, I meant the settings directory (http://wiki.uqm.stack.nl/The_Ur-Quan_Masters_Technical_FAQ#Where_are_my_settings_stored.3F) link, not the FAQ link in my signature, although they both link to the same page, just different sections. Both links work for me.


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 11, 2008, 02:19:49 pm
Got it thanks

version 4
Menu-Backspace: key Backspace
Menu-Next: key Tab
Menu-Select: key Return
Pause: key Pause
Menu-Edit-Cancel: key Escape
Template-1-Escape: key Escape
Template-2-Escape: key Escape
Template-3-Escape: key Escape
Template-4-Escape: key Escape
Template-5-Escape: key Escape
Template-6-Escape: key Escape
Template-1-Up: key Escape
Template-5-Up: key Escape
Template-6-Up: key Escape
Menu-Cancel: key Space
Menu-Search: key /
Template-3-Special: key [
Template-3-Weapon: key ]
Template-2-Left: key a
Template-4-Special: key a
Template-2-Special: key b
Template-2-Right: key d
Template-4-Down: key d
Template-4-Up: key e
Template-4-Right: key f
Template-4-Weapon: key q
Template-2-Down: key s
Template-4-Left: key s
Template-2-Weapon: key v
Template-2-Up: key w
Menu-Delete: key Delete
Menu-Cancel: key Keypad-0
Template-1-Special: key Keypad-0
Menu-End: key Keypad-1
Menu-Down: key Keypad-2
Template-1-Down: key Keypad-2
Template-3-Down: key Keypad-2
Menu-Page-Down: key Keypad-3
Menu-Left: key Keypad-4
Template-1-Left: key Keypad-4
Template-3-Left: key Keypad-4
Menu-Right: key Keypad-6
Template-1-Right: key Keypad-6
Template-3-Right: key Keypad-6
Menu-Home: key Keypad-7
Menu-Up: key Keypad-8
Template-3-Up: key Keypad-8
Menu-Page-Up: key Keypad-9
Menu-Delete: key Keypad-.
Menu-Zoom-Out: key Keypad--
Menu-Zoom-In: key Keypad-+
Menu-Select: key Keypad-Enter
Template-1-Weapon: key Keypad-Enter
Menu-Up: key Up
Template-1-Up: key Up
Template-3-Up: key Up
Menu-Down: key Down
Template-1-Down: key Down
Template-3-Down: key Down
Menu-Right: key Right
Template-1-Right: key Right
Template-3-Right: key Right
Menu-Left: key Left
Template-1-Left: key Left
Template-3-Left: key Left
Menu-Home: key Home
Menu-End: key End
Menu-Page-Up: key PageUp
Menu-Zoom-In: key PageUp
Menu-Page-Down: key PageDown
Menu-Zoom-Out: key PageDown
Pause: key F1
Exit: key F10
Menu-Cancel: key RightShift
Template-1-Special: key RightShift
Menu-Select: key RightControl
Template-1-Weapon: key RightControl


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 11, 2008, 02:32:43 pm
All right, I think I see the problem. Try adding the following to that file:

Code:
# This is a sample joystick configuration.  This is intended to work
# primarily under WinXP with a USB analog/digital gamepad.  The
# digital aspect of the gamepad happens to present itself to the
# system as a POV hat.  This configuration allows either the digital
# or analog stick to be used simultaneously.  More importantly, it
# gives us a chance to give examples for all of the various input types
# that UQM can handle.

joystick 0 threshold 10000   # How far to move before it counts; 0-30000

Template-5-Up: joystick 0 axis 1 negative
Template-5-Down: joystick 0 axis 1 positive
Template-5-Left: joystick 0 axis 0 negative
Template-5-Right: joystick 0 axis 0 positive

Template-5-Up: joystick 0 hat 0 up
Template-5-Down: joystick 0 hat 0 down
Template-5-Left: joystick 0 hat 0 left
Template-5-Right: joystick 0 hat 0 right

Template-5-Weapon: joystick 0 button 0
Template-5-Special: joystick 0 button 1
Template-5-Escape: key Escape

Menu-Up: joystick 0 axis 1 negative
Menu-Down: joystick 0 axis 1 positive
Menu-Left: joystick 0 axis 0 negative
Menu-Right: joystick 0 axis 0 positive

Menu-Up: joystick 0 hat 0 up
Menu-Down: joystick 0 hat 0 down
Menu-Left: joystick 0 hat 0 left
Menu-Right: joystick 0 hat 0 right

Menu-Cancel: joystick 0 button 1
Menu-Select: joystick 0 button 0

joystick 1 threshold 10000   # How far to move before it counts; 0-30000

Template-6-Up: joystick 1 axis 1 negative
Template-6-Down: joystick 1 axis 1 positive
Template-6-Left: joystick 1 axis 0 negative
Template-6-Right: joystick 1 axis 0 positive

Template-6-Up: joystick 1 hat 0 up
Template-6-Down: joystick 1 hat 0 down
Template-6-Left: joystick 1 hat 0 left
Template-6-Right: joystick 1 hat 0 right

Template-6-Weapon: joystick 1 button 0
Template-6-Special: joystick 1 button 1

Template-6-Escape: key Escape

Menu-Up: joystick 1 axis 1 negative
Menu-Down: joystick 1 axis 1 positive
Menu-Left: joystick 1 axis 0 negative
Menu-Right: joystick 1 axis 0 positive

Menu-Up: joystick 1 hat 0 up
Menu-Down: joystick 1 hat 0 down
Menu-Left: joystick 1 hat 0 left
Menu-Right: joystick 1 hat 0 right

Menu-Cancel: joystick 1 button 1
Menu-Select: joystick 1 button 0
You may have to switch to the joystick template from the setup menu in UQM after making this change.


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 11, 2008, 04:29:01 pm
Thanks m8.  The Joypad now works throughout the menus as it did before but then stopped for some reason.

Still doesn't work within the actual game though.


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 11, 2008, 04:55:03 pm
Thanks m8.  The Joypad now works throughout the menus as it did before but then stopped for some reason.

Still doesn't work within the actual game though.
Good, that means the missing joystick definitions are OK and we only need to assign the joystick to a player. All right, let's check uqm.cfg (in the same directory). Could you please post the contents of that file here?


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 11, 2008, 05:13:53 pm
Certainly can  :)

config.speechvol = 100
config.sfxvol = 100
config.musicvol = 100
config.audioquality = high
config.audiodriver = mixsdl
config.player2control = 5
config.player1control = 4
config.pulseshield = no
config.positionalsfx = no
config.smoothmelee = yes
config.showfps = yes
config.3domovies = yes
config.3domusic = yes
config.smoothscroll = no
config.iconicscan = no
config.textgradients = yes
config.textmenu = yes
config.subtitles = yes
config.fullscreen = yes
config.scanlines = no
config.scaler = triscan
config.usegl = yes
config.alwaysgl = no
config.resheight = 768
config.reswidth = 1024
config.keys.6.name = Joystick 2
config.keys.5.name = Joystick 1
config.keys.4.name = ESDF
config.keys.3.name = Arrows (2)
config.keys.2.name = WASD
config.keys.1.name = Arrows


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 11, 2008, 06:01:39 pm
Bugger - Dont know what ive done but now nothing controls the in game.  not even the keyboard.

Oh this is unbearable!!  Ive been playing Urquan masters for a month daily.  Having withdrawal symptoms already!


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 11, 2008, 10:25:38 pm
Bugger - Dont know what ive done but now nothing controls the in game.  not even the keyboard.

Oh this is unbearable!!  Ive been playing Urquan masters for a month daily.  Having withdrawal symptoms already!
Funny, really. As far as I could tell everything should work now (joystick 0 should be controlling the game itself). Are the menus still functional?

Emergency solution: delete (or, to be safer, rename) both the key and main configuration files (the ones we've been editing). This will change UQM's settings back to the default, which hopefully should give you some control.

I really need to get hold of a joystick to be sure of what I'm doing, here (I have a broken old analogue stick around here somewhere I use for this sort of thing, but I don't have a game port to plug it in!).


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 12, 2008, 09:28:33 am
Hi Novus,

My internet went off last night and out of sheer boredom I tried an uninstall reinstall.  Totally forgot the installer is a downloader so that didnt help my cause at all.

Anyhow, because I couldn't see your above suggestion I have started again with a fresh install today, internet back on.

Should I add the code you said to add yesterday

# This is a sample joystick configuration.  This is intended to work
# primarily under WinXP with a USB analog/digital gamepad.  The
# digital aspect of the gamepad happens to present itself to the
# system as a POV hat.  This configuration allows either the digital
# or analog stick to be used simultaneously.  More importantly, it
# gives us a chance to give examples for all of the various input types
# that UQM can handle.

joystick 0 threshold 10000   # How far to move before it counts; 0-30000

Template-5-Up: joystick 0 axis 1 negative
Template-5-Down: joystick 0 axis 1 positive
Template-5-Left: joystick 0 axis 0 negative
Template-5-Right: joystick 0 axis 0 positive

Template-5-Up: joystick 0 hat 0 up
Template-5-Down: joystick 0 hat 0 down
Template-5-Left: joystick 0 hat 0 left
Template-5-Right: joystick 0 hat 0 right

Template-5-Weapon: joystick 0 button 0
Template-5-Special: joystick 0 button 1
Template-5-Escape: key Escape

Menu-Up: joystick 0 axis 1 negative
Menu-Down: joystick 0 axis 1 positive
Menu-Left: joystick 0 axis 0 negative
Menu-Right: joystick 0 axis 0 positive

Menu-Up: joystick 0 hat 0 up
Menu-Down: joystick 0 hat 0 down
Menu-Left: joystick 0 hat 0 left
Menu-Right: joystick 0 hat 0 right

Menu-Cancel: joystick 0 button 1
Menu-Select: joystick 0 button 0

joystick 1 threshold 10000   # How far to move before it counts; 0-30000

Template-6-Up: joystick 1 axis 1 negative
Template-6-Down: joystick 1 axis 1 positive
Template-6-Left: joystick 1 axis 0 negative
Template-6-Right: joystick 1 axis 0 positive

Template-6-Up: joystick 1 hat 0 up
Template-6-Down: joystick 1 hat 0 down
Template-6-Left: joystick 1 hat 0 left
Template-6-Right: joystick 1 hat 0 right

Template-6-Weapon: joystick 1 button 0
Template-6-Special: joystick 1 button 1

Template-6-Escape: key Escape

Menu-Up: joystick 1 axis 1 negative
Menu-Down: joystick 1 axis 1 positive
Menu-Left: joystick 1 axis 0 negative
Menu-Right: joystick 1 axis 0 positive

Menu-Up: joystick 1 hat 0 up
Menu-Down: joystick 1 hat 0 down
Menu-Left: joystick 1 hat 0 left
Menu-Right: joystick 1 hat 0 right

Menu-Cancel: joystick 1 button 1
Menu-Select: joystick 1 button 0


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 13, 2008, 11:19:51 am
Reinstalling UQM won't, IIRC, do anything to your configuration, and the problem seems to be there, not in the installation. That said, if the stuff I told you to add has disappeared (note that the file may be reordered, but the same lines about the joystick should still be there), you will need to put it back.


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 13, 2008, 07:53:10 pm
Ok m8, im back to where I started now.  Joypad works fine right up to the point where I have to select my ship in the Super Melee.

You get a chance to try your joystick. 



Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 15, 2008, 11:18:59 am
Anyone able to help me get my joypad working in game please?


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 15, 2008, 12:13:50 pm
All right. After doing a clean install of UQM 0.6.2 on a Windows ME box with a joystick (old-skool PC joystick with 2 analogue axes, 2 buttons) installed, the joystick wouldn't work. This turned out to be because it wasn't plugged in (or more, specifically, it wasn't plugged into the game port Windows was using; too many old sound cards).

After fixing that problem, UQM still didn't recognise the joystick at all (just like in your case). Deleting the configuration files (keys.cfg and uqm.cfg) made the menus react to the joystick. Finally, going into the setup menu and going Configure Controls/Player One/Joystick 1 fixed it; now the lower player in melee and the full game player are controlled by the joystick.

You can either try to retrace my steps or simply replace your keys.cfg and uqm.cfg with my keys.cfg (http://koti.mbnet.fi/lonnberg/keys.cfg) and uqm.cfg (http://koti.mbnet.fi/lonnberg/uqm.cfg).


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 15, 2008, 12:29:38 pm
Hi Novus,

A big thanks for all you efforts but it still didn't working m8.  Same as ever.  Works fine until I have to select my ship in super melee.

I copied and pasted your files


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 15, 2008, 12:36:18 pm
A big thanks for all you efforts but it still didn't working m8.  Same as ever.  Works fine until I have to select my ship in super melee.
Are you playing upper or lower player in melee? The joystick is now set up for the lower player. Have you tried full game?

When you cut and pasted the files, do you mean that you cut and pasted the contents replacing what was there, or replaced the files (both should work, though)?

Could you please post the contents of stderr.txt from your UQM installation directory?


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 15, 2008, 12:54:25 pm
It works m8 ;D ;D ;D ;D

I was selecting the upper player.  Dont understand why that would matter though. 

Will I be able to play two player both with joypads this way.  Just im trying to get as many interested as poss and when friend come over I want the to play the best ever 2 player game in history.


Title: Re: Joypad works on menus but not ingame???
Post by: Novus on March 15, 2008, 01:22:33 pm
It works m8 ;D ;D ;D ;D
Smashing!

Quote
I was selecting the upper player.  Dont understand why that would matter though. 
Lower player is player 1, upper player is player 2. They have separate control configurations.

Quote
Will I be able to play two player both with joypads this way.  Just im trying to get as many interested as poss and when friend come over I want the to play the best ever 2 player game in history.
Right now you're set up for one joypad, but the technique I described two posts ago for setting up joystick control should work with minor changes. A slightly improved version follows:

  • Ensure both joypads are plugged in (UQM automatically removes all configuration for joysticks that aren't connected, which is really annoying if you add/remove joypads).
  • Delete keys.cfg.
  • Start UQM.
  • In Setup, Configure Controls: Player One/Joystick 1 and Player Two/Joystick 2 (note that you have to press Return (or fire 1) to select the choices; just moving the highlight with cursor keys/direction pad does not change the setting).
  • Exit Setup.
  • Play. Player 1(full game, lower player in melee) is now on joystick 1, player 2 (upper player in melee) is on joystick 2.


Title: Re: Joypad works on menus but not ingame???
Post by: Kola on March 16, 2008, 12:53:40 pm
Ill try what you say but all my free time at the mo is taken up with joypad and UQM. :]

Giza a week or so