Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Q*Bert controls with 8-way joystick  (Read 10063 times)

0 Members and 1 Guest are viewing this topic.

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Q*Bert controls with 8-way joystick
« on: August 28, 2009, 01:05:13 am »
I tried to find a thread that had the answer to my question, but couldn't find the right search terms.   :dizzy:

I'm trying to play Q*Bert with standard 8-way joysticks.  I'm not sure why, but MAME won't let me map multiple inputs to the directions, so I can't map my diagonals as I want.  I really don't have a clue why this is a problem as I've had no problem mapping multiple inputs to other controls.  Help?

Oh, I should mention that I tried manually editing the cfg file to add both directions, but when I go to MAME, the directions don't work at all then. :dunno
« Last Edit: August 28, 2009, 01:08:54 am by bkenobi »

ahofle

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4544
  • Last login:August 30, 2023, 05:10:22 pm
    • Arcade Ambience Project
Re: Q*Bert controls with 8-way joystick
« Reply #1 on: August 28, 2009, 11:25:09 am »
Hmm, what do you mean it won't let you?  In the 'input - this game' menu, go to 'up', press enter, and then push your 8-way up and left at the same time.  What does that do?

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
Re: Q*Bert controls with 8-way joystick
« Reply #2 on: August 28, 2009, 11:54:04 am »
thats how we did it on the cabinet here at work, it worked beautifully.
Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade

u_rebelscum

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3633
  • Last login:April 21, 2010, 03:06:26 pm
  • You rebel scum
    • Mame:Analog+
Re: Q*Bert controls with 8-way joystick
« Reply #3 on: August 28, 2009, 12:11:12 pm »
I bet he's using gpwiz, u-hid in joystick mode, or a gamepad hack.  Ignore the following if you have a keyboard encoder (and aren't using a key2joy app).

Mame has a couple default 9x9 grid maps designed for analog joysticks used as 8 or 4 way sticks.  However, wondows treats all joysticks devices, including digital 8 ways, X & Y axes as analog.  One map is a analog to 8-way map, and an other is an analog to 4-way map.  Quess which one mame uses for qbert (hint: the game used a 4-way joystick ;)).

So there are two ways to fix it: make mame use an "8-way" grid map and remap like you want, or make mame use a "rotated 4-way" grid map (no other remapping needed).

I'd make a qbert.ini file and put one line in it.  What the line says depends on which of the above two choices you use.  I prefer the latter:

joystick_map    4444s8888..444458888.444555888.ss5.222555666.222256666.2222s6666.2222s6666

but the former might be easier to understand (even if more steps):

joystick_map   7778...4445


I could go into how the -joystick_map option works, but the docs/config.txt file is very good about it.  Just note that for 8-way gamepad devices (like gpwiz), only 9 squares of the 9x9 (81 squares) grid matter:

7sss8sss9
sssssssss
sssssssss
sssssssss
4sss5sss6
sssssssss
sssssssss
sssssssss
1sss2sss3


The reason the grid maps I posted are so completcated is they are great for analog joysticks (like u360 in analog mode), too.  (And I cut them for mame's source. ;))
Robin
Knowledge is Power

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Re: Q*Bert controls with 8-way joystick
« Reply #4 on: August 28, 2009, 12:36:07 pm »
Ahhh, I see!  I'm using a GP-Wiz.  I figured it had something to do with MAME forcing 4-way mode or something, but I had no clue that it used analog maps for this stuff.  Interesting!

Thanks for the guidance.  I'll give this a go this weekend.   :afro:

headkaze

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2943
  • Last login:August 14, 2023, 02:00:48 am
  • 0x2b|~0x2b?
Re: Q*Bert controls with 8-way joystick
« Reply #5 on: August 28, 2009, 02:41:05 pm »
As I mentioned to bkenobi on the GameEx forums there is always the Mame Analog Joystick Map Editor that can help make the files mentioned by u_rebelscum.

Ummon

  • Trade Count: (+13)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5244
  • Last login:June 09, 2010, 06:37:18 pm
Re: Q*Bert controls with 8-way joystick
« Reply #6 on: August 28, 2009, 11:15:52 pm »
This is only applicable to newer mame then, right?
Yo. Chocolate.


"Theoretical physics has been the most successful and cost-effective in all of science."

Stephen Hawking


People often confuse expressed observations with complaint, ridicule, or - even worse - self-pity.

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Re: Q*Bert controls with 8-way joystick
« Reply #7 on: August 29, 2009, 10:54:47 am »
Works great!  I now understand why people install dedicated diagonal sticks though.  On my LS-30s the diagonals are a bit hard to hit cleanly, so I tend to have a delayed movement.  Also, since I am moving to a corner, I have to fight 2 springs as opposed to just 1.  It's going to have to work cause I don't have any intention of changing anything.

Thanks guys!

severdhed

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2975
  • Last login:December 14, 2024, 05:01:52 pm
  • RIP Dinosaur Hippo
Re: Q*Bert controls with 8-way joystick
« Reply #8 on: August 29, 2009, 11:32:30 pm »
it can be a little difficult to play with an 8way stick, even when programmed that way, becasue if you arent right in the corner and dont hit both switches, it won't do anything.

i thought about a dedicated diagonal 4way, but it was just too much wasted space for a single game.  i ended up getting u360s and they play qbert perfectly.  there is a qbert map for it and i can tell you that since i got these sticks, i have not any one miss-jump on qbert that wasnt a result of me just being an idiot.

Current Projects:      Zak-Man | TMNT Pedestal | SNES Pi | N64 Odroid
Former Projects:     4 Player Showcase | Donkey Kong | iCade

jasonbar

  • Trade Count: (+10)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2250
  • Last login:July 10, 2025, 11:29:40 am
  • Dr. Inferno
    • The Infernolab
Re: Q*Bert controls with 8-way joystick
« Reply #9 on: August 30, 2009, 12:36:03 pm »
i thought about a dedicated diagonal 4way, but it was just too much wasted space for a single game.


Hey, don't forget Q*Bert's Qubes!   :)

