Help with this script

GPC script programming for Titan Two device. Code examples, how to, questions, requests.

Moderators: The_Rabid_Taco, pablosscripts, bonefisher

Help with this script

Postby BrianRoby » Thu Oct 10, 2019 5:16 pm

I need to convert this script to Titan2.
And let this work with L1 and R1 buttons




Code: Select all
define RB = XB1_RB;
define LB = XB1_LB;
define RT = 4; // R2 - Change for different layout
define LT = 7; // L2 - Change for different layout
define RX = 9;
define RY = 10;
define SENSE_LOW = FALSE; //SENSITIVITY 1 - 4 ########################################
define SENSE_MID = TRUE; //SENSITIVITY 5 - 14 ########################################
define SENSE_MOUSE = FALSE; //SENSITIVITY 14 MOUSE ##
// ##
//##########################################################################################################################################
// ##
int delay = 11;
int value = 0;
int value2 = 0;
 
 
int value1 = 30; // Raccommended values: from 30 to 40; Mouse users: 20
int delay1 = 25;
 
 
int minT = -20;
int pluT = 20;
int pluTN = 10;
int minTH = -30;
int pluTH = 30;
// ##
// ########################################
define RECOMMENDED = FALSE; //Recommended Settings ########################################
define STRONGER = TRUE; //Stronger than Recommended ########################################
define INSANE = FALSE; //Strongest Assist po
//##########################################################################################################################################
// ##
int negative_value_rt_first = 0;
int positive_value_rt_first = 0;
int positive_value_rt_second = 0;
define SEMI = TRUE; //SEMI AUTOMATIC GUNS ex. SHEIVA ########################################
define SMG = FALSE; //SUB MACHINE GUNS ex. VMP ########################################
define AR = FALSE; //AUSSAULT RIFLES ex. MAN O WAR ########################################
// ########################################
int negative_value_lt_first = 0;
int positive_value_lt_first = 0;
int positive_value_lt_second = 0;
// ##
//##########################################################################################################################################
// ##
 
 
//DECLARARATIONS
//--------------------------------------------------------------
define SHOOT_BUTTON = PS4_R2;
define RAPIDFIRE_BUTTON = PS4_L2;
define RATE_OF_FIRE = 180; // Range: 1 to 25 RPS (Round/s)
define AUTOSPOT_BUTTON = PS4_L2;
define SPOT_BUTTON =PS4_R3;
//VARIABLES
//--------------------------------------------------------------
// *DO NOT EDIT/DELETE THIS SECTION*
int hold_time;
int rest_time;
int Attack = FALSE;
 
 
int Timeout_Melee = 0;
int DbleClick_Square = 0;
 
 
//INITIALIZATION - init
//--------------------------------------------------------------
init {
hold_time = 5450 / RATE_OF_FIRE;
rest_time = hold_time - 5450;
if(rest_time < 23) rest_time = 0;
}
 
 
//MAIN BLOCK RUTINES
//--------------------------------------------------------------
main {
 
 
 
 
// COLOR INDICATION FOR the RAPID FIRE ON / OFF
if(get_val(RAPIDFIRE_BUTTON) && get_val(SHOOT_BUTTON)) {
colorled(0,0,1,0); // OFF (Dim Lime/Green) *you can edit here*
colorled(3,3,3,3); // (White) *you can edit here*
combo_run(RapidFire);
} else if(combo_running(RapidFire)) {
combo_stop(RapidFire);
reset_leds(); }
 
 
// COLOR INDICATION FOR the RAPID SPOT ON / OFF
if(get_val(RAPIDFIRE_BUTTON)) {
combo_run(RapidSpot);
} else if(combo_running(RapidSpot)) {
combo_stop(RapidSpot);
reset_leds(); }
 
 
// Double click Square to turn off/on Melee.
if(DbleClick_Square > 0) DbleClick_Square = DbleClick_Square - get_rtime();
if(event_press(PS4_SQUARE) && DbleClick_Square <= 0) {
DbleClick_Square = 300; }
else if(event_press(PS4_SQUARE) && DbleClick_Square > 0) {
Attack = !Attack;
Timeout_Melee = 0;
}
if(Attack) {
set_val(TRACE_1, Timeout_Melee);
Timeout_Melee = Timeout_Melee + get_rtime();
if(Timeout_Melee <= 350) combo_run(Brawl);
else combo_run(StrongAttack);
} else if(combo_running(Brawl)) {
combo_stop(Brawl);
reset_leds(); }
 
 
// Rapid fire on Square button.
if(get_val(PS4_SQUARE)) { combo_run(Action); }
else if(combo_running(Action)) { combo_stop(Action); }
 
 
if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -16;
positive_value_lt_first = 16;
positive_value_lt_second = 16;
 
 
negative_value_rt_first = -24;
positive_value_rt_first = 24;
positive_value_rt_second = 14;
}
 
 
if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -14;
positive_value_lt_first = 14;
positive_value_lt_second = 14;
 
 
negative_value_rt_first = -16;
positive_value_rt_first = 16;
positive_value_rt_second = 6;
}
 
 
if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -22;
positive_value_lt_first = 22;
positive_value_lt_second = 12;
 
 
negative_value_rt_first = -32;
positive_value_rt_first = 32;
positive_value_rt_second = 22;
}
 
 
// ##
//##########################################################################################################################################
// ##
 
 
if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
 
 
negative_value_lt_first = -22;
positive_value_lt_first = 22;
positive_value_lt_second = 22;
 
 
negative_value_rt_first = -32;
positive_value_rt_first = 32;
positive_value_rt_second = 22;
}
 
 
if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
 
 
negative_value_lt_first = -20;
positive_value_lt_first = 20;
positive_value_lt_second = 20;
 
 
negative_value_rt_first = -24;
positive_value_rt_first = 24;
positive_value_rt_second = 13;
}
 
 
if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
 
 
negative_value_lt_first = -30;
positive_value_lt_first = 30;
positive_value_lt_second = 20;
 
 
negative_value_rt_first = -40;
positive_value_rt_first = 40;
positive_value_rt_second = 30;
}
 
 
// ##
//##########################################################################################################################################
// ##
 
 
if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -17;
positive_value_lt_first = 17;
positive_value_lt_second = 17;
 
 
negative_value_rt_first = -27;
positive_value_rt_first = 27;
positive_value_rt_second = 17;
}
 
 
if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -16;
positive_value_lt_first = 16;
positive_value_lt_second = 16;
 
 
negative_value_rt_first = -19;
positive_value_rt_first = 19;
positive_value_rt_second = 10;
}
 
 
if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
 
 
negative_value_lt_first = -25;
positive_value_lt_first = 25;
positive_value_lt_second = 15;
 
 
negative_value_rt_first = -35;
positive_value_rt_first = 35;
positive_value_rt_second = 25;
}
// ##
//##########################################################################################################################################
// ##
if(INSANE == TRUE && STRONGER == FALSE && RECOMMENDED == FALSE) {
value = 45;
value2 = -45;
}
 
 
if(INSANE == FALSE && STRONGER == TRUE && RECOMMENDED == FALSE) {
value = 39;
value2 = -39;
}
// ##
//##########################################################################################################################################
// ##
if(SENSE_LOW == FALSE && SENSE_MID == TRUE && SENSE_MOUSE == FALSE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
 
 
value = 33;
value2 = -33;
}
 
 
if(SENSE_LOW == TRUE && SENSE_MID == FALSE && SENSE_MOUSE == FALSE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
 
 
value = 33;
value2 = -33;
}
 
 
if(SENSE_LOW == FALSE && SENSE_MID == FALSE && SENSE_MOUSE == TRUE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
 
 
value = 20;
value2 = -20;
}
// ##
//##########################################################################################################################################
// ##
if(get_val(LB) && (SEMI == TRUE || AR == TRUE || SMG == TRUE)) {
combo_run(LB_C);
}
 
 
if(get_val(RB) && get_val(LB) && (SEMI == TRUE || AR == TRUE || SMG == TRUE)) {
combo_stop(LB_C);
combo_run(RB_C);
}
 
 
if(get_val(RX) < value2 || get_val(RX) > value || get_val(RY) < value2 || get_val(RY) > value
|| get_val(RX) < value2 || get_val(RX) > value || get_val(RY) < value2 || get_val(RY) > value){
combo_stop(LB_C);
combo_stop(RB_C);
}
if(get_val(LT)) {
combo_run(LT_C);
}
 
 
if(get_val(RT) && get_val(LT)) {
combo_stop(LT_C);
combo_run(RT_C);
}
 
 
if( abs(get_val(10))> value1 || abs(get_val(9))> value1) {
combo_stop(LT_C);
combo_stop(RT_C);
}}
 
 
//COMBO BLOCKS
//--------------------------------------------------------------
 
 
 
 
combo LT_C {
set_val(RY, minT);
wait(delay1)
set_val(RX, pluT);
set_val(RY, pluTN);
wait(delay1)
set_val(RY, pluTN);
wait(delay1)
set_val(RX, minT);
set_val(RY, pluTN);
wait(delay1)
}
 
 
combo RT_C {
set_val(RY, minTH);
wait(delay1)
set_val(RX, pluTH);
set_val(RY, pluT);
wait(delay1)
set_val(RY, pluT);
wait(delay1)
set_val(RX, minTH);
set_val(RY, pluT);
wait(delay1)
}
combo RapidFire {
set_val(SHOOT_BUTTON, 150);
wait(hold_time);
set_val(SHOOT_BUTTON, 0);
wait(rest_time);
set_val(SHOOT_BUTTON, 0);
}
 
 
combo RapidSpot {
set_val(SPOT_BUTTON, 100);
wait(hold_time);
set_val(SPOT_BUTTON, 0);
wait(rest_time);
set_val(SPOT_BUTTON, 0);
}
 
 
combo Brawl {
set_val(PS4_SQUARE, 100);
set_led(LED_4, 2);
wait(80);
set_val(PS4_SQUARE, 0);
set_led(LED_2, 0);
wait(60);
set_val(PS4_SQUARE, 0);
set_led(LED_4, 0);
}
 
 
combo StrongAttack {
set_val(PS4_TRIANGLE, 100);
wait(100);
set_val(PS4_TRIANGLE, 0);
Timeout_Melee = 0;
}
 
 
combo Action {
set_val(PS4_SQUARE, 100);
wait(40);
set_val(PS4_SQUARE, 0);
wait(20);
set_val(PS4_SQUARE, 0);
}
//##########################################################################################################################################
// ##
 
 
 
 
combo LB_C {
set_val(RY, negative_value_lt_first);
wait(delay)
set_val(RX, positive_value_lt_first);
set_val(RY, positive_value_lt_second);
wait(delay)
set_val(RY, positive_value_lt_second);
wait(delay)
set_val(RX, negative_value_lt_first);
set_val(RY, positive_value_lt_second);
wait(delay)
}
 
 
 
 
combo RB_C {
set_val(RY, negative_value_rt_first);
wait(delay)
set_val(RX, positive_value_rt_first);
set_val(RY, positive_value_rt_second);
wait(delay)
set_val(RY, positive_value_rt_second);
wait(delay)
set_val(RX, negative_value_rt_first);
set_val(RY, positive_value_rt_second);
wait(delay)
}
//
// COLOR LED INDICATION for PS4 *NO NEED TO EDIT BELOW*
//--------------------------------------------------------------
function colorled(a,b,c,d) {
set_led(LED_1,a);
set_led(LED_2,b);
set_led(LED_3,c);
set_led(LED_4,d);
}
User avatar
BrianRoby
Master Sergeant
Master Sergeant
 
