PDA

View Full Version : SFV RYU Script



mnguyen
28th March 16, 14:07
Hi,
This is my SFV Ryu script. I have used it in matches and it works pretty well. I use a HORI FIGHT COMMANDER 4 controller which has 2 extra shoulder buttons which are perfect for the cronusmax.
I have similar scripts for Nash, Ken, Cammy and Karin.


// I USE THE HORI FIGHT COMMANDER 4 WHICH HAVE L1 L2 L3 R3 TRIGGERS.
// THIS SCRIPT MAKES USE OF THE EXTRA L3 AND R3 TRIGGERS.


// ----- CONTROLLER BUTTONS --------------------------
// USING DEFAULT CONFIGURATION SETTINGS FOR THE BUTTONS
//
define BTN_LP = 20; //SQUARE
define BTN_MP = 17; //TRIANGLE
define BTN_HP = 3; //R1
define BTN_LK = 19; //CROSS
define BTN_MK = 18; //CIRCLE
define BTN_HK = 4; //R2
define BTN_L1 = 6; //USUALLY PPP BUT I USE IT FOR OTHER FUNCTIONS
define BTN_L2 = 7; //USUALLY KKK BUT I USE IT FOR OTHER FUNCTIONS
define BTN_L3 = 8;
define BTN_R3 = 5;


// ----- BUTTON CODES --------------------------------
// USE A 16 BIT INTEGER FOR BUTTON CODES IN COMBOS
// BIT 0 = LP
// BIT 1 = MP
// BIT 2 = HP
// BIT 3 = LK
// BIT 4 = MK
// BIT 5 = HK
//
define VAR = 99; //VARIABLE USED IN RUN COMBO


define NP = 63; //111111 NO PRESS
define NB = 0; //000000 NO BUTTON
define LP = 1; //000001
define MP = 2; //000010
define HP = 4; //000100
define LK = 8; //001000
define MK = 16; //010000
define HK = 32; //100000


define LP_MP = 3; //000011
define LP_HP = 5; //000101
define LP_MP_HP = 7; //000111
define MP_HP = 6; //000110


define LK_MK = 24; //011000
define LK_HK = 40; //101000
define LK_MK_HK = 56; //111000
define LK_MP = 10; //001010
define LK_HP = 12; //001100
define MK_HP = 20; //010100
define MK_HK = 48; //110000


define LP_LK = 9; //001001
define LP_MP_MK = 19; //010011
define LP_MK = 17; //010001
define LP_HK = 33; //100001
define MP_MK = 18; //010010
define HP_HK = 36; //100100


define LP_MP_HP_LK = 15;//001111
define LP_MP_HP_HK = 39;//100111
define LP_MP_HP_MK = 23;//010111
define LP_LK_MK_HK = 57;//111001


// ----- DIRECTIONS ----------------------------------
// USE A 16 BIT INTEGER FOR DIRECTIONS IN COMBOS
// USED IN CONJUCTION WITH WHAT DIRECTION YOU ARE FACING
// BIT 0 = FORWARD
// BIT 1 = BACK
// BIT 2 = DOWN
// BIT 3 = UP
//
define ND = 15; //1111 DO NOT SET DIRECTION
define N = 0; //0000 NEUTRAL
define F = 1; //0001
define DF = 5; //0101
define D = 4; //0100
define DB = 6; //0110
define B = 2; //0010
define BU = 10; //1010
define U = 8; //1000
define UF = 9; //1001


// ----- DEFINE VARIABLES ----------------------------
// VARIABLE TO DETERMINE WHICH WAY YOU ARE FACING
// I ASSUME IF YOU ARE HOLDING LEFT THEN YOU ARE BLOCKING
// AND RIGHT IS FORWARD. THIS VARIABLE IS USED TO DETERMINE
// HOW LONG YOU MUST HOLD THE DIRECTION FOR THE SCRIPT TO CHANGE
// THE WAY YOU ARE FACING
//
define FACINGSWITCHTIME = 5; //MILLISECONDS


