Sony navigation controller button reassignment?

Gtuner Plugins support. MaxAim, MaxRemapper, Combo Magick, Game Rec.

Sony navigation controller button reassignment?

Postby Frashbrang » Wed Aug 17, 2016 11:10 pm

Is it possible to reassign buttons on a Sony navigation controller?

I am using maxaim di with the Sony navigation controller plugged directly into the titan one. I would like the trigger on the Sony navigation controller to become the button for reload instead of its default function of aim Down sights. This is because I aim Down sights with the right mouse button.

I attempted to use the remapper plug in but to no avail. Is it doable? Thanks
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby J2Kbr » Thu Aug 18, 2016 6:06 am

this is possible, but will require a script and a little trick.

On MaxAim layout, you possible have the right mouse button assigned to the L2, you need change that to any available EXTRA Input, eg CEMU_EXTRA1. And then load the script below on MaxAIm (not on device):

Code: Select all
main {
    if(get_val(PS4_L2)) {
        set_val(PS4_SQUARE, 100);
        set_val(PS4_L2, 0);
    }
    if(get_val(CEMU_EXTRA1)) {
        set_val(PS4_L2, 100);
        set_val(CEMU_EXTRA1, 0);
    }
}
ConsoleTuner Support Team
User avatar
J2Kbr
General of the Army
General of the Army
 
Posts: 20323
Joined: Tue Mar 18, 2014 1:39 pm

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Thu Aug 18, 2016 9:38 pm

many thanks, this works fine but not its caused another problem...sorry :)

I remap L1(throw grenade) to L3 (sprint)
the way your script works is to turn off L1 as soon as it is pressed therefore negating its primary function.

if I try to remap mouse scroll up to throw grenade this now seems impossible to me because L1 was throw grenade.

so my question is, is it possible to remap L1 to L3 (L1 becomes sprint) and remap mouse scroll up to throw grenade which was initially mapped to L1.

ps my brain is on fire, cant work it out

thanks
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby J2Kbr » Fri Aug 19, 2016 9:09 am

I extended the script to do the L1 -> L3 and EXTRA2 -> L1, where EXTRA2 have your mouse scroll up on MaxAim DI button profile:

Code: Select all
main {
    if(get_val(PS4_L2)) {
        set_val(PS4_SQUARE, 100);
        set_val(PS4_L2, 0);
    }
    if(get_val(CEMU_EXTRA1)) {
        set_val(PS4_L2, 100);
        set_val(CEMU_EXTRA1, 0);
    }
   
    if(get_val(PS4_L1)) {
        set_val(PS4_L3, 100);
        set_val(PS4_L1, 0);
    }
    if(get_val(CEMU_EXTRA2)) {
        set_val(PS4_L1, 100);
        set_val(CEMU_EXTRA2, 0);
    }
}

Hope it works as you expect. :)
ConsoleTuner Support Team
User avatar
J2Kbr
General of the Army
General of the Army
 
Posts: 20323
Joined: Tue Mar 18, 2014 1:39 pm

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Fri Aug 19, 2016 11:17 am

thanks for your reply....

please see the code I have commented below, cheers

Code: Select all
main {
    if(get_val(PS4_L2)) {
        set_val(PS4_SQUARE, 100);
        set_val(PS4_L2, 0);
    }
    if(get_val(CEMU_EXTRA1)) {
        set_val(PS4_L2, 100);
        set_val(CEMU_EXTRA1, 0);
    }
   
    if(get_val(PS4_L1)) {
        set_val(PS4_L3, 100);   //CODE 1 = when L1 pressed then sprint instead of throw grenade
        set_val(PS4_L1, 0);
    }
    if(get_val(CEMU_EXTRA2)) {
        set_val(PS4_L1, 100);    //when CEMU_EXTRA2 pressed then press L1 which should activate grenade, but because of CODE 1 it doesn't activate grenade, it activates sprint. How can L1 = sprint when I want it to sprint and Grenade when I want to throw grenade?
        set_val(CEMU_EXTRA2, 0);
    }
}
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Fri Aug 19, 2016 10:39 pm

The issue is that reassignment of L1 to L3 means that L1's primary function can never be called upon. Any if statement that sets L1 to 100/pressed is immediately cancelled by the if statement that reassigns L1 to L3.

I can see a way to fix this but cannot code it. If L1 is clicked then remap it to be L3, if L1 is double clicked then do L1's primary function (throw grenade in destiny) what do you think? A toggle that recognises the difference between a tap and a double tap which then runs 2 different combos :

Combo 1 remaps L1 To L3
Combo 2 allows L1 to be L1

Please thank you and goodnight
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Sat Aug 20, 2016 1:47 am

This code allows me to run if I tap L1 and throw grenade if I hold L1. I want it to run if I hold L1 and throw grenade if I tap L1 but I cant seem to get it to work. I'm trying here!!!!


Code: Select all
int toggle = TRUE;

main {

if(get_ptime(PS4_L1) <= 300 && !toggle)
        {
        set_val(PS4_L1, 0);
        set_val(PS4_L3, 100);
        }

       
if(get_ptime(PS4_L1) >= 300)
    {
    toggle = FALSE
   
    }

               
    }
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby The_Rabid_Taco » Sat Aug 20, 2016 2:06 am

Give this a shot. I changed the time on L1 press to >= 300 on the first line. If <= 300 it will cancel the L1 press and press L3 instead. This should give a long press to run and a quick press to throw the grenade. Also added a condition that makes toggle equal true if a short press. If not it would always be false after the first time.

Code: Select all
int toggle = TRUE;

main {

if(get_ptime(PS4_L1) >= 300 && !toggle)
        {
        set_val(PS4_L1, 0);
        set_val(PS4_L3, 100);
        }

       
if(get_ptime(PS4_L1) >= 300)
    {
    toggle = FALSE;
   
    } else if(get_ptime(PS4_L1) <= 300) {
    toggle = TRUE;
    }
               
    }
User avatar
The_Rabid_Taco
Major
Major
 
Posts: 1066
Joined: Wed Mar 16, 2016 6:04 pm
Location: Pensacola, FL

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Sat Aug 20, 2016 10:25 am

unfortunately this does not work as expected. when I run this it sprints constantly without having to press anything then when I tap L1 it does throw grenade but then goes back to sprinting. I feel it is very nearly there. all that needs to happen is that it doesn't sprint until I hold down L1.
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Re: Sony navigation controller button reassignment?

Postby Frashbrang » Sat Aug 20, 2016 11:58 am

Ok I have solved this issue by using combos.

If I remap L1 to L3 then to access L1's default function using any other button I must activate L1 outside the main code in a combo else L1 will always be L3.

Hope that makes sense for anyone else trying to use Sony navigation controller, mouse and maxaim.

Glad that's over :) time to remap for all my games
User avatar
Frashbrang
Command Sergeant Major
Command Sergeant Major
 
Posts: 153
Joined: Sat Jul 16, 2016 4:02 pm

Next

Return to Gtuner Plugins Support

Who is online

Users browsing this forum: No registered users and 36 guests