Posts: 27
Joined: Tue Aug 06, 2019 12:46 am

Re: Help with this script

Postby DontAtMe » Thu Oct 10, 2019 5:21 pm

Paste this at the top of the script.
Code: Select all
#include <titanone.gph>
#define wait(a) ;wait(a);
User avatar
DontAtMe
Sergeant Major of the Army
Sergeant Major of the Army
 
Posts: 210
Joined: Tue Oct 02, 2018 4:49 am

Re: Help with this script

Postby Buffy » Thu Oct 10, 2019 5:41 pm

User avatar
Buffy
Sergeant Major of the Army
Sergeant Major of the Army
 
Posts: 281
Joined: Wed Jul 20, 2016 5:23 am

Re: Help with this script

Postby BrianRoby » Thu Oct 10, 2019 5:53 pm

Thanks but
Now I need it to work with the L1 and R1 buttons
User avatar
BrianRoby
Master Sergeant
Master Sergeant
 
Posts: 27
Joined: Tue Aug 06, 2019 12:46 am

Re: Help with this script

Postby Mad » Thu Oct 10, 2019 7:54 pm

Change:
Code: Select all
define RT = 4; // R2 - Change for different layout
define LT = 7; // L2 - Change for different layout

To:
Code: Select all
define RT = PS4_R1; // R2 - Change for different layout
define LT = PS4_L1; // L2 - Change for different layout
ConsoleTuner Support Team || Discord
Mad
Captain
Captain
 