If one has a 4-player panel with angled-in outer players, one can make one of the outer sticks be a 4-way/8-way switcher & you're set!

(see far left stick in this pic: http://i242.photobucket.com/albums/ff97/infernolab/Arcade%20Game/01fullcabinet.jpg)


Thanks,
-Jason

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Re: Q*Bert controls with 8-way joystick
« Reply #10 on: August 30, 2009, 01:07:05 pm »
I can only think of 3 games that use diagonal 4-ways:  Q*Bert, Q*Bert's Cubes, Congo Bongo.  All 3 are fun, but my system won't have a dedicated diagonal 4-way unless I were to go with swappable CP's (unlikely).  I don't have a spinner or trackball either, so if I were to look into another CP, I doubt the diagonal 4-way would be high on the priority list.

If I didn't have rotary joysticks, I would probably get a pair of U360's since everyone seems so infatuated with them.  The only other option would be to make the U360 a rotary stick, but I haven't seen an implementation that looked that rugged as of yet.

Ummon

  • Trade Count: (+13)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5244
  • Last login:June 09, 2010, 06:37:18 pm
Re: Q*Bert controls with 8-way joystick
« Reply #11 on: August 30, 2009, 11:05:11 pm »
Guess what. There's a Williams game, circa '84, called INFERNO that uses dual diagonal sticks - and it's two-player. Hey, maybe that was the game being worked on at Williams in that one photo in that thread of 'back in the day at -insert game manufacturer-' pictures.
Yo. Chocolate.


"Theoretical physics has been the most successful and cost-effective in all of science."

Stephen Hawking


People often confuse expressed observations with complaint, ridicule, or - even worse - self-pity.

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Re: Q*Bert controls with 8-way joystick
« Reply #12 on: August 30, 2009, 11:32:10 pm »
Wait, a game that needs 4 diagonal sticks to play?!  Are they trigger sticks as well?  That would be a pretty nice addition to the frankenpanel list of required controls.   :lol

jasonbar

  • Trade Count: (+10)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 2250
  • Last login:July 10, 2025, 11:29:40 am
  • Dr. Inferno
    • The Infernolab
Re: Q*Bert controls with 8-way joystick
« Reply #13 on: August 31, 2009, 12:53:49 am »
Don't worry--Inferno's not very good--you don't need to go out of your way to accommodate it...   ;D

-Jason

u_rebelscum

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3633
  • Last login:April 21, 2010, 03:06:26 pm
  • You rebel scum
    • Mame:Analog+
Re: Q*Bert controls with 8-way joystick
« Reply #14 on: September 01, 2009, 06:02:16 pm »
This is only applicable to newer mame then, right?

"Newer" yes, sort of, but depends on where you draw the "new" vs "old" line.  It's been around for just about two years.  Joystick_map was added in 0.117u1.  Qbert started with a rotated 4-way map, but it was switched to using the normal 4-way joystick_map in 0.118u3.  0.119 came on 13 Sep 2007, and 0.118 on 5 Aug 2007
If post 0.106 is "new", then yes.  If one year or newer is "new", then no.   ;)


I can only think of 3 games that use diagonal 4-ways:  Q*Bert, Q*Bert's Cubes, Congo Bongo.  All 3 are fun, but my system won't have a dedicated diagonal 4-way unless I were to go with swappable CP's (unlikely).  I don't have a spinner or trackball either, so if I were to look into another CP, I doubt the diagonal 4-way would be high on the priority list.

Actually, Congo Bongo seems to work fine with either a rotated four way or a (not rotated) 8-way without any remapping in mame.  At least last time I tested, a few versions ago.  Pretty cool coding, IMO, so that it could be converted from both qbert cabs and a normal 8-way cab. 

You can test it if you have a gamepad encoder or u360 in analog mode very easily.  Set mame's joystick_map to "only diagonals" with: "joystick_map 7777s..77775.777555.ss5" and leave mame's in game mapping alone.  The double check by using the before mentioned rotated 4-way joystick_map ("joystick_map    4444s8888..444458888.444555888.ss5.222555666.222256666.2222s6666.2222s6666"), again without changing mame's in game remapping.  Both work the same. 
(If you draw out the joystick_maps, they are the same as far as center and sticky spots, but the former sends diagonals when the stick is pressed diagonally, while the latter send cardinal directions when pressed diagonally.)

