Jump to content
The Dark Mod Forums

Questions about gamepad support


MirceaKitsune

Recommended Posts

So this online store I bought a pair of headphones from decided to gift me 12$ today. Since the voucher would expire in in two weeks unless used and I had nothing else to get, I decided to spend it on a 17$ gamepad so I'd have one of these as well. I understand they should work fine under Linux these days, plus it supports both dinput and xinput so I'm not concerned.

I never played any FPS or most games using something other than the keyboard and mouse, this feels like an interesting opportunity to try it out. TDM is one of the games I might enjoy playing with such a thing, especially since it doesn't require super-fast reactions till I get used to it like a deathmatch shooter. So until the device arrives tomorrow, I figured I'd ask how well I can expect TDM to run on such a thing! Especially now that we have a new rendering and input management system for the upcoming TDM 2.10.

There's a few things I wanted to know. One is if both looking around as well as movement using the finger pads is supported. I remember some games allowed walking more slowly if you only pushed the pad slightly; Does this mean it's possible to sneak by only moving the pad a bit, in a way that affects how much guards hear you?

Otherwise I was curious if force feedback (vibration) is implemented and used. For TDM this mainly makes sense when you take damage, are in radius of a sound that has the shake effect, and other potential situations I might be missing now. Is gamepad vibration a feature in the engine at least?

  • Like 1
Link to comment
Share on other sites

Seems gamepad support was first added in 2.09 and there's an article about it on the VR branch. I'm assuming this isn't a VR version only feature: Such gamepads have existed for ages for standard games. I actually have one that's 15 years old, stopped using it because some buttons aren't making proper contact any more and it otherwise felt too ancient... USB and even has force-feedback! I got it before Doom 3 was released if I'm not mistaken, so I'd imagine support for gamepads might have existed in vanilla idTech 4.

  • Like 1
Link to comment
Share on other sites

"so I'd imagine support for gamepads might have existed in vanilla idTech 4"

No vanilla idtech 4 has no gamepad support, is possible to go around that by using some emulation/translation software, that maps gamepad cmds to keyboard cmds but the code itself has no idea about gamepads. (that can be easelly changed today)

idSoftware were not fans of those for FPS's when Doom 3 was made (that I totally agree), they were openly against gamepads (that has of course changed now) the game was also PC exclusive for years, they were a very PC centric company in the past.

Edited by HMart
  • Like 1
Link to comment
Share on other sites

Fair enough. Anyway I got my gamepad and found a configuration that works with Linux. Am able to play Xonotic on it, including looking around with one thumb stick and gradual movement with the other! For TheDarkMod however nothing happens, it's ignoring the thumbsticks and buttons entirely: The buttons cannot be set in the menu and the dpads aren't working either. I have the in_pad* cvars set to their default values; Do I need to set a special cvar to enable gamepad support first?

  • Like 1
Link to comment
Share on other sites

Got the controller working perfectly with TDM! The issue appears to be that joysticks based on the older D-input architecture aren't recognized by our engine: You need to use the X-input (xbox controller) architecture. Currently there's a bug in the Linux kernel module which causes the controlled to not be initialized accordingly and require a script to fix after it's plugged in; With this script I can successfully use my new gamepad to play TheDarkMod on Manjaro Linux :)

  • Like 1
Link to comment
Share on other sites

I spent the day configuring the mappings to something I felt I could learn and use properly: The default configuration is less than ideal IMO, this could make for a nice default if other devs agree. This isn't perfect or free of all cumbersome combinations, but it's more organized and prolly the closest you can get to perfection that with the physical design of the controller; With this setup I'm actually getting the hang of playing TDM on an Xbox style gamepad! Unlike shooter FPS's you don't need as much precision in aiming so walking and turning with the dpad is pretty fair and efficient. If other wish to test my setup, simply overwrite the contents of DarkmodPadbinds.cfg with:

unbindPad
bindPadButton MODIFIER PAD_START
bindPadButton PRESS PAD_BACK "inventory_hotkey ''"
bindPadButton LONG_PRESS PAD_BACK "escape"
bindPadButton MOD_PRESS PAD_BACK "_weapon0"

bindPadButton PRESS PAD_A "_inventory_use"
bindPadButton PRESS PAD_B "_inventory_drop"
bindPadButton PRESS PAD_X "inventory_use '#str_02395'"
bindPadButton PRESS PAD_Y "inventory_use '#str_02396'"
bindPadButton LONG_PRESS PAD_A "_inventory_grid"
bindPadButton LONG_PRESS PAD_B "_objectives"
bindPadButton LONG_PRESS PAD_X "savegame quick"
bindPadButton LONG_PRESS PAD_Y "loadgame quick"

bindPadButton PRESS PAD_UP "_inventory_next"
bindPadButton PRESS PAD_DOWN "_inventory_prev"
bindPadButton PRESS PAD_LEFT "_weapon_prev"
bindPadButton PRESS PAD_RIGHT "_weapon_next"
bindPadButton LONG_PRESS PAD_UP "inventory_cycle_group '#str_02392'"
bindPadButton LONG_PRESS PAD_DOWN "inventory_cycle_group '#str_02389'"
bindPadButton LONG_PRESS PAD_LEFT "inventory_cycle_maps"
bindPadButton LONG_PRESS PAD_RIGHT "inventory_cycle_group '#str_02391'"
bindPadButton MOD_PRESS PAD_UP "_weapon4"
bindPadButton MOD_PRESS PAD_DOWN "_weapon3"
bindPadButton MOD_PRESS PAD_LEFT "_weapon1"
bindPadButton MOD_PRESS PAD_RIGHT "_weapon2"