Posts: 690
Joined: Wed May 22, 2019 5:39 am

Re: Help with this script

Postby shygur » Sat Oct 12, 2019 12:29 am

BrianRoby wrote:I need to convert this script to Titan2.
And let this work with L1 and R1 buttons

Attachments
BrianRoby By Shygur.gpc
maybe solved!
(8.94 KiB) Downloaded 8 times
User avatar
shygur
Sergeant
Sergeant
 
Posts: 8
Joined: Wed Sep 11, 2019 12:36 am

Re: Help with this script

Postby shygur » Sat Oct 12, 2019 12:30 am

Code: Select all
#pragma METAINFO("BrianRoby By Shygur", 1, 0, "shygur")
 
// ADD -- for using this script on titan2.
#include <titanone.gph>
#define wait(a) ;wait(a);
// ADD -- R2 > R1    L2 > L1.
define RT = PS4_R1; // R2 - Change for different layout
define LT = PS4_L1; // L2 - Change for different layout
 
//-- Controller Layout --//
define RB = XB1_RB;
define LB = XB1_LB;
define RT = 4;         // R2 - Change for different layout
define LT = 7;         // L2 - Change for different layout
define RX = 9;
define RY = 10;
 
define SHOOT_BUTTON = PS4_R2;
define RAPIDFIRE_BUTTON = PS4_L2;
define RATE_OF_FIRE = 180; // Range: 1 to 25 RPS (Round/s)
define AUTOSPOT_BUTTON = PS4_L2;
define SPOT_BUTTON =PS4_R3;
 
 
//-- Settings --//
define SENSE_LOW = FALSE;    //SENSITIVITY 1 - 4
define SENSE_MID = TRUE;    //SENSITIVITY 5 - 14
define SENSE_MOUSE = FALSE;    //SENSITIVITY 14 MOUSE
define RECOMMENDED = FALSE;    //Recommended Settings
define STRONGER = TRUE;     //Stronger than Recommended
define INSANE = FALSE;         //Strongest Assist po
define SEMI = TRUE;         //SEMI AUTOMATIC GUNS ex. SHEIVA
define SMG = FALSE;         //SUB MACHINE GUNS ex. VMP
define AR = FALSE;            //AUSSAULT RIFLES ex. MAN O WAR
 
