Anti recoil

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

Anti recoil

Postby Apok » Sat Apr 30, 2022 4:18 pm

Hi All,

I have been away from T2 for over a year and see a lot has changed!!

Can any one point me towards a few new anti recoil scripts. I would like to update the one i am currently using in my script.

I see there are multi stage ones now which might be overkill for my simple use of them but I wanted to see what the new hotness was out there these days.

Code: Select all
 
  //////////////////////////////////////////////////////////////////////////
  //Anti Recoil
  //////////////////////////////////////////////////////////////////////////
  if (bUseAntiRecoil)
    {
 
      if (get_actual(BUTTON_5) && time_active(BUTTON_5) >= ARecoilDelay)
        {
 
          if (abs(get_actual(STICK_1_X)) < StickNoise) set_val(STICK_1_X, 0.0);
            if (abs(get_actual(STICK_1_Y)) < StickNoise) set_val(STICK_1_Y, 0.0);
            if (abs(get_actual(STICK_2_X)) < StickNoise) set_val(STICK_2_X, 0.0);
            if (abs(get_actual(STICK_2_Y)) < StickNoise) set_val(STICK_2_Y, 0.0);
 
        if (get_val(BUTTON_5))
        {
          AntiRecoil(STICK_1_X, ARecoil_H_Standing);
            AntiRecoil(STICK_1_Y, ARecoil_V_Standing);
        }
      }
  }
 
User avatar
Apok
Staff Sergeant
Staff Sergeant
 
Posts: 14
Joined: Sun Dec 30, 2018 12:40 am

Return to GPC2 Script Programming

Who is online

Users browsing this forum: No registered users and 75 guests