// ----- DEFINE DELAY TIMES --------------------------
// DELAY TIME TIMES TO DETERMINE HOW LONG SINCE YOU PRESSED
// THE CORRESPONDING BUTTON. THIS IS USED TO PERFORM MOVES
// WHEN YOU PRESS CERTIAN BUTTON COMBINATIONS.
//
define LP_DELAY_LIMIT = 200;
define MP_DELAY_LIMIT = 300;
define HP_DELAY_LIMIT = 200;
define LK_DELAY_LIMIT = 200;
define MK_DELAY_LIMIT = 200;
define HK_DELAY_LIMIT = 200;
define L1_DELAY_LIMIT = 200;
define L2_DELAY_LIMIT = 200;
define L3_DELAY_LIMIT = 400;
define R3_DELAY_LIMIT = 400;
define JUMP_DELAY_LIMIT = 800;
define COMBO_DELAY_LIMIT = 800;


// ----- ARRAY SIZES AND VARIABLES -------------------
define TIME_VAR_COUNT = 14;
define BOOL_COUNT = 19;
define DELAY_COUNT = 12;
define BUTTON_CODE_COUNT = 11;


// ----- TIME VARIABLE ARRAY INDEXES -----------------
define I_LP = 0;
define I_MP = 1;
define I_HP = 2;
define I_LK = 3;
define I_MK = 4;
define I_HK = 5;
define I_L1 = 6;
define I_L2 = 7;
define I_L3 = 8;
define I_R3 = 9;
define I_JUMP = 10;
define I_COMBO = 11;
define HOLD_TIME_RIGHT = 12;
define HOLD_TIME_LEFT = 13;


// ----- BOOL INDEXES ------------------------------
// I HAVE AN ARRAY OF VARIABLES USED A BOOLEANS. THESE
// ARE SET WHEN CERTAIN CONDITIONS ARE MET
//
define DELAY_EN_LP = 0; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_MP = 1; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_HP = 2; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_LK = 3; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_MK = 4; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_HK = 5; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_L1 = 6; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_L2 = 7; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_L3 = 8; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_R3 = 9; //LP PRESSED WITHIN DELAY TIME
define DELAY_EN_JUMP = 10; //JUMP (UP) PRESSED WITHIN DELAY
define DELAY_EN_COMBO = 11; //A COMBO WAS RUN WITHIN DELAY TIME
define DIR_BACK = 12; //BACK IS BEING PRESSED
define DIR_DOWN_BACK = 13; //DOWN BACK IS BEING PRESSED
define DIR_DOWN = 14; //DOWN IS BEING PRESSED
define DIR_NEUTRAL = 15; //NO DIRECTIONS ARE BEING PRESSESD
define DIR_UP = 16; //UP IS BEING PRESSED
define DIR_DOWN_ANY = 17;//DOWN OR DOWN BACK BEING PRESSED
define DIR_BACK_ANY = 18;//BACK OR DOWN BACK BEING PRESSED


// ----- COMBO INDEXES -------------------------------
// COMBO INDEXES THAT POINT TO THE DATA SECTION
// I HAVE CREATED A SPREADSHEET THAT WILL GENERATE THE COMBO
// INDEXES AND COMBO DATA
//
define THROW = 0;
define V_SKILL = 6;
define V_TRIGGER = 12;
define V_REVERSAL = 18;
define V_REVERSAL_TRIGGER_OS = 24;
define V_REVERSAL_THROW_OS = 33;
define SUPER = 39;
define SUPER_V_REVERSAL_OS = 54;
define FIREBALL = 69;
define DRAGON_PUNCH = 84;
define DRAGON_PUNCH_CROSSUP = 96;
define TATSU = 114;
define TARGET_COMBO_1 = 126;
define TARGET_COMBO_2 = 147;
define SMP_CMK = 165;
define SMP_CHP = 186;
define V_REVERSAL_SKILL_OS = 207;