//-- Values --//
int delay = 11;
int value = 0;
int value2 = 0;
int value1 = 30; // Raccommended values: from 30 to 40; Mouse users: 20
int delay1 = 25;
int minT = -20;
int pluT = 20;
int pluTN = 10;
int minTH = -30;
int pluTH = 30;
int negative_value_rt_first = 0;
int positive_value_rt_first = 0;
int positive_value_rt_second = 0;
int negative_value_lt_first = 0;
int positive_value_lt_first = 0;
int positive_value_lt_second = 0;
 
//-- DONT TOUCH --//
int hold_time;
int rest_time;
int Attack = FALSE;
int Timeout_Melee = 0;
int DbleClick_Square = 0;
 
 
//-- Initialization --//
init {
    hold_time = 5450 / RATE_OF_FIRE;
    rest_time = hold_time - 5450;
    if(rest_time < 23) rest_time = 0;
}
 
main {
    // COLOR INDICATION FOR the RAPID FIRE ON / OFF
    if(get_val(RAPIDFIRE_BUTTON) && get_val(SHOOT_BUTTON)) {
        colorled(0,0,1,0); // OFF (Dim Lime/Green) *you can edit here*
        colorled(3,3,3,3); // (White) *you can edit here*
        combo_run(RapidFire);
    } else if(combo_running(RapidFire)) {
        combo_stop(RapidFire);
        reset_leds();
    }
 
    // COLOR INDICATION FOR the RAPID SPOT ON / OFF
    if(get_val(RAPIDFIRE_BUTTON)) {
        combo_run(RapidSpot);
    } else if(combo_running(RapidSpot)) {
        combo_stop(RapidSpot);
        reset_leds();
    }
 
 
    // Double click Square to turn off/on Melee.
    if(DbleClick_Square > 0) DbleClick_Square = DbleClick_Square - get_rtime();
    if(event_press(PS4_SQUARE) && DbleClick_Square <= 0) {
        DbleClick_Square = 300;
    } else if(event_press(PS4_SQUARE) && DbleClick_Square > 0) {
        Attack = !Attack;
        Timeout_Melee = 0;
    }
    if(Attack) {
        set_val(TRACE_1, Timeout_Melee);
        Timeout_Melee = Timeout_Melee + get_rtime();
        if(Timeout_Melee <= 350) combo_run(Brawl);
        else combo_run(StrongAttack);
    } else if(combo_running(Brawl)) {
        combo_stop(Brawl);
        reset_leds();
    }
 
    // Rapid fire on Square button.
    if(get_val(PS4_SQUARE)) { combo_run(Action); }
    else if(combo_running(Action)) { combo_stop(Action); }
 
    if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -16;
        positive_value_lt_first = 16;
        positive_value_lt_second = 16;
        negative_value_rt_first = -24;
        positive_value_rt_first = 24;
        positive_value_rt_second = 14;
    }
    if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -14;
        positive_value_lt_first = 14;
        positive_value_lt_second = 14;
        negative_value_rt_first = -16;
        positive_value_rt_first = 16;
        positive_value_rt_second = 6;
    }
    if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == TRUE && SENSE_MID == FALSE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -22;
        positive_value_lt_first = 22;
        positive_value_lt_second = 12;
        negative_value_rt_first = -32;
        positive_value_rt_first = 32;
        positive_value_rt_second = 22;
    }
    if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
        negative_value_lt_first = -22;
        positive_value_lt_first = 22;
        positive_value_lt_second = 22;
        negative_value_rt_first = -32;
        positive_value_rt_first = 32;
        positive_value_rt_second = 22;
    }
    if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
        negative_value_lt_first = -20;
        positive_value_lt_first = 20;
        positive_value_lt_second = 20;
        negative_value_rt_first = -24;
        positive_value_rt_first = 24;
        positive_value_rt_second = 13;
    }
    if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == FALSE && SENSE_LOW == TRUE) {
        negative_value_lt_first = -30;
        positive_value_lt_first = 30;
        positive_value_lt_second = 20;
        negative_value_rt_first = -40;
        positive_value_rt_first = 40;
        positive_value_rt_second = 30;
    }
    if(SEMI == FALSE && SMG == FALSE && AR == TRUE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -17;
        positive_value_lt_first = 17;
        positive_value_lt_second = 17;
        negative_value_rt_first = -27;
        positive_value_rt_first = 27;
        positive_value_rt_second = 17;
    }
    if(SEMI == TRUE && SMG == FALSE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -16;
        positive_value_lt_first = 16;
        positive_value_lt_second = 16;
        negative_value_rt_first = -19;
        positive_value_rt_first = 19;
        positive_value_rt_second = 10;
    }
    if(SEMI == FALSE && SMG == TRUE && AR == FALSE && SENSE_MOUSE == FALSE && SENSE_MID == TRUE && SENSE_LOW == FALSE) {
        negative_value_lt_first = -25;
        positive_value_lt_first = 25;
        positive_value_lt_second = 15;
        negative_value_rt_first = -35;
        positive_value_rt_first = 35;
        positive_value_rt_second = 25;
    }
    if(INSANE == TRUE && STRONGER == FALSE && RECOMMENDED == FALSE) {
        value = 45;
        value2 = -45;
    }
    if(INSANE == FALSE && STRONGER == TRUE && RECOMMENDED == FALSE) {
        value = 39;
        value2 = -39;
    }
    if(SENSE_LOW == FALSE && SENSE_MID == TRUE && SENSE_MOUSE == FALSE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
        value = 33;
        value2 = -33;
    }
    if(SENSE_LOW == TRUE && SENSE_MID == FALSE && SENSE_MOUSE == FALSE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
        value = 33;
        value2 = -33;
    }
    if(SENSE_LOW == FALSE && SENSE_MID == FALSE && SENSE_MOUSE == TRUE && RECOMMENDED == TRUE && STRONGER == FALSE && INSANE == FALSE) {
        value = 20;
        value2 = -20;
    }
    if(get_val(LB) && (SEMI == TRUE || AR == TRUE || SMG == TRUE)) {
        combo_run(LB_C);
    }
    if(get_val(RB) && get_val(LB) && (SEMI == TRUE || AR == TRUE || SMG == TRUE)) {
        combo_stop(LB_C);
        combo_run(RB_C);
    }
    if(get_val(RX) < value2 || get_val(RX) > value || get_val(RY) < value2 || get_val(RY) > value
    || get_val(RX) < value2 || get_val(RX) > value || get_val(RY) < value2 || get_val(RY) > value){
        combo_stop(LB_C);
        combo_stop(RB_C);
    }
    if(get_val(LT)) {
        combo_run(LT_C);
    }
    if(get_val(RT) && get_val(LT)) {
        combo_stop(LT_C);
        combo_run(RT_C);
    }
    if( abs(get_val(10))> value1 || abs(get_val(9))> value1) {
        combo_stop(LT_C);
        combo_stop(RT_C);
    }
}
//COMBO BLOCKS
combo LT_C {
    set_val(RY, minT);
    wait(delay1)
    set_val(RX, pluT);
    set_val(RY, pluTN);
    wait(delay1)
    set_val(RY, pluTN);
    wait(delay1)
    set_val(RX, minT);
    set_val(RY, pluTN);
    wait(delay1)
}
combo RT_C {
    set_val(RY, minTH);
    wait(delay1)
    set_val(RX, pluTH);
    set_val(RY, pluT);
    wait(delay1)
    set_val(RY, pluT);
    wait(delay1)
    set_val(RX, minTH);
    set_val(RY, pluT);
    wait(delay1)
}
combo RapidFire {
    set_val(SHOOT_BUTTON, 150);
    wait(hold_time);
    set_val(SHOOT_BUTTON, 0);
    wait(rest_time);
    set_val(SHOOT_BUTTON, 0);
}
combo RapidSpot {
    set_val(SPOT_BUTTON, 100);
    wait(hold_time);
    set_val(SPOT_BUTTON, 0);
    wait(rest_time);
    set_val(SPOT_BUTTON, 0);
}
combo Brawl {
    set_val(PS4_SQUARE, 100);
    set_led(LED_4, 2);
    wait(80);
    set_val(PS4_SQUARE, 0);
    set_led(LED_2, 0);
    wait(60);
    set_val(PS4_SQUARE, 0);
    set_led(LED_4, 0);
}
combo StrongAttack {
    set_val(PS4_TRIANGLE, 100);
    wait(100);
    set_val(PS4_TRIANGLE, 0);
    Timeout_Melee = 0;
}
combo Action {
    set_val(PS4_SQUARE, 100);
    wait(40);
    set_val(PS4_SQUARE, 0);
    wait(20);
    set_val(PS4_SQUARE, 0);
}
combo LB_C {
    set_val(RY, negative_value_lt_first);
    wait(delay)
    set_val(RX, positive_value_lt_first);
    set_val(RY, positive_value_lt_second);
    wait(delay)
    set_val(RY, positive_value_lt_second);
    wait(delay)
    set_val(RX, negative_value_lt_first);
    set_val(RY, positive_value_lt_second);
    wait(delay)
}
combo RB_C {
    set_val(RY, negative_value_rt_first);
    wait(delay)
    set_val(RX, positive_value_rt_first);
    set_val(RY, positive_value_rt_second);
    wait(delay)
    set_val(RY, positive_value_rt_second);
    wait(delay)
    set_val(RX, negative_value_rt_first);
    set_val(RY, positive_value_rt_second);
    wait(delay)
}
function colorled(a,b,c,d) {
    set_led(LED_1,a);
    set_led(LED_2,b);
    set_led(LED_3,c);
    set_led(LED_4,d);
}
//END!!!
User avatar
shygur
Sergeant
Sergeant
 
Posts: 8
Joined: Wed Sep 11, 2019 12:36 am


Return to GPC Script Programming (Titan Two)

Who is online

Users browsing this forum: No registered users and 81 guests