Bad analog controls (N64)

Seems there is a problem with the right analog stick. There’s always too much dead zone. It’s not my controller, i have 3 controllers and all behave the same. Left stick is fine.

I can sort of fix this temporary by going to RetroArch input options and swap the left and right analog controls. This way the right analog gets fixed (but the deadzone transfers to the left). However i can’t save that as override. I only need this for certain games where i use the right controller for camera/look.

I’m using the latest nightly. Can this be fixed?

Assuming you’re using the right analog stick as a substitute for the C Buttons, my guess is that the reason why there’s so much deadzone is because of the way the digital buttons are being transferred to an analog stick.

I’m not using it for c-buttons. I bind the N64 analog stick to it, instead of the left stick. The c-buttons go to the left stick. This way in Goldeneye/PD i can look and aim with the right stick and move with the left, like a modern shooter.

But there’s always this deadzone on the right stick that makes aiming imprecise.

I need to bump this for a bit to ask, is this problem only on my end or is it the same for everyone but there’s no interest because nobody else is using the right stick for analog controls?

Did you try manually creating an override with the sticks swapped? I use this type of control scheme with Sin and Punishment and the deadzone on the right stick doesn’t seem overly large. The stick swap in my game override looks like this (it’s for an Xbox One controller, so it should work with any xinput pad):

input_player1_l_x_plus_axis = "+2"
input_player1_l_y_plus_axis = "-3"
input_player1_l_x_minus_axis = "-2"
input_player1_l_y_minus_axis = "+3"
input_player1_r_x_plus_axis = "+0"
input_player1_r_x_minus_axis = "-0"
input_player1_r_y_plus_axis = "-1"
input_player1_r_y_minus_axis = "+1"
1 Like

Yes, i tried but i doesn’t work.

If i save it as a game remap, it doesn’t read those values.

If i adjust the input via the retroarch main menu and save it as a game.cfg override it also doesn’t work because it loads the autoconfig and it ignores the values.

If i disable input auto config it just makes makes all binds blank and the controller doesn’t work at all. And if i try to rebind them it doesn’t save the values.

I thought about messing with the autoconfig file itself but that means the values will affect all games. I only want to use the right stick in some games though, not all. I don’t know how to load a different autoconfig per game, if that’s even possible at all.

You are saying it works for you? But how do you save it?

This all would have been avoided if there wasn’t a deadzone on the right stick. I don’t understand it’s purpose and it looks like a bug to me. Maybe a developer would shine some light?

Did some further testing and it seems like the right analog stick does indeed have a bigger deadzone than the left.

I was wrong before, if i reduce the threshold too much, the left stick does become even more sensitive and i don’t really want that, it was already sensitive enough. I have to use a value of 0.15 to make the right stick behave correctly but that messes up the left.

I know it’s not a bad controller though because if i swap the left-right analog via the rertoarch iput menu, the deadzone gets swapped as well. And the left stick becomes the problematic one.

So there has to be an error, maybe a different default value for each stick or something like that? Dunno, RetroArch is the only program where my gamepads behave like this.

Anyway, i finally hacked my way through this problem by managing to save an input config override to swap the sticks, increasing the deadzone in the Mupen options and changing the threshold in the main cfg a bit.

Now the right analog behaves great but the left has some deadzone left, however, this doesn’t bother me much since i use that for the c-buttons. I just have to push the stick a bit further but that’s OK, it’s not analog so i don’t need precision.

If there isn’t an inherent deadzone in one of the sticks then i can’t figure out what the problem could be that causes this. In standalone emulators i don’t get this behavior at all, both sticks behave the same. It’s only in RetroArch that i get this, both in Mupen and Parallel, so i assumed there was something wrong there.

I don’t have time right now but the code that applies remapping is:

    for (j = 0; j < 8; j++)
       unsigned k                 = j + RARCH_FIRST_CUSTOM_BIND;
       int16_t current_axis_value = current_input.analogs[j];
       unsigned remap_axis        = 

       if (
             (abs(current_axis_value) > 
             *input_driver_get_float(INPUT_ACTION_AXIS_THRESHOLD) * 32767) && 
             (k != remap_axis)         &&
             (remap_axis != RARCH_UNMAPPED)
          if (remap_axis < RARCH_FIRST_CUSTOM_BIND)
             BIT256_SET(handle->buttons[i], remap_axis);
             int invert = 1;

             if (  (k % 2 == 0 && remap_axis % 2 != 0) || 
                   (k % 2 != 0 && remap_axis % 2 == 0)
                invert = -1;

                remap_axis - RARCH_FIRST_CUSTOM_BIND] = 
                   current_axis_value * invert;


I guess the order could be tweaked so the deadzone has no effect on analog only. Basically check first if it’s digital instead of checking if there is an input.