// ----- COMBO DATA ----------------------------------
// COMBO DATA IS BROKEN UP INTO STEPS. EACH STEP CONSISTS
// OF 3 PARTS: DIRECTION, BUTTONS, AND WAIT TIME AFTER.
// THE WAIT TIME LISTED WILL BE MULTIPLIED BY 5 SINCE A
// BYTE CAN ONLY HOLD 255. THIS ALLOWS FOR LONGER WAIT TIMES.
// A WAIT TIME OF 0 WILL END THE COMBO.
//
// ([D,B,W] * 15)
// D: Direction Input
// B: Buttons
// W: Wait Time * 5 (2 = 10);
//
data
(
N,LP_LK,4, ND,NB,0, //THROW
ND,MP_MK,4, ND,NB,0, //V_SKILL
ND,HP_HK,4, ND,NB,0, //V_TRIGGER
F,LP_MP_HP,4, ND,NB,0, //V_REVERSAL
ND,NB,4, DF,LP_MP_HP_HK,4, ND,NB,0, //V_REVERSAL_TRIGGER_OS
F,LP_MP_HP_LK,4, ND,NB,0, //V_REVERSAL_THROW_OS
D,NB,4, F,NB,4, D,NB,4, F,VAR,4, ND,NB,0, //SUPER
D,NB,4, F,NB,4, D,NB,4, F,LP_MP_HP,4, ND,NB,0, //SUPER_V_REVERSAL_OS
DB,NB,4, D,NB,4, DF,NB,4, F,VAR,4, ND,NB,0, //FIREBALL
F,NB,4, D,NB,4, DF,VAR,4, ND,NB,0, //DRAGON_PUNCH
DF,NB,4, DB,NB,4, D,NB,4, DF,NB,4, DB,VAR,4, ND,NB,0, //DRAGON_PUNCH_CROSSUP - I FIND THIS ACTUALLY DOES DRAGON PUNCH REGARDLESS IF YOU ARE PRESSING FORWARD OR BACKWARD
D,NB,4, DB,NB,4, B,VAR,4, ND,NB,0, //TATSU
N,HP,20, N,HK,4, N,NB,50, N,HK,4, N,NB,4, N,HK,4, N,NB,0, //TARGET_COMBO_1
N,MP,20, N,HP,80, N,HK,4, N,NB,4, N,HK,4, N,NB,0, //TARGET_COMBO_2
N,MP,78, D,MK,4, N,NB,4, D,MK,4, N,NB,4, D,MK,4, N,NB,0, //SMP_CMK - STANDING MP CROUCHING MK LINK
N,MP,78, D,HP,4, N,NB,4, D,HP,4, N,NB,4, D,HP,4, N,NB,0, //SMP_CHP - STANDING MP CROUCHING HP LINK
F,LP_MP_HP_MK,4, ND,NB,0 //V_REVERSAL_SKILL_OS
);


// GLOBAL VARIABLES
int loopIndex = 0;
int maxSlot = 0;
int slot = 0;
int rtime = 0;
int comboIndex = 0;
int comboVarButton = 0;
int facingRight = 0;


// ARRAYS
int timeVar[TIME_VAR_COUNT];
int delayLimit[DELAY_COUNT];
int ctrlButtCode[BUTTON_CODE_COUNT];
int blockButtons[BUTTON_CODE_COUNT];
int bool[BOOL_COUNT];


init
{
// GETS THE PERSISTENT VARIABLES FOR MAX SLOT
// THIS IS USED WHEN CYCLYING THROUGH THE SLOTS
// FOR DIFFERENT CHARACTERS. I USE A DUMMY SCRIPT
// IN SLOT 1 WHICH SETS THE MAX SLOTS AND LETS ME
// HAVE A REGULAR CONTROLLER IF NEED BE
maxSlot = get_pvar(PVAR_1, 1, 9, 1);


// SET THE DELAY LIMITS
delayLimit[I_LP] = LP_DELAY_LIMIT;
delayLimit[I_MP] = MP_DELAY_LIMIT;
delayLimit[I_HP] = HP_DELAY_LIMIT;
delayLimit[I_LK] = LK_DELAY_LIMIT;
delayLimit[I_MK] = MK_DELAY_LIMIT;
delayLimit[I_HK] = HK_DELAY_LIMIT;
delayLimit[I_L1] = L1_DELAY_LIMIT;
delayLimit[I_L2] = L2_DELAY_LIMIT;
delayLimit[I_L3] = L3_DELAY_LIMIT;
delayLimit[I_R3] = R3_DELAY_LIMIT;
delayLimit[I_JUMP] = JUMP_DELAY_LIMIT;
delayLimit[I_COMBO] = COMBO_DELAY_LIMIT;


// POPULATES BUTTON ARRAY FOR DELAY TIME PROCESSING
ctrlButtCode[I_LP] = BTN_LP;
ctrlButtCode[I_MP] = BTN_MP;
ctrlButtCode[I_HP] = BTN_HP;
ctrlButtCode[I_LK] = BTN_LK;
ctrlButtCode[I_MK] = BTN_MK;
ctrlButtCode[I_HK] = BTN_HK;
ctrlButtCode[I_L1] = BTN_L1;
ctrlButtCode[I_L2] = BTN_L2;
ctrlButtCode[I_L3] = BTN_L3;
ctrlButtCode[I_R3] = BTN_R3;
ctrlButtCode[I_JUMP] = PS3_UP;


// SET INITIAL VALUES FOR TIME ARRAY
loopIndex = 0;
while( loopIndex < DELAY_COUNT )
{
timeVar[loopIndex] = delayLimit[loopIndex];
bool[loopIndex] = 0;

loopIndex = loopIndex + 1;
}
}


