Help with script please

GPC2 script programming for Titan Two. Code examples, questions, requests.

Help with script please

Postby minataur07 » Fri Jul 10, 2020 10:45 pm

Hi guys could someone kindly help me with a script please? I would like when i pull l2 all the way down that l1 would be pressed and held at the same time. Would this be ok and wouldnt interfere with l2 if i tapped it? many thanks
User avatar
minataur07
Sergeant First Class
Sergeant First Class
 
Posts: 25
Joined: Sat Jun 20, 2020 7:42 pm

Re: Help with script please

Postby Yuri-chan » Sat Jul 11, 2020 1:50 am

It should not be a problem at all. L1 and L2 are kept separately from each other.

You should look at the device monitor (rightmost tab in GtunerIV) to see what values of L2 presses you get when you do what you consider a "full" pull. Then you have to write a script that acts if the value of L2 is greater or equal to the value you got.
User avatar
Yuri-chan
Staff Sergeant
Staff Sergeant
 
Posts: 10
Joined: Sun Jun 28, 2020 3:57 pm

Re: Help with script please

Postby Mad » Sat Jul 11, 2020 3:30 am

Code: Select all
main {
    if(get_actual(BUTTON_8) >= 95f) {
        set_val(BUTTON_7, 100);
    }
}
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Re: Help with script please

Postby minataur07 » Sat Jul 11, 2020 1:05 pm

Many thanks , with the auto sprint script you gave me can i just paste the 2 together ?

Code: Select all
 
#include <ps4.gph>
 
main {
    if (get_actual(PS4_LY) <= -50f) {
        set_val(PS4_L3, 100);
    }
}
 
User avatar
minataur07
Sergeant First Class
Sergeant First Class
 
Posts: 25
Joined: Sat Jun 20, 2020 7:42 pm

Re: Help with script please

Postby Mad » Sun Jul 12, 2020 10:45 am

minataur07 wrote:Many thanks , with the auto sprint script you gave me can i just paste the 2 together ?

Sure can:
Code: Select all
#include <ps4.gph>
 
main {
    if (get_actual(PS4_LY) <= -50f) {
        set_val(PS4_L3, 100);
    }
 
    if(get_actual(PS4_L2) >= 95f) {
        set_val(PS4_L1, 100);
    }
}
ConsoleTuner Support Team || ConsoleTuner Discord || InputSense Discord
Mad
Major General
Major General
 
Posts: 4536
Joined: Wed May 22, 2019 5:39 am

Re: Help with script please

Postby minataur07 » Sat Jul 18, 2020 5:22 pm

Huge thanks mate
User avatar
minataur07
Sergeant First Class
Sergeant First Class
 
Posts: 25
Joined: Sat Jun 20, 2020 7:42 pm


Return to GPC2 Script Programming

Who is online

Users browsing this forum: Google [Bot], proxy342 and 135 guests