Page 10 of 13

Re: T1/CM to Titan Two Script Converter [v0.27r5 - 01/29/202

PostPosted: Wed Jan 29, 2020 9:52 am
by Buffy
Fixed 0.27r5, also fixed gpc attached

Re: T1/CM to Titan Two Script Converter [v0.27r3 - 01/26/202

PostPosted: Wed Jan 29, 2020 7:52 pm
by DontAtMe
TrayDay wrote:I've tried converting this script. Yes, used the converter as well, and just can't get it to clear the errors of "invalid symbol redefinition" for "SS" and "AS". Identifiers?
This would not even compile on the CM.
The script was missing a few functions,

I commented out all the references to them though.
Not sure how well this script will work without them.
Code: Select all
//##################################################################################################
//Button Layout
//----------------------------------------------------------------------------------------------
//RF_SWITCH and AR_SWITCH toggle buttons // Change here with above numbers if needed
//----------------------------------------------------------------------------------------------
//RAPID FIRE XB1_Y - 17 17 UP 13 // CEMU_EXTRA1 = 21   
// XB1_MENU - 2 2 // CEMU_EXTRA3 = 23        SAVE BUTTON
//----------------------------------------------------------------------------------------------
//---------------------------------------------------------------------------------------------
//VARIABLES     - YOU CAN MAKE ADJUSTMENTS HERE IF NEEDED !!!!!
//---------------------------------------------------------------------------------------------
//SET OFF IF YOU DONT WANT SHAKY AIM ASSIST OR FEEL WEIRD BEHAVIOUR
//CHANGE OFF TO ON IF YOU PLAY WITH FLIPPED TRIGGERS
//CHANGE ON TO OFF IF YOU DON'T WANT AUTO RUN
//CHANGE OFF TO ON IF YOU WANT SUPER SPRINT - AUTO RUN MUST BE ON
//CHANGE ON TO OFF IF YOU DON'T WANT HAIR TRIGGER   
//CHANGE ON TO OFF IF YOU DON'T WANT HOLD BREATH   
// IF TRUE RAPIDFIRE IS ON BY DEFAULT - IF FALSE, OFF BY DEFAULT
// RANGE: 1 TO 25 RPS (ROUND/S)
//-------------------------------------------------------------------------------------------------
//  AIM ABUSE // INCREASE AP & AM FOR MORE ASSIST BUT IT CAN CAUSE SHAKE LIKE JUMPY CROSSHAIR
//                 MORE THAN 23 NOT RECOMMENDED. int AS = OFF TO DISABLE ABOVE   
//-------------------------------------------------------------------------------------------------
// ARELEASE MUST BE 1 HIGHER THAN AP & AM.
// DECREASE AP & AM IF YOU FEEL SHAKE OR WEIRD MOVEMENT AND DON'T LIKE IT.
// THIS WILL NOT AFFECT SWEET EVILS AIMBOT.
//#################################################################################################
//
// State machine variable
//
//
//#################################################################################################
//######################################### Script variable #######################################
//#################################################################################################
//
// Dont't change!
//
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//
//--Anti-Recoil Progression Adjustable Transition Point
//
//#################################################################################################
//
//--Anti-Recoil values go from Starting_Anti_Recoil_Value to Mid_Point_Anti_Recoil_Value over Progression_Point_Percent of Total_Anti_Recoil_Time
//--Anti-Recoil values then go from Mid_Point_Anti_Recoil_Value to Ending_Anti_Recoil_Value for the remaining Total_Anti_Recoil_Time percent
//--Ending_Anti_Recoil_Value is then applied until trigger release.
//
//--Zero's out controller input of less than 10
//
//#################################################################################################
//
//--Adjust These Values
//--postive values only
//-- 10ms increments (min - 2000)
//--percentage of total time to transition to mid to end values 10% increments
//
//#################################################################################################
//
//--Do not alter sequence of the variables below.  Script uses in-direct reference to access the values (ex... inc[0] = inc , inc[1] = inc_2)
//
//#################################################################################################
//
//
//#################################################################################################
//
//#################################################################################################
//############################################# MAIN ##############################################
//#################################################################################################
//
//update main every 8ms --> only for PS4
// vm_tctrl(-2);
//--LT pulled
//Applying BOOST
////Aim_Perfection(Last_Value, Current_Value, Boost, Correction, X_AXIS, Y_AXIS )
//Applying CORRECTION
////Aim_Perfection(Last_Value, Current_Value, Boost, Correction, X_AXIS, Y_AXIS )
//--LT not pulled
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//
//--reset counters/pointers
//--anti recoil
// CHANGE 7 INTO DESIRED BUTTON FOR TOGGLE DEFINED ABOVE
// SAVE VALUES TO DEVICE MONITOR
//
//#################################################################################################
//############################################# FUNC ##############################################
//#################################################################################################
//           
//Rounding integer division (instead of truncating)
//--moving right
//--moving left
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//   
//--return progression index
//--return current ar val
//--return ar val + input or input if above release
// COLOR LED function
//--------------------------------------------------------------
//
//#################################################################################################
//############################################# END ###############################################
//#################################################################################################
 
define PS = 0;
define SHARE = 1;
define OPTIONS = 2;
define R1 = 3;
define R2 = 4;
define R3 = 5;
define L1 = 6;
define L2 = 7;
define L3 = 8;
define RX = 9;
define RY = 10;
define LX = 11;
define LY = 12;
define UP = 13;
define DOWN = 14;
define LEFT = 15;
define RIGHT = 16;
define TRIANGLE = 17;
define CIRCLE = 18;
define CROSS = 19;
define SQUARE = 20;
define TOUCHPAD = 27;
define Blue = 1;
define Red = 2;
define Green = 3;
define Pink = 4;
define SkyBlue = 5;
define Yellow = 6;
define White = 7;
define RF_switch = 17;
define save = 2;
define ON = TRUE;
define OFF = FALSE;
define Get_Last_Value = 0;
define Get_Current_Value = 1;
define Aim_Correction = 2;
define Aim_Boost = 3;
define Aim_Perfection_Limit = 60;
define Starting_Anti_Recoil_Value = 20;
define Mid_Point_Anti_Recoil_Value = 28;
define Ending_Anti_Recoil_Value = 10;
define Total_Anti_Recoil_Time = 2500;
define Progression_Point_Percent = 30;
 
int AS = ON;
int Flipped = OFF;
int RUN = OFF;
int SS = OFF;
int HT = ON;
int HB = OFF;
int rapid_onoff = TRUE;
int RATE_OF_FIRE = 13;
int Col_ind;
int fire_button;
int scope_button;
int hold_time;
int rest_time;
int SP = ON;
int Remove_Block;
int AP = 20;
int AM = -20;
int Delay = 20;
int ARelease = 21;
int Current_State = 0;
int Aim_Abuse_State = 2;
int X_Last_Value = 0;
int Y_Last_Value = 0;
int X_Current_Value = 0;
int Y_Current_Value = 0;
int mvt = 0;
int Aim_Boost_Val = 0;
int Aim_Correction_Val = 0;
int p, inc, inc_2, pr, pr_2, vm, vm_2;
int loops, loops_2, vm_count, p_count, v, ar_y;
 
init {
  fire_button = 4;
  scope_button = 7;
  RATE_OF_FIRE = get_pvar(SPVAR_1, 0, 25, 13);
 
  loops = (Total_Anti_Recoil_Time / 100) * (Progression_Point_Percent / 10);
  loops_2 = (Total_Anti_Recoil_Time / 10)  -loops;
  if (Starting_Anti_Recoil_Value < Mid_Point_Anti_Recoil_Value) inc = 1;
  else  inc = -1;
  if (Mid_Point_Anti_Recoil_Value < Ending_Anti_Recoil_Value) inc_2 = 1;
  else  inc_2 = -1;
  pr = abs(Starting_Anti_Recoil_Value-Mid_Point_Anti_Recoil_Value);
  pr_2 = abs(Mid_Point_Anti_Recoil_Value-Ending_Anti_Recoil_Value);
  vm = loops / pr;
  vm_2 = loops_2 / pr_2;
}
 
 
main {
  if (get_val(PS4_L2)) {
    if (Current_State == Get_Last_Value) {
      X_Last_Value = get_lval(PS4_RX);
      Y_Last_Value = get_lval(PS4_RY);
      Current_State = Get_Current_Value;
    }
    else if (Current_State == Get_Current_Value) {
      X_Current_Value = get_val(PS4_RX);
      Y_Current_Value = get_val(PS4_RY);
      if (Aim_Abuse_State == Aim_Correction) {
        Current_State = Aim_Boost;
      }
      else {
        Current_State = Aim_Correction;
      }
    }
    if (Current_State == Aim_Boost) {
      //Aim_Perfection(X_Last_Value, X_Current_Value, 1, 0, 1, 0);
      //Aim_Perfection(Y_Last_Value, Y_Current_Value, 1, 0, 0, 1);
      Current_State = Get_Last_Value;
      Aim_Abuse_State = Aim_Boost;
    }
    else if (Current_State == Aim_Correction) {
      //Aim_Perfection(X_Last_Value, X_Current_Value, 0, 1, 1, 0);
      //Aim_Perfection(Y_Last_Value, Y_Current_Value, 0, 1, 0, 1);
      Current_State = Get_Last_Value;
      Aim_Abuse_State = Aim_Correction;
    }
  }
  else {
    Current_State = Get_Last_Value;
    Aim_Abuse_State = Aim_Correction;
  }
  if (!get_lval(PS4_R2)) {
    p = 0;
    vm_count = 0;
    p_count = 0;
    ar_y = Starting_Anti_Recoil_Value;
  }
  if ((get_val(PS4_R2) && !get_val(PS4_L2)) || ((get_val(PS4_R2) && get_val(PS4_L2) && (Current_State == Get_Current_Value|| Current_State == Get_Last_Value)))) {
    //        p = p_cycle();
    //        if (p !=  -1) ar_y = p_val();
  }else{  ar_y = Ending_Anti_Recoil_Value;
    set_val(PS4_RY, f_y_val());
  }
  if (get_val(7) && event_press(RF_switch)) {
    combo_run(c_vibrate);
    rapid_onoff =! rapid_onoff;
  }
  if ((rapid_onoff)) f_colourled(Green);
  if ((!rapid_onoff)) f_colourled(Red);
  if (rapid_onoff) {
    if (get_val(4)) {
      combo_run(c_RAPID_FIRE);
    }
  }
  hold_time = 500 / RATE_OF_FIRE;
  rest_time = hold_time-20;
  if (rest_time < 0) rest_time = 0;
  if (get_val(19)) {
    if (event_press(UP)) {
      RATE_OF_FIRE = RATE_OF_FIRE+ 1;
    }
    if (event_press(DOWN)) {
      RATE_OF_FIRE = RATE_OF_FIRE-1;
    }
    set_val(UP, 0);
    set_val(DOWN, 0);
  }
  if (get_val(scope_button) && event_press(save)) {
    combo_run(c_vibrate);
    set_pvar(SPVAR_1, RATE_OF_FIRE);
    set_val(save, 0);
  }
  if (AS) if (get_val(L2)) combo_run(c_AS);
  if (Flipped) {
    swap(R1, R2);
    swap(L1, L2);
  }
  if (HT) deadzone(L2, R2, 100, 100);
  if (HB) if (get_val(L2)) set_val(L3, 100);
  if (HB) if (get_val(LY) < -90 && get_val(L2) && get_ptime(L2) > 200) combo_stop(c_CH);
  if (HB) if (event_press(L2)) combo_run(c_CH);
  if (HB) if (get_val(L2) && get_lval(L3)) set_val(L3, 0);
  if (RUN) if (get_val(LY) < -90 && !get_val(L2)) set_val(L3, 100);
  if (SS == ON && get_val(L2)) combo_stop(c_SS);
  if (SS) if (SP && get_val(LY) < -90) combo_run(c_SS);
  if (get_val(LY) > -90) SP = ON;
  if (get_val(L2)) {
    if (event_press(UP)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(RIGHT)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(DOWN)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(LEFT)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(R3)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(TRIANGLE)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(R1)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(L1)) {
      Remove_Block =! Remove_Block;
    }
    set_val(UP, 0);
    set_val(RIGHT, 0);
    set_val(DOWN, 0);
    set_val(LEFT, 0);
    set_val(R3, 0);
    set_val(TRIANGLE, 0);
    set_val(R1, 0);
    set_val(L1, 0);
  }
  if (get_val(OPTIONS)) {
    if (event_press(SHARE)) {
      Remove_Block =! Remove_Block;
    }
    set_val(SHARE, 0);
  }
}
 
 
combo c_CH {
  set_val(L3, 0);
  wait(60);
  set_val(L3, 100);
  wait(110);
  set_val(L3, 0);
  wait(110);
}
 
combo c_SS {
  wait(20);
  set_val(L3, 100);
  wait(40);
  set_val(L3, 0);
  wait(40);
  SP = OFF;
}
 
combo c_AS {
  set_val(RY, f_a_f(RY, AP));
  wait(Delay);
  set_val(RX, f_a_f(RX, AP));
  wait(Delay);
  set_val(RY, f_a_f(RY, AM));
  wait(Delay);
  set_val(RX, f_a_f(RX, AM));
  wait(Delay);
}
 
combo c_vibrate {
  set_rumble(RUMBLE_A, 100);
  wait(300);
  reset_rumble();
}
 
combo c_RAPID_FIRE {
  set_val(fire_button, 100);
  wait(hold_time);
  set_val(fire_button, 0);
  wait(rest_time);
  set_val(fire_button, 0);
}
 
 
function f_y_val() {
  v = get_val(PS4_RY);
  if (abs(v) < 10) v = 0;
  if (abs(v) > ar_y+ 5)
  return v;
  return v+ ar_y;
}
 
function f_a_f(p, m) {
  if (abs(get_val(p)) < ARelease)
  return m;
  return get_val(p);
}
 
function f_colourled(Colour) {
  Col_ind = (Colour * 4)  -3;
  set_led(LED_1, dbyte(Col_ind));
  set_led(LED_2, dbyte(Col_ind+ 1));
  set_led(LED_3, dbyte(Col_ind+ 2));
  set_led(LED_4, dbyte(Col_ind+ 3));
}

Re: T1/CM to Titan Two Script Converter [v0.27r3 - 01/26/202

PostPosted: Thu Jan 30, 2020 11:13 am
by TrayDay
Buffy wrote:Fixed 0.27r5, also fixed gpc attached

Thank you. The script you attached did indeed work. I also downloaded the updated converter.

DontAtMe wrote:
TrayDay wrote:I've tried converting this script. Yes, used the converter as well, and just can't get it to clear the errors of "invalid symbol redefinition" for "SS" and "AS". Identifiers?
This would not even compile on the CM.
The script was missing a few functions,

I commented out all the references to them though.
Not sure how well this script will work without them.
Code: Select all
//##################################################################################################
//Button Layout
//----------------------------------------------------------------------------------------------
//RF_SWITCH and AR_SWITCH toggle buttons // Change here with above numbers if needed
//----------------------------------------------------------------------------------------------
//RAPID FIRE XB1_Y - 17 17 UP 13 // CEMU_EXTRA1 = 21   
// XB1_MENU - 2 2 // CEMU_EXTRA3 = 23        SAVE BUTTON
//----------------------------------------------------------------------------------------------
//---------------------------------------------------------------------------------------------
//VARIABLES     - YOU CAN MAKE ADJUSTMENTS HERE IF NEEDED !!!!!
//---------------------------------------------------------------------------------------------
//SET OFF IF YOU DONT WANT SHAKY AIM ASSIST OR FEEL WEIRD BEHAVIOUR
//CHANGE OFF TO ON IF YOU PLAY WITH FLIPPED TRIGGERS
//CHANGE ON TO OFF IF YOU DON'T WANT AUTO RUN
//CHANGE OFF TO ON IF YOU WANT SUPER SPRINT - AUTO RUN MUST BE ON
//CHANGE ON TO OFF IF YOU DON'T WANT HAIR TRIGGER   
//CHANGE ON TO OFF IF YOU DON'T WANT HOLD BREATH   
// IF TRUE RAPIDFIRE IS ON BY DEFAULT - IF FALSE, OFF BY DEFAULT
// RANGE: 1 TO 25 RPS (ROUND/S)
//-------------------------------------------------------------------------------------------------
//  AIM ABUSE // INCREASE AP & AM FOR MORE ASSIST BUT IT CAN CAUSE SHAKE LIKE JUMPY CROSSHAIR
//                 MORE THAN 23 NOT RECOMMENDED. int AS = OFF TO DISABLE ABOVE   
//-------------------------------------------------------------------------------------------------
// ARELEASE MUST BE 1 HIGHER THAN AP & AM.
// DECREASE AP & AM IF YOU FEEL SHAKE OR WEIRD MOVEMENT AND DON'T LIKE IT.
// THIS WILL NOT AFFECT SWEET EVILS AIMBOT.
//#################################################################################################
//
// State machine variable
//
//
//#################################################################################################
//######################################### Script variable #######################################
//#################################################################################################
//
// Dont't change!
//
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//
//--Anti-Recoil Progression Adjustable Transition Point
//
//#################################################################################################
//
//--Anti-Recoil values go from Starting_Anti_Recoil_Value to Mid_Point_Anti_Recoil_Value over Progression_Point_Percent of Total_Anti_Recoil_Time
//--Anti-Recoil values then go from Mid_Point_Anti_Recoil_Value to Ending_Anti_Recoil_Value for the remaining Total_Anti_Recoil_Time percent
//--Ending_Anti_Recoil_Value is then applied until trigger release.
//
//--Zero's out controller input of less than 10
//
//#################################################################################################
//
//--Adjust These Values
//--postive values only
//-- 10ms increments (min - 2000)
//--percentage of total time to transition to mid to end values 10% increments
//
//#################################################################################################
//
//--Do not alter sequence of the variables below.  Script uses in-direct reference to access the values (ex... inc[0] = inc , inc[1] = inc_2)
//
//#################################################################################################
//
//
//#################################################################################################
//
//#################################################################################################
//############################################# MAIN ##############################################
//#################################################################################################
//
//update main every 8ms --> only for PS4
// vm_tctrl(-2);
//--LT pulled
//Applying BOOST
////Aim_Perfection(Last_Value, Current_Value, Boost, Correction, X_AXIS, Y_AXIS )
//Applying CORRECTION
////Aim_Perfection(Last_Value, Current_Value, Boost, Correction, X_AXIS, Y_AXIS )
//--LT not pulled
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//
//--reset counters/pointers
//--anti recoil
// CHANGE 7 INTO DESIRED BUTTON FOR TOGGLE DEFINED ABOVE
// SAVE VALUES TO DEVICE MONITOR
//
//#################################################################################################
//############################################# FUNC ##############################################
//#################################################################################################
//           
//Rounding integer division (instead of truncating)
//--moving right
//--moving left
//
//#################################################################################################
//####################################### Batts anti-recoil #######################################
//#################################################################################################
//   
//--return progression index
//--return current ar val
//--return ar val + input or input if above release
// COLOR LED function
//--------------------------------------------------------------
//
//#################################################################################################
//############################################# END ###############################################
//#################################################################################################
 
define PS = 0;
define SHARE = 1;
define OPTIONS = 2;
define R1 = 3;
define R2 = 4;
define R3 = 5;
define L1 = 6;
define L2 = 7;
define L3 = 8;
define RX = 9;
define RY = 10;
define LX = 11;
define LY = 12;
define UP = 13;
define DOWN = 14;
define LEFT = 15;
define RIGHT = 16;
define TRIANGLE = 17;
define CIRCLE = 18;
define CROSS = 19;
define SQUARE = 20;
define TOUCHPAD = 27;
define Blue = 1;
define Red = 2;
define Green = 3;
define Pink = 4;
define SkyBlue = 5;
define Yellow = 6;
define White = 7;
define RF_switch = 17;
define save = 2;
define ON = TRUE;
define OFF = FALSE;
define Get_Last_Value = 0;
define Get_Current_Value = 1;
define Aim_Correction = 2;
define Aim_Boost = 3;
define Aim_Perfection_Limit = 60;
define Starting_Anti_Recoil_Value = 20;
define Mid_Point_Anti_Recoil_Value = 28;
define Ending_Anti_Recoil_Value = 10;
define Total_Anti_Recoil_Time = 2500;
define Progression_Point_Percent = 30;
 
int AS = ON;
int Flipped = OFF;
int RUN = OFF;
int SS = OFF;
int HT = ON;
int HB = OFF;
int rapid_onoff = TRUE;
int RATE_OF_FIRE = 13;
int Col_ind;
int fire_button;
int scope_button;
int hold_time;
int rest_time;
int SP = ON;
int Remove_Block;
int AP = 20;
int AM = -20;
int Delay = 20;
int ARelease = 21;
int Current_State = 0;
int Aim_Abuse_State = 2;
int X_Last_Value = 0;
int Y_Last_Value = 0;
int X_Current_Value = 0;
int Y_Current_Value = 0;
int mvt = 0;
int Aim_Boost_Val = 0;
int Aim_Correction_Val = 0;
int p, inc, inc_2, pr, pr_2, vm, vm_2;
int loops, loops_2, vm_count, p_count, v, ar_y;
 
init {
  fire_button = 4;
  scope_button = 7;
  RATE_OF_FIRE = get_pvar(SPVAR_1, 0, 25, 13);
 
  loops = (Total_Anti_Recoil_Time / 100) * (Progression_Point_Percent / 10);
  loops_2 = (Total_Anti_Recoil_Time / 10)  -loops;
  if (Starting_Anti_Recoil_Value < Mid_Point_Anti_Recoil_Value) inc = 1;
  else  inc = -1;
  if (Mid_Point_Anti_Recoil_Value < Ending_Anti_Recoil_Value) inc_2 = 1;
  else  inc_2 = -1;
  pr = abs(Starting_Anti_Recoil_Value-Mid_Point_Anti_Recoil_Value);
  pr_2 = abs(Mid_Point_Anti_Recoil_Value-Ending_Anti_Recoil_Value);
  vm = loops / pr;
  vm_2 = loops_2 / pr_2;
}
 
 
main {
  if (get_val(PS4_L2)) {
    if (Current_State == Get_Last_Value) {
      X_Last_Value = get_lval(PS4_RX);
      Y_Last_Value = get_lval(PS4_RY);
      Current_State = Get_Current_Value;
    }
    else if (Current_State == Get_Current_Value) {
      X_Current_Value = get_val(PS4_RX);
      Y_Current_Value = get_val(PS4_RY);
      if (Aim_Abuse_State == Aim_Correction) {
        Current_State = Aim_Boost;
      }
      else {
        Current_State = Aim_Correction;
      }
    }
    if (Current_State == Aim_Boost) {
      //Aim_Perfection(X_Last_Value, X_Current_Value, 1, 0, 1, 0);
      //Aim_Perfection(Y_Last_Value, Y_Current_Value, 1, 0, 0, 1);
      Current_State = Get_Last_Value;
      Aim_Abuse_State = Aim_Boost;
    }
    else if (Current_State == Aim_Correction) {
      //Aim_Perfection(X_Last_Value, X_Current_Value, 0, 1, 1, 0);
      //Aim_Perfection(Y_Last_Value, Y_Current_Value, 0, 1, 0, 1);
      Current_State = Get_Last_Value;
      Aim_Abuse_State = Aim_Correction;
    }
  }
  else {
    Current_State = Get_Last_Value;
    Aim_Abuse_State = Aim_Correction;
  }
  if (!get_lval(PS4_R2)) {
    p = 0;
    vm_count = 0;
    p_count = 0;
    ar_y = Starting_Anti_Recoil_Value;
  }
  if ((get_val(PS4_R2) && !get_val(PS4_L2)) || ((get_val(PS4_R2) && get_val(PS4_L2) && (Current_State == Get_Current_Value|| Current_State == Get_Last_Value)))) {
    //        p = p_cycle();
    //        if (p !=  -1) ar_y = p_val();
  }else{  ar_y = Ending_Anti_Recoil_Value;
    set_val(PS4_RY, f_y_val());
  }
  if (get_val(7) && event_press(RF_switch)) {
    combo_run(c_vibrate);
    rapid_onoff =! rapid_onoff;
  }
  if ((rapid_onoff)) f_colourled(Green);
  if ((!rapid_onoff)) f_colourled(Red);
  if (rapid_onoff) {
    if (get_val(4)) {
      combo_run(c_RAPID_FIRE);
    }
  }
  hold_time = 500 / RATE_OF_FIRE;
  rest_time = hold_time-20;
  if (rest_time < 0) rest_time = 0;
  if (get_val(19)) {
    if (event_press(UP)) {
      RATE_OF_FIRE = RATE_OF_FIRE+ 1;
    }
    if (event_press(DOWN)) {
      RATE_OF_FIRE = RATE_OF_FIRE-1;
    }
    set_val(UP, 0);
    set_val(DOWN, 0);
  }
  if (get_val(scope_button) && event_press(save)) {
    combo_run(c_vibrate);
    set_pvar(SPVAR_1, RATE_OF_FIRE);
    set_val(save, 0);
  }
  if (AS) if (get_val(L2)) combo_run(c_AS);
  if (Flipped) {
    swap(R1, R2);
    swap(L1, L2);
  }
  if (HT) deadzone(L2, R2, 100, 100);
  if (HB) if (get_val(L2)) set_val(L3, 100);
  if (HB) if (get_val(LY) < -90 && get_val(L2) && get_ptime(L2) > 200) combo_stop(c_CH);
  if (HB) if (event_press(L2)) combo_run(c_CH);
  if (HB) if (get_val(L2) && get_lval(L3)) set_val(L3, 0);
  if (RUN) if (get_val(LY) < -90 && !get_val(L2)) set_val(L3, 100);
  if (SS == ON && get_val(L2)) combo_stop(c_SS);
  if (SS) if (SP && get_val(LY) < -90) combo_run(c_SS);
  if (get_val(LY) > -90) SP = ON;
  if (get_val(L2)) {
    if (event_press(UP)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(RIGHT)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(DOWN)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(LEFT)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(R3)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(TRIANGLE)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(R1)) {
      Remove_Block =! Remove_Block;
    }
    if (event_press(L1)) {
      Remove_Block =! Remove_Block;
    }
    set_val(UP, 0);
    set_val(RIGHT, 0);
    set_val(DOWN, 0);
    set_val(LEFT, 0);
    set_val(R3, 0);
    set_val(TRIANGLE, 0);
    set_val(R1, 0);
    set_val(L1, 0);
  }
  if (get_val(OPTIONS)) {
    if (event_press(SHARE)) {
      Remove_Block =! Remove_Block;
    }
    set_val(SHARE, 0);
  }
}
 
 
combo c_CH {
  set_val(L3, 0);
  wait(60);
  set_val(L3, 100);
  wait(110);
  set_val(L3, 0);
  wait(110);
}
 
combo c_SS {
  wait(20);
  set_val(L3, 100);
  wait(40);
  set_val(L3, 0);
  wait(40);
  SP = OFF;
}
 
combo c_AS {
  set_val(RY, f_a_f(RY, AP));
  wait(Delay);
  set_val(RX, f_a_f(RX, AP));
  wait(Delay);
  set_val(RY, f_a_f(RY, AM));
  wait(Delay);
  set_val(RX, f_a_f(RX, AM));
  wait(Delay);
}
 
combo c_vibrate {
  set_rumble(RUMBLE_A, 100);
  wait(300);
  reset_rumble();
}
 
combo c_RAPID_FIRE {
  set_val(fire_button, 100);
  wait(hold_time);
  set_val(fire_button, 0);
  wait(rest_time);
  set_val(fire_button, 0);
}
 
 
function f_y_val() {
  v = get_val(PS4_RY);
  if (abs(v) < 10) v = 0;
  if (abs(v) > ar_y+ 5)
  return v;
  return v+ ar_y;
}
 
function f_a_f(p, m) {
  if (abs(get_val(p)) < ARelease)
  return m;
  return get_val(p);
}
 
function f_colourled(Colour) {
  Col_ind = (Colour * 4)  -3;
  set_led(LED_1, dbyte(Col_ind));
  set_led(LED_2, dbyte(Col_ind+ 1));
  set_led(LED_3, dbyte(Col_ind+ 2));
  set_led(LED_4, dbyte(Col_ind+ 3));
}


I was noticing something was off. I continued to trial and error the best of my knowledge but couldn't get passed the 2 errors that continued to plague me. The script Buffy provided, did indeed work. But while utilizing it, I noticed needed a little touch up in the settings noticed a few similarities with Scachi's script. About the script not being able to work with CM, I understood this as I figured I would need a larger size as I also have a microSD which I placed the script on as the large size is not a problem. Thank you for your input and the corrections.

Re: T1/CM to Titan Two Script Converter [v0.27r3 - 01/26/202

PostPosted: Thu Jan 30, 2020 6:44 pm
by Buffy
TrayDay wrote:I was noticing something was off. I continued to trial and error the best of my knowledge but couldn't get passed the 2 errors that continued to plague me. The script Buffy provided, did indeed work. But while utilizing it, I noticed needed a little touch up in the settings noticed a few similarities with Scachi's script. About the script not being able to work with CM, I understood this as I figured I would need a larger size as I also have a microSD which I placed the script on as the large size is not a problem. Thank you for your input and the corrections.


It was an error with the converter, not the script itself. Should all be good now.

Re: T1/CM to Titan Two Script Converter [v0.28 - 04/05/2020]

PostPosted: Fri May 08, 2020 9:10 am
by Prototype
I have a question about the T1.gph use. What is the interval used, is it 10ms ? I ask because i tried one and the vm_tctrl seems to stress the CPU !

Re: T1/CM to Titan Two Script Converter [v0.28 - 04/05/2020]

PostPosted: Fri May 08, 2020 11:12 pm
by Buffy
prototype wrote:I have a question about the T1.gph use. What is the interval used, is it 10ms ? I ask because i tried one and the vm_tctrl seems to stress the CPU !

It's essentially running scripts similar to how a T1 runs them (every 10ms, or whatever the vm_tctrl is set to). Due to how some scripts were coded for the T1, this is essential to fix bugs that may occur. I've just released 0.28r2, which should reduce CPU usage a bit when using the VM mode (thanks to DontAtMe for his help and code).

Re: T1/CM to Titan Two Script Converter [v0.28r2 - 05/08/202

PostPosted: Sat May 09, 2020 12:43 pm
by Prototype
Ok, thanks for the update. I'm going to try.

Re: T1/CM to Titan Two Script Converter [v0.28r2 - 05/08/202

PostPosted: Tue May 12, 2020 8:34 pm
by Ghost251313
Will it be possible to convert Zen gpc files, with that crappy Oled code?

Re: T1/CM to Titan Two Script Converter [v0.28r2 - 05/08/202

PostPosted: Mon May 18, 2020 9:24 pm
by J2Kbr
Ghost251313 wrote:Will it be possible to convert Zen gpc files, with that crappy Oled code?

I didn't try yet. However, I believe it should be possible, provided the OLED part gets removed/commented. Or better, redirected to GPC2 printf() calls.

Re: T1/CM to Titan Two Script Converter [v0.28r2 - 05/08/202

PostPosted: Fri May 29, 2020 12:43 pm
by Drifter_2012
thanks works great