main
{
// CHANGE SLOT IF R3 AND START PRESSED
ChangeSlot();


// RECONNECT IF L3 AND START PRESSED
Reconnect();


// DETERMINE WHICH WAY YOU ARE FACING
GetFacingDirection();


// PROCESS BUTTON DELAY TIMES
GetDelay();


// DETERMINE WHICH DIRECTION(S) ARE BEING HELD
GetHoldDirection();

// PROCESS BUTTON PRESSES THIS IS THE MAIN SECTION
if (!combo_running(MainCombo))
DoButtonPresses();


BlockButtons();
}


// THE MAIN COMBO ROUTINE. I USED THIS ROUTINE INSTEAD OF A COMBO STEP LOOP IN THE MAIN SECTION
// BECAUSE THIS SEEMS MORE RELIABLE. IT USES MORE MEMORY BUT IT SEEMS TO WORK BETTER
// I PROGRAMMED IT FOR 15 STEPS INITIALLY BUT FOUND THAT I DIDNT NEED ALL OF THEM. THE REST IS
// COMMENTED OUT TO SAVE MEMORY
combo MainCombo
{
// RESET LAST COMBO RUN TIME
timeVar[I_COMBO] = 0;


// Step 1
SendInput(dbyte(comboIndex+0), dbyte(comboIndex+1));
if (dbyte(comboIndex+2) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+2) * 5);


// Step 2
SendInput(dbyte(comboIndex+3), dbyte(comboIndex+4));
if (dbyte(comboIndex+5) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+5) * 5);

// Step 3
SendInput(dbyte(comboIndex+6), dbyte(comboIndex+7));
if (dbyte(comboIndex+8) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+8) * 5);


// Step 4
SendInput(dbyte(comboIndex+9), dbyte(comboIndex+10));
if (dbyte(comboIndex+11) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+11) * 5);


// Step 5
SendInput(dbyte(comboIndex+12), dbyte(comboIndex+13));
if (dbyte(comboIndex+14) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+14) * 5);

// Step 6
SendInput(dbyte(comboIndex+15), dbyte(comboIndex+16));
if (dbyte(comboIndex+17) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+17) * 5);


// Step 7
SendInput(dbyte(comboIndex+18), dbyte(comboIndex+19));
if (dbyte(comboIndex+20) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+20) * 5);

// Step 8
SendInput(dbyte(comboIndex+21), dbyte(comboIndex+22));
if (dbyte(comboIndex+23) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+23) * 5);


// Step 9
SendInput(dbyte(comboIndex+24), dbyte(comboIndex+25));
if (dbyte(comboIndex+26) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+26) * 5);


// Step 10
SendInput(dbyte(comboIndex+27), dbyte(comboIndex+28));
if (dbyte(comboIndex+29) == 0)
{
combo_stop(MainCombo);
}
wait(dbyte(comboIndex+29) * 5);


// Step 11
//SendInput(dbyte(comboIndex+30), dbyte(comboIndex+31));
//if (dbyte(comboIndex+32) == 0)
//{
// combo_stop(MainCombo);
//}
//wait(dbyte(comboIndex+32) * 5);


