Using xboxdrv for 4-way restrictor on complete rertropie setup already using dragonrise usb controller setup?
-
@spud11 OK, for now i don't have time to deal with this crazy complexity of xboxdrv...
In general what does this make differently... i mean in the end it has to guess the direction you intend to use depending on your inputs... This is also done by default in Retropie by means of ignoring the unchanged direction between two movements.
meaning moving from up to up/right ignores up as it has not changed leading to a right control input. Is this generally done differently with xboxdrv?
-
@robertvb83 said in Using xboxdrv for 4-way restrictor on complete rertropie setup already using dragonrise usb controller setup?:
moving from up to up/right ignores up as it has not changed leading to a right control input. Is this generally done differently with xboxdrv?
Using four-way restriction would ignore up/right altogether. A large number of games can't read those inputs, leading to deadly stall-outs in control. It's most easily seen in any of the 'Pac-Man' games. When turning a corner. If the game reads a mixed input, you're Pac-character will just hang there until a decisive up, down, left or right input is read. Another good example is 'Donkey Kong' or 'Burger Time'. Using ladders should be easy, but with mixed inputs, many times you character just stalls-out.
-
@mediamogul as far as i understand from mame changelog (do not find where i read that) basically mame knows if it is a 4-way or 8-way game. so in case of a 4-way game it decides to translate up/right into right in case you switch from up. i am just curios how xboxdrv deals with it, as it has to come up with a prediction method also
-
@robertvb83 said in Using xboxdrv for 4-way restrictor on complete rertropie setup already using dragonrise usb controller setup?:
as far as i understand from mame changelog (do not find where i read that) basically mame knows if it is a 4-way or 8-way game.
Nice! I use AdvanceMame on RetroPie, which makes use of the 0.106 code base and that feature wasn't added by that point. Any idea when it was introduced? As far as xboxdrv goes, I have a list of games that benefit from four-way restriction and I use it to launch the proper map from the runcommand-onstart script. As @spud11 mentioned above, I also found a way to switch between the two as the situation calls for it, but I haven't impleented it in my setup yet.
-
-
Very interesting. I've never run into the feature in practice. It looks as though it's been tweaked and gutted quite a few times. Perhaps the MAME team just decided to leave it out at some point.
-
@mediamogul Holy moly. That is interesting. I'm doubtful the 8 way/4 way MAME dichotomy works in the RetroPie versions of MAME. At least when I've tried playing Ms Pacman with an 8 way non-restricted xboxdrv configuration, Ms Pacman's head basically spins around. When I've used the 4 way restriction, there's no problem. Mind you I'm not using MAME 0.37B as referenced in the thread. Perhaps 4 way games would work properly with MAME 0.37B in Retropie?
-
@spud11 hmm I don't know. I understood that statements like it was implemented around 2002 and kept since for future versions...
here is a nother discussion with part of the code...
http://forum.arcadecontrols.com/index.php/topic,123175.msg1309881.html#msg1309881Its really hard to figure such things out for me, because I do not really know where and what exactly to search. If I only had the time to test all this :-)
-
@robertvb83 You've certainly discovered (rediscovered) something of real interest.
All I know is xboxdrv works very well indeed with 4 way games.
-
@spud11 @mediamogul i created an issue for mame2003-plus https://github.com/libretro/mame2003-plus-libretro/issues/380#issuecomment-425712224
The discussiin is about how the xboxdrv driver internally manages the task of 4way conversion for 8way joystick inputs. Can you help clarifying? E.g. what does the software exactly do with the 4way option flag? -
I'm really not sure, but I've always assumed that it takes the diagonal space, divides it in two and assigns the closest allowed direction whenever a joystick goes past the divide. However, that theory wouldn't seem to hold water for digital 8-way directional joysticks, so I'm either wrong, or the technique only works with analog joysticks. I've tested on an 8-way before and I seem to remember it working, but it's been close to two years and I didn't spend a lot of time with it, so it's possible I'm misremembering. Of course, the guy you'd really want to ask is Grumbel, the developer of xboxdrv. He moved development to Gitlab shortly after Microsoft bought Github, so you can currently find him there.
-
well ive applied change to mame2003 plus it works well on a sanwa 8 way for kung fu master. I tried to mimic in code what a 4 way does in a very simple way. i do agree looking at the code briefly it looks like its getting the closest to direction point via analog. Dragon rise is set to analog by default so it probably just ignores and diagonals which is what i done in my code change. Any feedback on this would be good as i only have a 360 controller my ps3 one broke and xbox one is the old wireless type
-
ok think ive nailed it with my last pull req for 8 way joysticks.
im just assuming it ill be ok on digital control pads will need testing. I havent really tried any 4way games on gamepad shocking really.
I think mame was setup towards keyboard usage back in 2003. So the when this is finished we might end up with 3 options depending how control pads react
- original mame
- first down my preferred option (this assumes the diagonal was a mistake and keeps the last direction until the new direction is reached)
- last down all we need to to to implement this is mask out the last down flag.
The reason i picked first down is because it mimics my 4way hardware restriction better than last down. I still tend to use my hardware restriction might not need to now tested dkong ,kungfu master, amidar and pacman defiantly an improvement.
One thing i will say its probably because i know whats going on. I tended to center my joystick before changing direction out of habit(this is not a natural motion though) when in 8 way mode so i didnt have and real troubles with these games as much as others do now i dont need to do that i need to get used to using it normally again
-
ok this feature has been implemented as a core option. Its setup for real arcade joysticks its the last option in the options menu. Please let me know how any of you get on with it. With controllers and arcade joysticks. All you need to do is update from source
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.