2 button combo

GPC1 script programming for Titan One. Code examples, questions, requests.

2 button combo

Postby ESONewb » Mon Mar 25, 2019 11:54 am

Hello!

If this is done else where point me in the direction please!
but I am after a script with a 2 button combo that's activated from one button, I can adjust the buttons to the buttons id like to use but I am clueless as to setting up an actual script.

Please Help x
User avatar
ESONewb
Private First Class
Private First Class
 
Posts: 2
Joined: Sat Mar 23, 2019 11:12 am

Re: 2 button combo

Postby Buffy » Sun Mar 31, 2019 10:24 pm

Change the buttons up top to whatever buttons you need!


Code: Select all
define ACTIVATE_BUTTON  = XB1_X;
define BUTTON_1_ACTIVATE = XB1_Y;
define BUTTON_2_ACTIVATE = XB1_B;

main {
    if(event_press(ACTIVATE_BUTTON)) {
        combo_run(two_btn_combo);
    }
}

combo two_btn_combo {
    set_val(ACTIVATE_BUTTON, FALSE);
    set_val(BUTTON_1_ACTIVATE, TRUE);
    set_val(BUTTON_2_ACTIVATE, TRUE);
    wait(70);
}
ConsoleTuner Support Team || Discord || Custom Scripts
User avatar
Buffy
Lieutenant
Lieutenant
 
Posts: 422
Joined: Wed Jul 20, 2016 5:23 am

Re: 2 button combo

Postby ESONewb » Tue Apr 02, 2019 2:15 am

Thank you so much!
User avatar
ESONewb
Private First Class
Private First Class
 
Posts: 2
Joined: Sat Mar 23, 2019 11:12 am


Return to GPC1 Script Programming

Who is online

Users browsing this forum: No registered users and 61 guests