// Step 12
//SendInput(dbyte(comboIndex+33), dbyte(comboIndex+34));
//if (dbyte(comboIndex+35) == 0)
//{
// combo_stop(MainCombo);
//}
//wait(dbyte(comboIndex+35) * 5);


// Step 13
//SendInput(dbyte(comboIndex+36), dbyte(comboIndex+37));
//if (dbyte(comboIndex+38) == 0)
//{
// combo_stop(MainCombo);
//}
//wait(dbyte(comboIndex+38) * 5);


// Step 14
//SendInput(dbyte(comboIndex+39), dbyte(comboIndex+40));
//if (dbyte(comboIndex+41) == 0)
//{
// combo_stop(MainCombo);
//}
//wait(dbyte(comboIndex+41) * 5);


// Step 15
//SendInput(dbyte(comboIndex+42), dbyte(comboIndex+43));
//if (dbyte(comboIndex+44) == 0)
//{
// combo_stop(MainCombo);
//}
//wait(dbyte(comboIndex+44) * 5);


// RELEASE THE BUTTONS IF THE COMBO REACHES THIS FAR.
// IF NOT RELEASED, THE LAST MOVE SOMETIMES DOESNT COME
SendInput(ND,NB);
}


// SENDS DIRECTION AND BUTTON PRESSES
// THE COMBOVARBUTTON VARIABLE IS USED TO SEND DIFFERENT BUTTONS FOR
// SPECIAL MOVES
function SendInput(direction, buttons)
{
if (direction != ND)
{
if (facingRight)
{
set_val(PS3_RIGHT, test_bit(direction, 0) * 100);
set_val(PS3_LEFT, test_bit(direction, 1) * 100);
}
else
{
set_val(PS3_RIGHT, test_bit(direction, 1) * 100);
set_val(PS3_LEFT, test_bit(direction, 0) * 100);
}
set_val(PS3_DOWN, test_bit(direction, 2) * 100);
set_val(PS3_UP, test_bit(direction, 3) * 100);
}


if (buttons != NP)
{
if (buttons == VAR)
buttons = comboVarButton;


set_val(BTN_LP, test_bit(buttons, 0) * 100);
set_val(BTN_MP, test_bit(buttons, 1) * 100);
set_val(BTN_HP, test_bit(buttons, 2) * 100);
set_val(BTN_LK, test_bit(buttons, 3) * 100);
set_val(BTN_MK, test_bit(buttons, 4) * 100);
set_val(BTN_HK, test_bit(buttons, 5) * 100);
}
}


// CALL THIS TO PERFORM COMBO WITH THE COMBOINDEX AND BUTTONS
function RunCombo(selectedCombo, variableButton)
{
comboIndex = selectedCombo;
comboVarButton = variableButton;
combo_run(MainCombo);
}


function ChangeSlot()
{
// Change Slots
if (get_val(PS3_R3) && event_press(PS3_START))
{
slot = get_slot();
if (slot < maxSlot)
load_slot(slot+1);
else
load_slot(1);
}
}


function Reconnect()
{
if (get_val(PS3_L3) && event_press(PS3_START))
output_reconnection();
}


function GetFacingDirection()
{
rtime = get_rtime();


// Get Facing Direction
if (get_val(PS3_RIGHT))
{
timeVar[HOLD_TIME_LEFT] = 0;
timeVar[HOLD_TIME_RIGHT] = timeVar[HOLD_TIME_RIGHT] + rtime;


if (!get_val(PS3_UP))
{
if (timeVar[HOLD_TIME_RIGHT] > FACINGSWITCHTIME)
facingRight = 0;
}
}

if (get_val(PS3_LEFT))
{
timeVar[HOLD_TIME_RIGHT] = 0;
timeVar[HOLD_TIME_LEFT] = timeVar[HOLD_TIME_LEFT] + rtime;


if (!get_val(PS3_UP))
{
if (timeVar[HOLD_TIME_LEFT] > FACINGSWITCHTIME)
facingRight = 1;
}
}
}