bindPadButton PRESS PAD_L1 "_jump"
bindPadButton PRESS PAD_R1 "_crouch"
bindPadButton PRESS PAD_L2 "_inventory_use"
bindPadButton PRESS PAD_R2 "_frob"
bindPadButton PRESS PAD_L3 "_lean_left"
bindPadButton PRESS PAD_R3 "_lean_right"
bindPadButton LONG_PRESS PAD_L1 "_mantle"
bindPadButton LONG_PRESS PAD_R1 "_speed"
bindPadButton MOD_PRESS PAD_L2 "_parry"
bindPadButton MOD_PRESS PAD_R2 "_attack"

The next / start key acts as the mod key: Hold it to operate the weapon, meaning parry instead of using the active item (left trigger) or attack instead of frobbing (right trigger). The arrows are used to cycle through stuff, long presses cycle through item categories. The A / B / X / Y buttons are used to activate items, with long presses showing objectives / inventory grid or executing quicksave / quickload. Left action button handles jumping (short press) or mantling (long press), right one does crouching (short) or sneaking (long). Lean by pressing on the dpads, both at the same time to lean forward. The back / select key clears the selected stuff, hold to enter the main menu.

Edited by MirceaKitsune
Link to comment
Share on other sites

  • 2 years later...

Does anyone know if there is vibration support?

"I really perceive that vanity about which most men merely prate — the vanity of the human or temporal life. I live continually in a reverie of the future. I have no faith in human perfectibility. I think that human exertion will have no appreciable effect upon humanity. Man is now only more active — not more happy — nor more wise, than he was 6000 years ago. The result will never vary — and to suppose that it will, is to suppose that the foregone man has lived in vain — that the foregone time is but the rudiment of the future — that the myriads who have perished have not been upon equal footing with ourselves — nor are we with our posterity. I cannot agree to lose sight of man the individual, in man the mass."...

- 2 July 1844 letter to James Russell Lowell from Edgar Allan Poe.

badge?user=andarson

Link to comment
Share on other sites

7 hours ago, Anderson said:

Does anyone know if there is vibration support?

When I tested TDM with a gamepad long ago, I'm afraid there wasn't any. I believe I tested force feedback with a system command and it worked, so TDM just doesn't implement this yet.

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

The gamepad implementation allows for a great degree of flexibility to personalize settings, aside from a few minor issues that I mentioned here: https://forums.thedarkmod.com/index.php?/topic/22337-gamepad-bindings/

I would say that playing TDM with a gamepad works very well, especially considering that it was implemented as experimental and hasn't been changed since then.

If I could, I'd go back to 2021-you and congratulate you on buying that gamepad. 🙂

I notice that your DarkmodPadbinds.cfg looks very different from mine...

  • Like 2
Link to comment
Share on other sites

Thank you! Can I get a config file to set up generic controls bindings for a gamepad?

"I really perceive that vanity about which most men merely prate — the vanity of the human or temporal life. I live continually in a reverie of the future. I have no faith in human perfectibility. I think that human exertion will have no appreciable effect upon humanity. Man is now only more active — not more happy — nor more wise, than he was 6000 years ago. The result will never vary — and to suppose that it will, is to suppose that the foregone man has lived in vain — that the foregone time is but the rudiment of the future — that the myriads who have perished have not been upon equal footing with ourselves — nor are we with our posterity. I cannot agree to lose sight of man the individual, in man the mass."...

- 2 July 1844 letter to James Russell Lowell from Edgar Allan Poe.

badge?user=andarson

Link to comment
Share on other sites

  • 2 weeks later...
On 1/28/2024 at 7:41 PM, Anderson said:

Can I get a config file to set up generic controls bindings for a gamepad?

I'm not certain i understand the question, but it may be something similar to what I asked here (number 3):

...but it seems you've already found that post.

  • Like 1
Link to comment
Share on other sites

15 hours ago, Fiver said:

I'm not certain i understand the question, but it may be something similar to what I asked here (number 3):

...but it seems you've already found that post.

Yes, thank you.

My question is if there is a catch-all configuration for a gamepad since apparently there's no gamepad support by default. Even though Doom 3 was released on consoles as well. I imagine this means no rumble, vibration support for gamepads neither.

Just wanted to double check if there is an easy workaround that I missed.

Apologies for the confusion.

"I really perceive that vanity about which most men merely prate — the vanity of the human or temporal life. I live continually in a reverie of the future. I have no faith in human perfectibility. I think that human exertion will have no appreciable effect upon humanity. Man is now only more active — not more happy — nor more wise, than he was 6000 years ago. The result will never vary — and to suppose that it will, is to suppose that the foregone man has lived in vain — that the foregone time is but the rudiment of the future — that the myriads who have perished have not been upon equal footing with ourselves — nor are we with our posterity. I cannot agree to lose sight of man the individual, in man the mass."...

- 2 July 1844 letter to James Russell Lowell from Edgar Allan Poe.

badge?user=andarson

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • Ansome

      Finally got my PC back from the shop after my SSD got corrupted a week ago and damaged my motherboard. Scary stuff, but thank goodness it happened right after two months of FM development instead of wiping all my work before I could release it. New SSD, repaired Motherboard and BIOS, and we're ready to start working on my second FM with some added version control in the cloud just to be safe!
      · 0 replies
    • Petike the Taffer  »  DeTeEff

      I've updated the articles for your FMs and your author category at the wiki. Your newer nickname (DeTeEff) now comes first, and the one in parentheses is your older nickname (Fieldmedic). Just to avoid confusing people who played your FMs years ago and remember your older nickname. I've added a wiki article for your latest FM, Who Watches the Watcher?, as part of my current updating efforts. Unless I overlooked something, you have five different FMs so far.
      · 0 replies
    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 4 replies
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
×
×
  • Create New...