Still, for qbert and congo bongo, a true rotated 4-way feels better than a circular 8-way (like happs super).  Or at least those restricted like one (like u360's square restrictor).  Happs competitions with noticeable corners aren't bad either.
Robin
Knowledge is Power

bkenobi

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 1668
  • Last login:August 16, 2021, 10:41:52 pm
Re: Q*Bert controls with 8-way joystick
« Reply #15 on: September 01, 2009, 09:42:19 pm »
Very interesting.  Thanks for the education!   :cheers:

If there were more games, I would definitely consider a dedicated stick.  As it is, I just can't see building a panel for that alone (since I'm happy with a single panel as is).  I'll give the Congo Bongo stuff a try though.  I thought it was a cool game, but last I played it, it seemed difficult to play.  Perhaps I just didn't have things set up right with the joystick_map.

Ummon

  • Trade Count: (+13)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5244
  • Last login:June 09, 2010, 06:37:18 pm
Re: Q*Bert controls with 8-way joystick
« Reply #16 on: September 02, 2009, 04:39:09 am »
bkenobi: Congo Bongo is killer. One of my all-time faves - but weird if you're used to 2D, northerly-directioned games. This was actually the main reason I needed the capability, Q-bert being not quite as important.


u_reb: in general, both maps will work, yes. However, with the special restrictor on my U360, the rotated one is imperative, and when  using 'newer' mame an ultramap (or otherwise custom) map is required, because the default mame map doesn't work well.

So, yeah, by 'newer' I'm meaning post- whatever development the topic is about, in this case controls (in others, video).
Yo. Chocolate.


"Theoretical physics has been the most successful and cost-effective in all of science."

Stephen Hawking


People often confuse expressed observations with complaint, ridicule, or - even worse - self-pity.

u_rebelscum

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 3633
  • Last login:April 21, 2010, 03:06:26 pm
  • You rebel scum
    • Mame:Analog+
Re: Q*Bert controls with 8-way joystick
« Reply #17 on: September 02, 2009, 07:33:55 pm »
u_reb: in general, both maps will work, yes. However, with the special restrictor on my U360, the rotated one is imperative, and when  using 'newer' mame an ultramap (or otherwise custom) map is required, because the default mame map doesn't work well.

 ???  What I posted above overrides mame's defaults.  Mame only applies the defaults if you don't supply one.  Or are you applying the maps to the u360 instead of mame?

There are a quite few choices with mame-with-joystick_map (for this discussion: "new" ;)) option:

  • A qbert.ini file with one line:
    "joystick_map 4444s8888..444458888.444555888.ss5.222555666.222256666.2222s6666.2222s6666" (rotated 4-way),
    leave u350 in analog mode.  No mame in game remapping
  • Set up (usually with script) ultramap with a rotated 4-way map, leave mame default joystick_map and no in game remapping.
  • A qbert.ini file with on line:
    "joystick_map 7778" (normal 8-way),
    leave u360 in analog or 8-way mode, remap mame in game to use diagonals (or ctrlr file).
  • A qbert.ini file with one line:
    "joystick_map 7777s..77775.777555.ss5" (diagonal only),
    leave u360 in analog mode, remap mame to use diagonals.
  • A qbert.ini file with one line:
    "joystick_map 7778" (normal 8-way),
    set u360 in diagonal only mode, remap in game mame to use diagonals.
  • (This one is redunant, and the qbert.in file is unneeded, but works)
    A qbert.ini file with on line:
    "joystick_map 7778" (normal 8-way),
    set u360 in rotated 4-way mode, no remap in game remapping.

IMO, the above is listed in the order of difficultly of setup, from easiest to hardest (except the last, it's just more work than needed).  Once setup, they're about the same since qbert.ini has only one line.  If the whole mame.ini file was copied, and you wanted to change mame.ini, qbert.ini would also need to be changed to match. 

Which of the first three makes the most sense varies from person to person.  (I like the first one the most.)  Just don't incorrectly mix parts (the last one is an example).

Most setup, doesn't work example:
qbert.ini file copied from mame.ini, with one line changed:
"joystick_map s8.4s8.44s8.4445" (4-way, mame already automatically does this),
set up u360 in diagonal only mode, remap by hand so the game is "in game mapped" to use diagonals.
Robin
Knowledge is Power

Ummon

  • Trade Count: (+13)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 5244
  • Last login:June 09, 2010, 06:37:18 pm
Re: Q*Bert controls with 8-way joystick
« Reply #18 on: September 04, 2009, 04:48:53 am »
.....I don't think about it all in the way you do. While I appreciate your methodical approach, I prefer to start with a visual map, and then play around with it in the editor (whichever I'm using, which is generally Ultramap, because I don't much play newer MAME) until I get something I like and that works with the restictor I have.
Yo. Chocolate.


"Theoretical physics has been the most successful and cost-effective in all of science."

Stephen Hawking


People often confuse expressed observations with complaint, ridicule, or - even worse - self-pity.