function GetDelay()
{
loopIndex = 0;
while( loopIndex < DELAY_COUNT )
{
timeVar[loopIndex] = timeVar[loopIndex] + rtime;


// IF DELAY TIME EXPIRED RESET BOOL
if (timeVar[loopIndex] >= delayLimit[loopIndex])
{
bool[loopIndex] = 0;
timeVar[loopIndex] = delayLimit[loopIndex];
}
else // STILL WITHIN THE DELAY TIME
{
bool[loopIndex] = 1;
}


// RESET DELAY TIME WHEN BUTTON IS PRESSED
if (loopIndex < BUTTON_CODE_COUNT && event_press(ctrlButtCode[loopIndex]) && !bool[loopIndex])
{
timeVar[loopIndex] = 0;
bool[loopIndex] = 0;
}

loopIndex = loopIndex + 1
}
}


// DETERMINES WHICH DIRECTION IS BEING HELD
// THERE IS NO FORWARD SINCE I HAVENT FOUND A WAY TO DETERMINE WHICH WAY
// THE CHARACTER IS FACING FOR SURE. SO IF YOU ARE PRESSING RIGHT OR LEFT IT WILL ALWAYS
// ASSUME THAT YOU ARE PRESSING BACK
function GetHoldDirection()
{
bool[DIR_BACK] = 0;
bool[DIR_DOWN_BACK] = 0;
bool[DIR_DOWN] = 0;
bool[DIR_NEUTRAL] = 0;
bool[DIR_UP] = 0;
bool[DIR_DOWN_ANY] = 0;
bool[DIR_BACK_ANY] = 0;


if (get_val(PS3_UP))
{
bool[DIR_UP] = 1;
}
else if (get_val(PS3_LEFT) || get_val(PS3_RIGHT))
{
if (get_val(PS3_DOWN))
{
bool[DIR_DOWN_BACK] = 1;
bool[DIR_DOWN_ANY] = 1;
bool[DIR_BACK_ANY] = 1;
}
else
{
bool[DIR_BACK] = 1;
bool[DIR_BACK_ANY] = 1;
}
}
else if (get_val(PS3_DOWN))
{
bool[DIR_DOWN] = 1;
bool[DIR_DOWN_ANY] = 1;
}
else
{
bool[DIR_NEUTRAL] = 1;
}
}


function DoButtonPresses()
{
L3Press(); L1Press();
R3Press(); L2Press();


LPPress(); MPPress(); HPPress();
LKPress(); MKPress(); HKPress();

STARTPress();
}


function BlockButtons()
{
// BLOCK L1 AND L2
// I BLOCK L1 AND L2 SINCE I USE THEM FOR OTHER THINGS
// AND DO NOT WANT TO SEND PPP AND KKK AND TO AVOID CHANGEING
// THE DEFAULT BUTTON CONFIG
if (get_val(BTN_L1))
set_val(BTN_L1, 0);


if (get_val(BTN_L2))
set_val(BTN_L2, 0);


// BLOCK START SINCE I USE IT FOR SUPERS
if (get_val(PS3_START))
set_val(PS3_START, 0);

// CHANGE SELECT TO START AND BLOCK SELECT SINCE IT IS ALSO
// THE SHARE BUTTON ON PS4
if (get_val(PS3_SELECT))
{
set_val(PS3_SELECT, 0);
set_val(PS3_START, 100);
}
}


// I USE L3 MOSTLY FOR FIREBALLS
function L3Press()
{
if (event_press(BTN_L3))
{
if (bool[DELAY_EN_JUMP])
{
}
else if (bool[DELAY_EN_MP] || bool[DELAY_EN_HP] || (bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY]))
{
RunCombo(FIREBALL, HP);
}
else
{
if (bool[DIR_BACK])
{
// I FOUND IF YOU SEND FIREBALL WITH A KICK AND PUNCH BUTTON IT WILL DO A FIREBALL IF YOU ARE
// HOLDING BACK AND TATSU IF YOU ARE HOLDING FORWARD. BUT THE BUTTONS CANNOT BE OF SAME STRENGTH
// SINCE THROW, V_SKILL AND V_TRIGGER TAKE PRIORITY

// HP FIREBALL OR LK TATSU
RunCombo(FIREBALL, LK_HP);
}
else if (bool[DIR_DOWN_BACK])
{
// LP FIREBALL OR HK TATSU
RunCombo(FIREBALL, LP_HK);
}
else if (bool[DIR_DOWN])
{
// FIREBALL EX
RunCombo(FIREBALL, LP_MP);
}
else if (bool[DIR_NEUTRAL])
{
// I USE THIS MOSTLY AFTER JUMP INS
RunCombo(SMP_CMK, 0);
}
else if (bool[DIR_UP])
{
}
}
}
}


// I USE R3 MOSTLY FOR DRAGON PUNCH
function R3Press()
{
if (event_press(BTN_R3))
{
if (bool[DELAY_EN_JUMP])
{
}
// THROW FIREBALL IF MK WAS PRESSED RIGHT BEFORE SINCE DRAGON PUNCH SOMETIMES WHIFFS
else if ((bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY]) || (bool[DELAY_EN_COMBO] && comboIndex == SMP_CMK))
{
RunCombo(FIREBALL, LK_HP);
}
// USE HP DRAGON PUNCH AS COMBO ENDERS
else if (bool[DELAY_EN_LP] || bool[DELAY_EN_LK] || bool[DELAY_EN_MP] || bool[DELAY_EN_HP])
{
RunCombo(DRAGON_PUNCH, HP);
}
else
{
// I USE R3 FOR MP DRAGON PUNCH SINCE IT IS THE BEST ANTI AIR VERSION
// YOU CAN USE EX DRAGON PUNCH BUT I LIKE TO SAVE THE METER
if (bool[DIR_BACK])
{
RunCombo(DRAGON_PUNCH, MP);
}
else if (bool[DIR_DOWN_BACK])
{
// THIS WILL DRAGON PUNCH NO MATTER WHICH WAY YOU ARE PRESSING (FORWARD OR BACK) AS LONG AS
// IT IS NOT IN A COMBO
// IT TAKES 2 MORE DIRECTIONAL INPUTS SO IT WILL TAKE 2 MORE FRAMES
RunCombo(DRAGON_PUNCH_CROSSUP, MP);
}
else if (bool[DIR_DOWN])
{
RunCombo(DRAGON_PUNCH, MP);
}
else if (bool[DIR_NEUTRAL])
{
// I USE THIS MOSTLY AFTER JUMP INS
RunCombo(SMP_CHP, 0);
}
else if (bool[DIR_UP])
{
}
}
}
}


// I USE L1 MOSTLY FOR THROWS
function L1Press()
{
if (event_press(BTN_L1))
{
// PERFORMS AIR TATSU, YOU HAVE TO BE JUMPING FORWARD AND HAVE PRESSED BACK DURING THE JUMP
if (bool[DELAY_EN_JUMP])
{
RunCombo(TATSU, LK);
}
else
{
// COMPLETES THE TARGET COMBO IF PRESSED RIGHT AFTER STANDING MP
if (bool[DELAY_EN_MP] && bool[DIR_BACK])
{
RunCombo(TARGET_COMBO_1, 0);
}
// TATSU LK ENDER IF CROUCHING MK AND CROUCHING MP OR CROUNCHING HP PRESSED RIGHT BEFORE.
else if ((bool[DELAY_EN_LK] && bool[DIR_BACK]) ||(bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY]) || (bool[DELAY_EN_HP] && bool[DIR_DOWN_ANY]) || (bool[DELAY_EN_COMBO] && comboIndex == SMP_CMK))
{
RunCombo(TATSU, LK);
}
// THROW OR V_REVERSAL OS - THIS WILL PERFORM A THROW IF NOT BLOCKING OR V_REVERSAL IF BLOCKING
else if (bool[DIR_BACK])
{
RunCombo(V_REVERSAL_THROW_OS, 0);
}
else if (bool[DIR_DOWN_BACK])
{
RunCombo(V_REVERSAL_THROW_OS, 0);
}
else if (bool[DIR_DOWN])
{
RunCombo(THROW, 0);
}
else if (bool[DIR_NEUTRAL])
{
RunCombo(THROW, 0);
}
else if (bool[DIR_UP])
{
}
}
}
}


// I USE L2 FOR PARRY, SUPER, AND V-TRIGGER
function L2Press()
{
if (event_press(BTN_L2))
{
// EX TATSU IF JUMPING
if (bool[DELAY_EN_JUMP])
{
RunCombo(TATSU, LK_MK);
}
// V-TRIGGER IF NUETRAL PRESS
else if (bool[DIR_NEUTRAL])
{
RunCombo(V_TRIGGER, 0);
}
// COMBO INTO SUPER IF FIREBALL, DRAGON PUNCH OR NORMAL PRESSED RIGHT BEFORE
else if (bool[DELAY_EN_MP] || bool[DELAY_EN_HP] || bool[DELAY_EN_R3] || bool[DELAY_EN_L3] || (bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY]) || (bool[DELAY_EN_COMBO] && (comboIndex == FIREBALL || comboIndex == DRAGON_PUNCH || comboIndex == SMP_CMK || comboIndex == SMP_CHP)))
{
RunCombo(SUPER, HP);
}
else
{
// PARRY IF HOLDING BACK OR DOWN
if (bool[DIR_BACK])
{
RunCombo(V_REVERSAL_SKILL_OS, 0);
}
else if (bool[DIR_DOWN_BACK])
{
RunCombo(V_REVERSAL_SKILL_OS, 0);
}
else if (bool[DIR_DOWN])
{
RunCombo(V_REVERSAL_SKILL_OS, 0);
}
else if (bool[DIR_UP])
{
}
}
}
}


// LP COMBOS
function LPPress()
{
if (event_press(BTN_LP))
{
// LP -> LP = LP -> HP DRAGON PUNCH COMBO
if (bool[DELAY_EN_LP])
{
RunCombo(DRAGON_PUNCH, HP);
}
// MP -> LP = MP -> HP FIREBALL COMBO
else if (bool[DELAY_EN_MP])
{
RunCombo(FIREBALL, HP);
}
}
}


function MPPress()
{
if (event_press(BTN_MP))
{
// MP -> HP = TARGET COMBO 1
if (bool[DELAY_EN_HP])
{
RunCombo(TARGET_COMBO_1, 0);
}
}
}


function HPPress()
{
if (event_press(BTN_HP))
{
// HP -> MP = TARGET COMBO 2
if (bool[DELAY_EN_MP] && bool[DIR_BACK])
{
RunCombo(TARGET_COMBO_2, 0);
}
}
}


function LKPress()
{
if (event_press(BTN_LK))
{
// LK -> LK = LK -> HP DRAGON PUNCH COMBO
if (bool[DELAY_EN_LK] && (bool[DIR_BACK] || bool[DIR_NEUTRAL]))
{
RunCombo(DRAGON_PUNCH, HP);
}
// CMK -> LK = CMK -> HP FIREBALL COMBO
else if (bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY])
{
RunCombo(FIREBALL, HP);
}
}
}


function MKPress()
{
if (event_press(BTN_MK))
{
// CMK -> CMK = CMK -> HP FIREBALL COMBO
if (bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY])
{
RunCombo(FIREBALL, HP);
}
// LK -> LK = LK -> LK TATSU COMBO
else if (bool[DELAY_EN_LK] && bool[DIR_BACK])
{
RunCombo(TATSU, LK);
}
}
}


function HKPress()
{
if (event_press(BTN_HK))
{
// CMK -> HK = CMK -> EX TATSU COMBO
if (bool[DELAY_EN_MK] && bool[DIR_DOWN_ANY])
{
RunCombo(TATSU, LK_MK);
}
}
}


// RUN SUPER IF START PRESSED
function STARTPress()
{
if (event_press(PS3_START))
{
if (bool[DIR_BACK_ANY])
{
RunCombo(SUPER, HP);
}
}
}

swa2776
30th March 16, 01:12
Thanks for sharing

EvilRyu
30th March 16, 16:45
nice man could you post the other chars aswell?

mnguyen
31st March 16, 11:46
nice man could you post the other chars aswell?

Thanks! I posted a nash script in the SFV sub forum if you wan to take a look.