;==============================================================================================
;=======================================<COMMAND FILE>=========================================
;==============================================================================================

;====================<BUTTON REMAPPING>====================

[Remap]
x = x
y = y
z = z
a = a
b = b
c = c
s = s


;====================<DEFAULT VALUES>====================

[Defaults]
command.time = 15
command.buffer.time = 1



;====================<SINGLE BUTTON>====================

[Command]
name = "a"
command = a
time = 1

[Command]
name = "b"
command = b
time = 1

[Command]
name = "c"
command = c
time = 1

[Command]
name = "x"
command = x
time = 1

[Command]
name = "y"
command = y
time = 1

[Command]
name = "z"
command = z
time = 1

[Command]
name = "start"
command = s
time = 1

[Command]
name = "s"
command = s
time = 1

;==================<HOLD DIRECTION>==================

[Command]
name = "holdfwd"
command=/$F
time=1

[Command]
name = "holdback"
command = /$B
time = 1

[Command]
name = "holdup"
command = /$U
time=1

[Command]
name = "holddown"
command = /$D
time = 1


;====================<HOLD BUTTON>====================

[Command]
name = "holda"
command = /a
time = 1

[Command]
name = "holdb"
command = /b
time = 1

[Command]
name = "holdc"
command = /c
time = 1

[Command]
name = "holdx"
command = /x
time = 1

[Command]
name = "holdy"
command = /y
time = 1

[Command]
name = "holdz"
command = /z
time = 1

[Command]
name = "holdstart"
command = /s
time = 1



;====================<DIRECTION>====================

[Command]
name = "fwd"
command = F
time = 1

[Command]
name = "back"
command = B
time = 1

[Command]
name = "up"
command = U
time = 1

[Command]
name = "down"
command = D
time = 1

[Command]
name = "dfwd"
command = DF
time = 1

[Command]
name = "dback"
command = DB
time = 1

[Command]
name = "ufwd"
command = UF
time = 1

[Command]
name = "uback"
command = UB
time = 1



;====================<RELEASE DIR>====================

[Command]
name = "rlsfwd"
command = ~$F
time = 1

[Command]
name = "rlsback"
command = ~$B
time = 1

[Command]
name = "rlsup"
command = ~$U
time = 1

[Command]
name = "rlsdown"
command = ~$D
time = 1



;====================<RELEASE BUTTON>====================

[Command]
name = "rlsx"
command = ~x
time = 1

[Command]
name = "rlsy"
command = ~y
time = 1

[Command]
name = "rlsz"
command = ~z
time = 1

[Command]
name = "rlsa"
command = ~a
time = 1

[Command]
name = "rlsb"
command = ~b
time = 1

[Command]
name = "rlsc"
command = ~c
time = 1



;====================<OTHER>====================

[Command]
name = "highjump"
command = $D, $U
time = 15



;====================<DOUBLE TAP>====================

[Command]
name = "FF"
command = F, F
time = 10

[Command]
name = "BB"
command = B, B
time = 10



;====================<2/3 BUTTON COMBINATION>====================

[Command]
name = "recovery"
command = x
time = 1

[Command]
name = "recovery"
command = y
time = 1

[Command]
name = "recovery"
command = z
time = 1

[Command]
name = "recovery"
command = a
time = 1

[Command]
name = "recovery"
command = b
time = 1

[Command]
name = "recovery"
command = c
time = 1

[Command]
name = "pp"
command = x+y
time = 1

[Command]
name = "pp"
command = x+z
time = 1

[Command]
name = "pp"
command = y+z
time = 1


[Command]
name = "kk"
command = a+b
time = 1

[Command]
name = "kk"
command = a+c
time = 1

[Command]
name = "kk"
command = b+c
time = 1


[Command]
name = "a+x"
command = a+x
time=1

[Command]
name = "b+y"
command = b+y
time = 1

[Command]
name = "c+z"
command = c+z
time = 1


[Command]
name = "a+b"
command = a+b
time = 1

[Command]
name = "a+c"
command = a+c
time = 1

[Command]
name = "b+c"
command = b+c
time = 1



;==============================================================================================
;========================================<-1 STATES>===========================================
;==============================================================================================
[StateDef -1]

;==============================================================================================
;==============================================================================================
;================================<EXPLODsive Buffering System>=================================
;====================================<by JustMorphPointman>====================================
;==============================================================================================
;==============================================================================================

;==============================================================================================
;INTRODUCTION; INSTALLATION INSTRUCTIONS, AND HOW TO USE THIS SYSTEM
;==============================================================================================
;The following block of code is an explod-based buffering system, designed to overcome several
;different errors and bugs related to MUGEN's default method of processing commands, as well as
;offering creators more control over how the commands of their character should work. It is designed
;to be easy to use, understand, and install.

;MUGEN's default command system has many limitations: the reverse command bug [actually save this shit for the thread]

;The system is completely customizable, and can be modified to suit the preference of the creator.
;However, it can also be installed as is; requiring no modifications you other than switching out
;the triggers for the various ChangeState controllers in State -1. In this section, we will explain
;how to change those triggers; a more thorough explanation of how the system works and how to modify
;it and add more commands can be found below this introductory section.

;To properlly "install" this system, you have to copy and paste this block of code to the start of your
;-1 State, which is usually located in the character's .cmd file. It's vital that this block of code
;is placed at the very top of State -1!!!

;In addition, you need to add the following commands to your .cmd file:

;[Command]
;name = "dfwd"
;command = DF
;time = 1

;[Command]
;name = "dback"
;command = DB
;time = 1

;[Command]
;name = "ufwd"
;command = UF
;time = 1

;[Command]
;name = "uback"
;command = UB
;time = 1

;You must also create a helper, which this system will use to process the player's input. Just copy and paste
;the following into your character's State -2:

;[State -2, EXPLODsive Buffering Helper]
;type = Helper
;trigger1 = !NumHelper(90000005)
;helpertype = Normal
;stateNo = 90000005
;ID = 90000005
;name = "EXPLODsive Buffering helper"
;posType = P1
;facing = ifElse(Facing = 1, 1, -1)
;keyCtrl = 1
;ignoreHitPause = 1

;The helper state must also be added. Make sure not to place it inside another state!

;========================<EXPLODSIVE BUFFERING HELPER>=============================
;[StateDef 90000005]
;type = A
;physics = N
;moveType = I
;anim = 1
;velSet = 0,0
;ctrl = 0

;[State 90000005, DisplayToClipboard]
;type = DisplayToClipboard
;trigger1 = 1
;text = "by JustMorphPointman"
;ignoreHitPause = 1

;Now you just need to switch out the triggers in your character's ChangeStates in -1, and you'll
;be good to go! The only other thing you need to do (other than switching out the triggers) to make
;this system work is to set the "command.buffer.time" to 1. This will ensure the buffer system can
;properly read all of the player's inputs! You must also make sure that int variables 47, 48, 49, and
;50 are free, if you are including the charge moves. ;These variables are used by the system to store
;charge move buffer times and other information needed to have charge move behave properly. If you are
;not using the charge moves at all, you can safely make use of those four variables, as long as you
;delete the lines of code in the buffer system that deal with charge moves (for more information about
;deleting uneeded moves, see the advanced section below this introductory section.
;==============================================================================================
;The basic concept of this system is that we generate a series of explods based on the input of the
;player; for example, if the player hits "down", an explod with a unique ID, representing the "down"
;direction will be created, with a certain RemoveTime. If the player then hits "down-forward" before
;the "down" explod has been removed, a "down-forward" explod would be created. This process would repeat
;if the player then inputs "forward". If MUGEN checks to see if that "forward" explod exists, then
;it will know that a quarter circle forward motion has been successfully completed. This is what we
;use as triggers: instead of checking to see if command = "QCF", we check NumExplod(QCF). We use explods
;instead of variables in this system to keep the character's own variables (mostly) free; and we have to
;avoid using a helper

;However, unlike MUGEN, we won't be using "forward" and "back"; the explod system is based entirely
;on absolute, not relative, directional inputs. That means left and right, instead of forward or back.
;This is to avoid problems in situations where the characters are switching sides, and their commands
;reverse. By defining everything in terms of left and right, we can ensure that a player can always perform
;the move they want to perform, and not have engine limitations get in the way. So instead of checking for a
;quarter circle forward motion (D, DF, F), we check for both a quarter circle right/left motion
;(D, DR, R and D, DL, L). For a quarter circle forward motion, we would check if the quarter circle right
;explod exists when the character is facing to the right, and check for the quarter circle left explod
;if the character was facing left. This is required even if the character you are making only has a QCF, or
;only a QCB, or what have you!

;Here is a very simplified version of a Hadoken ChangeState, using MUGEN's old method:

;[State -1, Hadoken (light strength)]
;type = ChangeState
;value = 1000
;trigger1 = command = "QCF+x"
;trigger1 = ctrl && StateType = S

;We can very easily switch this out by looking up the explods that represent quarter circle right, left,
;and "x" button (check the handy chart at the bottom of this section), and adding the appropriate triggers.
;In this case, we find quarter-circle right corresponds to "90010006", quarter-circle left is "90010104",
;and "x" is 90000200. So, we modify the ChangeState to look like this:

;[State -1, Hadoken]
;type = ChangeState
;value = 1000
;trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010104))
;trigger1 = NumExplod(90000200)
;trigger1 = ctrl && StateType = S

;It might look more imposing, but it's pretty simple! We check to make sure that if the player is facing
;right, then we check if an explod with ID 90010006 exists (and if the player is on the left, then we check
;for an explod ID of 90010104); these explods represent the quarter circle motion. If one of those exist
;(and the character is facing the appropriate direction), and an explod that represents the "x" button
;also exists, then that means the player has sucessfully completed the quarter circle motion and has
;pressed "x", which means it's time to fire off a Hadoken!
;==============================================================================================
;Most moves, special, super, or otherwise, can be pretty easily updated to use this system, just by
;copying and pasting the appropriate triggers. For moves that require directional input(s), this statement
;(with the appropriate explod ID replacing the text in all caps) should be used (except in rarer cases covered below):

;triggerAll = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_RIGHT)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_LEFT))

;The above statement is how the vast majority of fighting game moves on the ground work. But moves performed in air
;are where things get a little trickier. In most Capcom games, when you jump over an opponent, your commands don't flip over
;until you land. So if you're playing as Akuma, and you start out on the left side of the screen before jumping over the
;opponent, your air fireball move is still performed by rotating the joystick from down to the right, a quarter-circle
;right motion. However, in most SNK games (and Street Fighter III and Capcom vs. SNK!), things work differently. In those games
;as soon as you jump over an opponent, your commands flip. So to use the same Akuma example again, if Akuma starts on the left
;and jumps over the opponent in one of these games, the player will have to move the joystick from down to *left* to get his air
;fireball move, because their commands have already been switched, as soon as they switched sides with their opponent. The SNK
;way of handling aerial moves doesn't require any changes to the above ifElse statements. With the Capcom games that don't
;flip directions in the air, however, a different set of triggers are required:

;triggerAll = ifElse(Facing = 1, NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_RIGHT), NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_LEFT))

;And in the very unlikely event you have a move that can be used in both the air and the ground, and that uses the same State for
;both versions, AND you want to use the Capcom's method of handling air commands, use this set of triggers:

;triggerAll = (ifElse(P2DisT x < -12 && StateType != A, Facing = -1, Facing = 1) && NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_RIGHT)) || (ifElse(P2DisT x < -12  && StateType != A, Facing = 1, Facing = -1) && NumExplod(DIRECTIONAL_COMMAND_WHEN_FACING_LEFT))
;==============================================================================================
;Buttons can be handled a lot more easily; no need for complicated ifElse statements or the like. Just check
;to see whether the appropriate button has been input (or released) using NumExplod. You can check for multiple
;buttons by chaining together NumExplod statements with MUGEN's logical operators.
;==============================================================================================
;BIG LIST OF EXPLOD ID #'s:

;BASIC DIRECTIONAL INPUTS (these are active whenever the specified direction is currently being input, and
;disappear as soon as they are released. They are used by the system to detect directional release, but can
;also be used by you to detect when a specific direction is being input or held down)
;Down:										90000002
;Down-right:									90000003
;Right:										90000006
;Up-right:									90000009
;Up:										90000008
;Up-left:										90000007
;Left:										90000004
;Down-left:									90000001


;BUTTON PRESS
;x:										90000200
;y:										90000210
;z:										90000220
;a:										90000230
;b:										90000240
;c:										90000250
;start:										90000195


;BUTTON RELEASE
;x:										90000205
;y:										90000215
;z:										90000225
;a:										90000235
;b:										90000245
;c:										90000255
;start:										90000196


;SYSTEM MOTIONS
;Down (3 ticks):					(D with a 3 tick buffer)		90000012
;Down-right (3 ticks):				(DR with a 3 tick buffer)		90000013
;Right (3 ticks):					(R with a 3 tick buffer)		90000016
;Up-right (3 ticks):				(UR with a 3 tick buffer)		90000019
;Up (3 ticks):					(U with a 3 tick buffer)		90000018
;Up-left (3 ticks):					(UL with a 3 tick buffer)		90000017
;Left (3 ticks):					(L with a 3 tick buffer)		90000014
;Down-left (3 ticks):				(DL with a 3 tick buffer)		90000011

;Down (3 ticks + HitPause):				(D w/ 3 tick buffer + HitPause)	90000212
;Down-right (3 ticks + HitPause):			(DR w/ 3 tick buffer + HitPause)	90000213
;Right (3 ticks + HitPause):				(R w/ 3 tick buffer + HitPause)	90000216
;Up-right (3 ticks + HitPause):			(UR w/ 3 tick buffer + HitPause)	90000219
;Up (3 ticks + HitPause):				(U w/ 3 tick buffer + HitPause)	90000218
;Up-left (3 ticks + HitPause):			(UL w/ 3 tick buffer + HitPause)	90000217
;Left (3 ticks + HitPause):				(L w/ 3 tick buffer + HitPause)	90000214
;Down-left (3 ticks + HitPause):			(DL w/ 3 tick buffer + HitPause)	90000211

;R, R:						(F, F)				90001016
;L, L:						(B, B)				90001064
;D, U:						(D, U)				90000408
;U, U:						(U, U)				90000518
;D, D:						(D, D)				90000562
;R, DR, D						(F, DF, D)			90007502
;L, DL, D						(B, DB, D)			90007552


;SPECIAL MOTIONS
;D, DR, R:					(QCF)				90010006
;D, DL, L:					(QCB)				90010104
;R, D, DR:					(F, D, DF)			90010203
;L, D, DL:					(B, D, DB)			90010301
;L, DL, D, DR, R:					(HCF)				90010406
;R, DR, D, DL, L:					(HCB)				90010504
;(charge) L, R:					([charge] B, F)			90010606
;(charge) R, L:					([charge] F, B)			90010704
;(charge) D, U:					([charge] D, U)			90010808
;L, D, R, U:					(360)				90011008
;L, U, R, D:					(360)				90011102
;D, R, U, L:					(360)				90011204
;D, L, U, R:					(360)				90011306
;R, D, L, U:					(360)				90011408
;R, U, L, D:					(360)				90011502
;U, R, D, L:					(360)				90011604
;U, L, D, R:					(360)				90011706
;R, D, L, R:					(HCB, F)				90012016
;L, D, R, L:					(HCF, B)				90012114
;R, L, R:						(F, B, F)				90012216
;L, R, L:						(B, F, B)				90012314
;D, DR, R, UR:					(QCF, UF)				90012409
;D, DL, L, UL:					(QCB, UB)				90012507
;D, D:						([special] D, D)			90012602


;SUPER MOTIONS
;D, DR, R, D, DR, R:				(QCFx2)				90030016
;D, DL, L, D, DL, L:				(QCBx2)				90030114
;L, DL, D, DR, R, L, DL, D, DR, R:			(HCFx2)				90030416
;R, DR, D, DL, L, R, DR, D, DL, L:			(HCBx2)				90030514
;(charge) L, R, L, R:				([charge] B, F, B, F)		90030616
;(charge) R, L, R, L:				([charge] F, B, F, B)		90030714
;(charge) DL, DR, DL, UR:				([charge] DB, DF, DB, UF)		90030809
;(charge) DR, DL, DR, UL:				([charge] DF, DB, DF, UB)		90030907
;L, D, R, U, L, D, R, U:				(720)				90031018
;L, U, R, D, L, U, R, D:				(720)				90031112
;D, R, U, L, D, R, U, L:				(720)				90031214
;D, L, U, R, D, L, U, R:				(720)				90031316
;R, D, L, U, R, D, L, U:				(720)				90031418
;R, U, L, D, R, U, L, D:				(720)				90031512
;U, R, D, L, U, R, D, L:				(720)				90031614
;U, L, D, R, U, L, D, R:				(720)				90031716
;R, L, D, R:					(F, HCF)				90032016
;L, R, D, L:					(B, HCB)				90032114
;D, DR, R, D, L:					(QCF, HCB)			90032204
;D, DL, L, D, R:					(QCB, HCF)			90032306
;D, DR, R, DR, L:					(QCF, DF, B)			90032404
;D, DL, L, DL, R:					(QCB, DB, F)			90032506
;D, D, D:						(D, D, D)				90032602


;SUPER MOTIONS (button inputs)
;x, x, F, a, z:					(Shun Goku Satsu)			94000220



;==============================================================================================
;ADVANCED SECTION; IN-DEPTH EXPLANATION ABOUT HOW THE SYSTEM WORKS; HOW TO CUSTOMIZE THE SYSTEM;
;HOW TO DELETE UNNEEDED COMMANDS; HOW TO ADD NEW MOVES
;==============================================================================================
;3. How to customize the code block (adjusting remove time [and how charge move command times differ], clearing out commands you don't need). Need to explain "linked commands";
;   commands like QCFx2 that are reliant on another set of commands, the QCF command can't be removed (even if they don't use it) if they want to use QCFx2!
;   List all the linked commands contained in the code block (QCRx2; QCLx2; HCRx2; HCLx2; 720s; QCL, HCR; QCR, HCL)
;==============================================================================================
;this is the start of the advanced section, where pretty much every aspect of the system is explained in detail. the first "block" is the directional detector explods.
;ME: REWRITE BELOW SECTION
;ALSO ME: add notes about how to emulate KOF98. allow the 8 below explod sctrls to create multiple explods, which will allow the player to determine how many ticks
;a direction / button has been input.



;This block of explods flip on when a certain direction is input; they are used as "detectors" to tell the character when that direction has been released.
;These explods are used instead of MUGEN's own inbuilt release direction system (i.e., "rlsdown", "rlsfwd", etc.) because of a serious bug involving the latter;
;see this thread for details: http://mugenguild.com/forum/msg.2324083

;These explods will exist for as long as the direction they represent is held; as soon as that direction is released, a corresponding removeexplod (near the very
;bottom of this file) will remove it.

;For most fighting game special/super moves, the very first directional command is a "release" directional input. For most characters, they'll only need release detectors
;for the four cardinal directions (Up, Down, Left, Right), but you should double check your movelist to see whether you might have a command that starts with a diagonal.
;You'll need the corresponding detector to get that move working!

;==============================================================================================
;===================================<DIRECTIONAL COMMANDS>=====================================
;==============================================================================================
[State -1, Release Down Detector]
type = Explod
;make sure explod doesn't already exist
triggerAll = !NumExplod(90000002)
;check to make sure Helper exists, and that the entity running this code isn't the helper
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
;explod will be created if down is input
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
;no other directions may be input, otherwise it wouldn't be a down input!
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000002
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Down-Right Detector]
type = Explod
triggerAll = !NumExplod(90000003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger1 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger1 = Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000003
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Right Detector]
type = Explod
triggerAll = !NumExplod(90000006)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000006
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Up-Right Detector]
type = Explod
triggerAll = !NumExplod(90000009)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger1 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger1 = Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000009
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Up Detector]
type = Explod
triggerAll = !NumExplod(90000008)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000008
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Up-Left Detector]
type = Explod
triggerAll = !NumExplod(90000007)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger1 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000007
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Left Detector]
type = Explod
triggerAll = !NumExplod(90000004)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000004
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release Down-Left Detector]
type = Explod
triggerAll = !NumExplod(90000001)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger1 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000001
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1



;==============================================================================================
;==========================================<BUTTONS>===========================================
;==============================================================================================

[State -1, Press x]
type = Explod
;if there already exists a "press x" explod, and the player is in hitpausetime, then we don't need another!
trigger1 = !HitPauseTime || !NumExplod(90000200)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "x"
anim = 1
ID = 90000200
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press y]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000210)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "y"
anim = 1
ID = 90000210
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press z]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000220)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "z"
anim = 1
ID = 90000220
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press a]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000230)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "a"
anim = 1
ID = 90000230
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press b]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000240)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "b"
anim = 1
ID = 90000240
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press c]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000250)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "c"
anim = 1
ID = 90000250
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, Press start]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000195)
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "start"
anim = 1
ID = 90000195
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;==============================================================================================
;
;==============================================================================================
[State -1, Release x Detector]
type = Explod
triggerAll = !NumExplod(90000201)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "x" || Helper(90000005), command = "holdx"
anim = 1
ID = 90000201
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release y Detector]
type = Explod
triggerAll = !NumExplod(90000211)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "y" || Helper(90000005), command = "holdy"
anim = 1
ID = 90000211
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release z Detector]
type = Explod
triggerAll = !NumExplod(90000221)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "z" || Helper(90000005), command = "holdz"
anim = 1
ID = 90000221
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release a Detector]
type = Explod
triggerAll = !NumExplod(90000231)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "a" || Helper(90000005), command = "holda"
anim = 1
ID = 90000231
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release b Detector]
type = Explod
triggerAll = !NumExplod(90000241)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "b" || Helper(90000005), command = "holdb"
anim = 1
ID = 90000241
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release c Detector]
type = Explod
triggerAll = !NumExplod(90000251)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "c" || Helper(90000005), command = "holdc"
anim = 1
ID = 90000251
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

[State -1, Release start Detector]
type = Explod
triggerAll = !NumExplod(90000194)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "start"
anim = 1
ID = 90000194
removeTime = -1
pauseMoveTime = -1
superMoveTime = -1
ignoreHitPause = 1

;==============================================================================================
;Relase button inputs don't persist through hitpause!
;==============================================================================================

[State -1, Release x]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000205)
triggerAll = NumExplod(90000201)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "x" && Helper(90000005), command != "holdx"
anim = 1
ID = 90000205
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release y]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000215)
triggerAll = NumExplod(90000211)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "y" && Helper(90000005), command != "holdy"
anim = 1
ID = 90000215
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release z]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000225)
triggerAll = NumExplod(90000221)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "z" && Helper(90000005), command != "holdz"
anim = 1
ID = 90000225
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release a]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000235)
triggerAll = NumExplod(90000231)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "a" && Helper(90000005), command != "holda"
anim = 1
ID = 90000235
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release b]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000245)
triggerAll = NumExplod(90000241)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "b" && Helper(90000005), command != "holdb"
anim = 1
ID = 90000245
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release c]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000255)
triggerAll = NumExplod(90000251)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "c" && Helper(90000005), command != "holdc"
anim = 1
ID = 90000255
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Release start]
type = Explod
trigger1 = !HitPauseTime || !NumExplod(90000196)
triggerAll = NumExplod(90000194)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "start" && Helper(90000005), command != "holdstart"
anim = 1
ID = 90000196
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1

[State -1, Throw Tech]
type = Explod
trigger1 = NumHelper(90000005) && !IsHelper
trigger1 = !AILevel
trigger1 = Helper(90000005), command = "x" && Helper(90000005), command = "a"
anim = 1
ID = 90000800
removeTime = 3 
pauseMoveTime = 3 
superMoveTime = 3 
ignoreHitPause = 1

;==============================================================================================
;=============================<DIRECTIONAL INPUTS (3 TICK BUFFER)>=============================
;==============================================================================================

;==============================================================================================
;These activate whenever the direction in question is input, and persist for three ticks. Useful
;if you need to use only a single directional input, but also want it to last longer than one tick.
;==============================================================================================

;======================================<DOWN (3 TICKS)>========================================
[State -1, Down (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "up" && Helper(90000005), command != "back" && Helper(90000005), command != "down" && Helper(90000005), command != "fwd"
anim = 1
ID = 90000012
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;===================================<DOWN-RIGHT (3 TICKS)>=====================================
[State -1, Down-Right (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "ufwd" && Helper(90000005), command != "back" && Helper(90000005), command != "down"
anim = 1
ID = 90000013
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;======================================<RIGHT (3 TICKS)>=======================================
[State -1, Right (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90000016
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;=====================================<UP-RIGHT (3 TICKS)>=====================================
[State -1, Up-Right (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "ufwd" && Helper(90000005), command != "back" && Helper(90000005), command != "down"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90000019
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;========================================<UP (3 TICKS)>========================================
[State -1, Up (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "up" && Helper(90000005), command != "fwd" && Helper(90000005), command != "down" && Helper(90000005), command != "back"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back"
anim = 1
ID = 90000018
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;=====================================<UP-LEFT (3 TICKS)>======================================
[State -1, Up-Left (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "uback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "down"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90000017
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;=======================================<LEFT 3 TICKS>=========================================
[State -1, Left (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90000014
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;====================================<DOWN-LEFT 3 TICKS>=======================================
[State -1, Down-Left (3 ticks)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = Helper(90000005), command = "uback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "down"
anim = 1
ID = 90000011
removeTime = 3
pauseMoveTime = 3
superMoveTime = 3
ignoreHitPause = 1



;==============================================================================================
;=====================<DIRECTIONAL INPUTS (3 TICK BUFFER + HITPAUSE TIME)>=====================
;==============================================================================================

;==============================================================================================
;These are almost identical to the explods directly above this, except these will persist through
;a HitPause, and will only activate if the direction in question is being either held or input on
;the same tick that any button is input. These can be used to replicate the command behavior of Capcom
;games for crouching and command normal moves. For more information, please see [INSERT LINK].
;==============================================================================================

;==============================<DOWN (3 TICKS + HITPAUSE TIME)>================================
[State -1, Down (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "down" || Helper(90000005), command = "holddown") && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holdup" && Helper(90000005), command != "holdfwd"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "up" || Helper(90000005), command = "holdup") && Helper(90000005), command != "back" && Helper(90000005), command != "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holddown" && Helper(90000005), command != "holdfwd"
anim = 1
ID = 90000022
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1




;===========================<DOWN-RIGHT (3 TICKS + HITPAUSE TIME)>=============================
[State -1, Down-Right (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "dfwd" || (Helper(90000005), command = "holddown" && Helper(90000005), command = "holdfwd")) && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holdup"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "ufwd" || (Helper(90000005), command = "holdup" && Helper(90000005), command = "holdfwd")) && Helper(90000005), command != "back" && Helper(90000005), command != "down" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000023
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;==============================<RIGHT (3 TICKS + HITPAUSE TIME)>===============================
[State -1, Right (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = (Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd") && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holdup" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000026
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=============================<UP-RIGHT (3 TICKS + HITPAUSE TIME)>=============================
[State -1, Up-Right (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "ufwd" || (Helper(90000005), command = "holdup" && Helper(90000005), command = "holdfwd")) && Helper(90000005), command != "back" && Helper(90000005), command != "down" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holddown"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "dfwd" || (Helper(90000005), command = "holddown" && Helper(90000005), command = "holdfwd")) && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "holdback" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000029
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;================================<UP (3 TICKS + HITPAUSE TIME)>================================
[State -1, Up (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "up" || Helper(90000005), command = "holdup") && Helper(90000005), command != "fwd" && Helper(90000005), command != "down" && Helper(90000005), command != "back" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holddown" && Helper(90000005), command != "holdback"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "down" || Helper(90000005), command = "holddown") && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holdup" && Helper(90000005), command != "holdback"
anim = 1
ID = 90000028
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=============================<UP-LEFT (3 TICKS + HITPAUSE TIME)>==============================
[State -1, Up-Left (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "uback" || (Helper(90000005), command = "holdup" && Helper(90000005), command = "holdback")) && Helper(90000005), command != "fwd" && Helper(90000005), command != "down" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holddown"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "dback" || (Helper(90000005), command = "holddown" && Helper(90000005), command = "holdback")) && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000027
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;===============================<LEFT 3 TICKS + HITPAUSE TIME>=================================
[State -1, Left (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = (Helper(90000005), command = "back" || Helper(90000005), command = "holdback") && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holdup" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000024
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;============================<DOWN-LEFT 3 TICKS + HITPAUSE TIME>===============================
[State -1, Down-Left (3 ticks + HitPauseTime)]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper && !AILevel
triggerAll = Helper(90000005), command = "x" || Helper(90000005), command = "y" || Helper(90000005), command = "z" || Helper(90000005), command = "a"  || Helper(90000005), command = "b" || Helper(90000005), command = "c" || Helper(90000005), command = "start"
trigger1 = !enemy, NumExplod(92828282) && !enemy, NumExplod(92468246)
trigger1 = (Helper(90000005), command = "dback" || (Helper(90000005), command = "holddown" && Helper(90000005), command = "holdback")) && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holdup"
trigger2 = enemy, NumExplod(92828282) || enemy, NumExplod(92468246)
trigger2 = (Helper(90000005), command = "uback" || (Helper(90000005), command = "holdup" && Helper(90000005), command = "holdback")) && Helper(90000005), command != "fwd" && Helper(90000005), command != "down" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "holddown"
anim = 1
ID = 90000021
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;==============================================================================================
;================================<FORWARD, FORWARD/BACK, BACK>=================================
;==============================================================================================

;==============================================================================================
;this is the first commmand block. this is where the vast majority of comments will be; need to explain why commands must be mirrored, and explain all the various compenents of the
;explods (why the timer [and what it means and how long it needs to be], how the first input must be formatted, etc.)

;also mention something about how the first input of a F,F/B,B command in SNK games is a release command


;OLD, REWRITE THIS SHIT
;All commands (unless they are solely performed with Up or Down) must be defined using two versions: one assuming the character is facing the right, and one for the left.
;This is to correct an oversight in MUGEN's command parser. For example, a traditional quarter-circle forward motion will be defined here as two commands: a Down, Down-Right, Right
;motion; and a Down, Down-Left, Left motion. This will allow the user to be able to correctly buffer commands while switching sides.
;==============================================================================================

;=======================================<UP, UP>=========================================
[State -1, U, U: 1st Up]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "ufwd" || Helper(90000005), command = "uback"
trigger1 = Helper(90000005), command != "down"
anim = 1
ID = 90000508
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, U, U: Neutral]
type = Explod
triggerAll = NumExplod(90000008) && NumExplod(90000508)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000505
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, Remove U, U: Neutral]
type = RemoveExplod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = NumExplod(90000002) || NumExplod(90000003) || NumExplod(90000004) || NumExplod(90000001) || NumExplod(90000006)
ID = 90000505
ignoreHitPause = 1

[State -1, U, U: 2nd Up]
type = Explod
triggerAll = NumExplod(90000505) && NumExplod(90000508)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "ufwd" || Helper(90000005), command = "uback"
trigger1 = Helper(90000005), command != "down"
anim = 1
ID = 90000518
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;=======================================<Down, Down>=========================================
[State -1, D, D: 2nd Down]
type = Explod
triggerAll = NumExplod(90000555) && NumExplod(90000552)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "dfwd" || Helper(90000005), command = "dback"
trigger1 = Helper(90000005), command != "up"
anim = 1
ID = 90012602
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

[State -1, D, D: 1st Down]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "dfwd" || Helper(90000005), command = "dback"
trigger1 = Helper(90000005), command != "up"
anim = 1
ID = 90000552
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, D: Neutral]
type = Explod
triggerAll = NumExplod(90000002) && NumExplod(90000552)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90000555
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, Remove D, D: Neutral]
type = RemoveExplod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = NumExplod(90000008) || NumExplod(90000009) || NumExplod(90000004) || NumExplod(90000007) || NumExplod(90000006)
ID = 90000555
ignoreHitPause = 1

[State -1, D, D: 2nd Down]
type = Explod
triggerAll = NumExplod(90000555) && NumExplod(90000552)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "dfwd" || Helper(90000005), command = "dback"
trigger1 = Helper(90000005), command != "up"
anim = 1
ID = 90000562
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;=======================================<DOWN, UP>=========================================
[State -1, D, U: Down]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "dfwd" || Helper(90000005), command = "dback"
trigger1 = Helper(90000005), command != "up"
anim = 1
ID = 90000402
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, U: Up]
type = Explod
triggerAll = NumExplod(90000402)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "ufwd" || Helper(90000005), command = "uback"
trigger1 = Helper(90000005), command != "down"
anim = 1
ID = 90000408
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;=======================================<RIGHT, RIGHT>=========================================
[State -1, R, R: 1st Right]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90001006
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, R, R: Neutral]
type = Explod
triggerAll = NumExplod(90000006) && NumExplod(90001006)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "back" && Helper(90000005), command != "holdback" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90001005
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, Remove R, R: Neutral]
type = RemoveExplod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = NumExplod(90000002) || NumExplod(90000003) || NumExplod(90000009) || NumExplod(90000008) || NumExplod(90000007) || NumExplod(90000004) || NumExplod(90000001)
trigger2 = !NumExplod(90001006)
ID = 90001005
ignoreHitPause = 1

[State -1, R, R: 2nd Right]
type = Explod
triggerAll = NumExplod(90001005) && NumExplod(90001006)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90001016
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=======================================<LEFT, LEFT>=========================================
[State -1, L, L: 1st Left]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90001054
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, L, L: Neutral]
type = Explod
triggerAll = NumExplod(90000004) && NumExplod(90001054)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "back" && Helper(90000005), command != "holdback"
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown" && Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd" && Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
anim = 1
ID = 90001055
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, Remove L, L: Neutral]
type = RemoveExplod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = NumExplod(90000002) || NumExplod(90000003) || NumExplod(90000006) || NumExplod(90000009) || NumExplod(90000008) || NumExplod(90000007) || NumExplod(90000001)
trigger2 = !NumExplod(90001054)
ID = 90001055
ignoreHitPause = 1

[State -1, L, L: 2nd Left]
type = Explod
triggerAll = NumExplod(90001055) && NumExplod(90001054)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90001064
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;==============================================================================================
;===================================<DOWN, UP (SUPER JUMP)>====================================
;==============================================================================================

;==============================================================================================
;Super jump commands can be done with any down directional input, followed by any up directional.
;==============================================================================================

;=======================================<RIGHT, RIGHT>=========================================
[State -1, D, U: Down]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "down" || Helper(90000005), command = "dfwd" || Helper(90000005), command = "dback"
trigger1 = Helper(90000005), command != "up"
anim = 1
ID = 90000402
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, U: Up]
type = Explod
triggerAll = NumExplod(90000402)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command = "up" || Helper(90000005), command = "ufwd" || Helper(90000005), command = "uback"
trigger1 = Helper(90000005), command != "down"
anim = 1
ID = 90000408
removeTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 3 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;==============================================================================================
;===============================<QUARTER CIRCLE FORWARD/BACK>==================================
;==============================================================================================

;==============================================================================================
;The vast majority of all commands in fighting games allow the first input of any command to be
;a release input, so that you're allowed to hold the direction that the command starts with for
;however long you want, then input the rest of the command, and still get the move. This is why
;in MUGEN, people typically write all their character's commands as starting with a release input;
;however, things are a bit more complicated outside of MUGEN (and thus, more complciated in this
;buffer too). In most games, the window of time a player has to input the next command in sequence
;after performing a release input is shorter than the window of time they have to input the next
;command after a press input. For example, in Street Fighter III, if you want to perform a quarter-
;circle forward motion, and you press (or hold) the "down" direction, you will have 10 ticks to
;input "down-forward" and continue the command. But if instead you were to hold the "down" direction
;down for a few seconds before releasing it, you will have only 5 ticks to input "down-forward" to
;continue entering the command.

;The way this is translated to the EXPLODsive Buffering system is this: we have two separate explods
;for the first input of every command that uses a release directional input. One explod is created
;whenever the first input is entered, and has a RemoveTime of 10 (which is the same amount of time
;that most other directional explods use in this system); one other explod is also created whenever
;the direction of the first input is released: this has a RemoveTime of 5, which is generally what
;commercial fighting games use.

;Do note that not every game gives players the same input windows for every single command: for
;example, in Street Fighter Alpha 3 (on normal speed), press directional inputs all have a 10 tick
;input window, but the input window for the release directional input in a quarter-circle motion is
;6, while the input window for the release directional input in a forward, down, down-forward motion
;is only 4! There's a whole bunch of variance here, sometimes in the same game, and so it's best to check
;the source game of the character you're making (if applicable) to try and get an idea of what RemoveTime
;will be best for each of your commands.
;==============================================================================================

;================================<DOWN, DOWN-RIGHT, RIGHT>=====================================

;Since this is the press directional input for the first input, it has a RemoveTime of 10
[State -1, D, DR, R: Press Down]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd"
anim = 1
ID = 90010002
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

;And since this is the release directional input for the first input, it has a RemoveTime of only 5!
[State -1, D, DR, R: Release Down]
type = Explod
triggerAll = NumExplod(90000002)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
anim = 1
ID = 90010052
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, D, DR, R: Down-Right]
type = Explod
;Remember, we have to check to see if either the "press down" or "release down" explods exist!
triggerAll = NumExplod(90010002) || NumExplod(90010052)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90010003
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R: Right]
type = Explod
triggerAll = NumExplod(90010003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90010006
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=================================<DOWN, DOWN-LEFT, LEFT>======================================
[State -1, D, DL, L: Press Down]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd"
anim = 1
ID = 90010102
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L: Release Down]
type = Explod
triggerAll = NumExplod(90000002)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
anim = 1
ID = 90010152
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, D, DL, L: Down-Left]
type = Explod
triggerAll = NumExplod(90010102) || NumExplod(90010152)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90010101
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L: Left]
type = Explod
triggerAll = NumExplod(90010101)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90010104
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;==============================================================================================
;===========================<DOUBLE QUARTER CIRCLE FORWARD/BACK>===============================
;==============================================================================================

;==============================================================================================
;This command is mostly identical to the QCF/QCB commands, but with different ID's; there are some
;important differences, however. Instead of repeating the entire first QCF/QCB command, we just
;(mostly) use the ones we already defined above!

;We do repeat the forward/backward input from the first QCF/QCB, though. This is because the final
;explod of the QCF/QCB command will persist through hitpause, which is not true for the QCFx2
;command: otherwise, you'd be able to input a QCF during a long hitpause, wait for the hitpause to
;end, and then input another QCF and still get a QCFx2 motion, and that's not how things are supposed
;to work!

;Also, do note that Capcom games use a command shortcut for QCFx2/QCBx2 motions; a D, DF, F, D, DF
;will work just as well as a D, DF, F, D, DF, F motion; if you want to replicate this behavior, all
;you have to do is check to see if either the repsective "DF/DB" or the "F/B" explods exist in the
;triggers for that move's ChangeState.
;==============================================================================================

;===========================<DOUBLE DOWN, DOWN-RIGHT, RIGHT>===============================
;this is almost identical to the D, DR, R: Right explod; the only difference is that it has a
;RemoveTime of 10 (with no additional ifElse statements), because it shouldn't persist through hitpause!
[State -1, D, DR, R, D, DR, R: 1st Right]
type = Explod
triggerAll = NumExplod(90010003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90030005
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, D, DR, R: 2nd Down]
type = Explod
triggerAll = NumExplod(90030005)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back"
anim = 1
ID = 90030002
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, D, DR, R: 2nd Down-Right]
type = Explod
triggerAll = NumExplod(90030002)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90030003
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, D, DR, R: 2nd Right]
type = Explod
triggerAll = NumExplod(90030003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90030006
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1


;===========================<DOUBLE DOWN, DOWN-LEFT, LEFT>===============================
[State -1, D, DL, L, D, DL, L: 1st Left]
type = Explod
triggerAll = NumExplod(90010101)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90030105
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, D, DL, L: 2nd Down]
type = Explod
triggerAll = NumExplod(90030105)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back"
anim = 1
ID = 90030102
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, D, DL, L: 2nd Down-Left]
type = Explod
triggerAll = NumExplod(90030102)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90030101
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, D, DL, L: 2nd Left]
type = Explod
triggerAll = NumExplod(90030101)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90030104
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;==============================================================================================
;=====<QUARTER CIRCLE FORWARD, DOWN-FORWARD, BACK/QUARTER CIRCLE BACK, DOWN-BACK, FORWARD>=====
;==============================================================================================

;==============================================================================================
;This is very, very similar to the preceding command, but it is a distinct command with its own
;quirks! This is typically used for Terry's Power Geyser super, among a few other moves. What
;makes this different from the QCF, HCB/QCB, HCF command is that although this command is officially
;referred to in move lists as "QCF, DF, B/QCB, DB, F", in KOF games, this command can (usually) skip
;straight from the starting QCF/QCB and proceed directly to the final input of the command (the
;command would here be rendered as "QCF, B"/"QCB, F"). But this can sometimes be weird: in KOF 2002
;this can only be done if  that final input in the QCF/QCB part of the command is held for at least
;two ticks (KOF 2002 is the first game in the series where the player only needs to enter an individual
;input for only one frame and still complete a command; previous games required the inputs to be held
;for at least two). In the Fatal Fury series, however, generally this either uses a motion that is
;actually "QCF, DF, B / QCB, DB, F" motion, or sometimes even a QCF, HCB/QCB, HCF motion. Point is,
;there's a ton of variance here!

;As with the previous command, we have opted to modify this for the default EXPLODsive Buffering system,
;in order to keep it relatively simple and tried to change the manner in which the command worked into
;something that made more sense (to us, at least). We have it set up so that this command can skip straight
;from the starting QCF/QCB and proceed directly to the final input of the command (the command would here
;be rendered as "QCF, B"/"QCB, F"). It also can be performed using a QCF, HCB/QCB, HCF motion, with
;the additional quirk that the user can proceed immediately to the final input of the command no matter
;where they are in the half circle motion. So, for example, the user could perform QCB, DB, D, F, and
;still get the move. What this ends up looking like translated to MUGEN code is that, for instance, the
;explod representing QCF, DF, B: DB is allowed to be created if an explod exists representing "D", or "DF",
;or even "F".

;As with the the QCF, HCB / QCB, HCF command, this can be made to accurate to the source game(s)
;by removing some or all of the non-diagonal (and also the "down") explods.
;==============================================================================================

;========================<DOWN, DOWN-RIGHT, RIGHT, DOWN-RIGHT, LEFT>===========================
[State -1, D, DR, R, DR, L: Right]
type = Explod
triggerAll = NumExplod(90010003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90032406
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, DR, L: Down-Right]
type = Explod
triggerAll = NumExplod(90032406)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90032403
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, DR, L: Down]
type = Explod
;the Down explod will be created if either (or both) the Right or Down-Right explods exist
triggerAll = NumExplod(90032406) || NumExplod(90032403)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back"
anim = 1
ID = 90032402
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, DR, L: Down-Left]
type = Explod
;the Down-Left explod will be created if the Right, Down-Right, or Down explods exist
triggerAll = NumExplod(90032406) || NumExplod(90032403) || NumExplod(90032402)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90032401
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DR, R, DR, L: Left]
type = Explod
;the Left explod will be created if the Right, Down-Right, Down, or Down-Left explods exist
triggerAll = NumExplod(90032406) || NumExplod(90032403) || NumExplod(90032402) || NumExplod(90032401)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90032404
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=========================<DOWN, DOWN-LEFT, LEFT, DOWN-LEFT, RIGHT>============================
[State -1, D, DL, L, DL, R: Left]
type = Explod
triggerAll = NumExplod(90010101)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90032504
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, DL, R: Down-Left]
type = Explod
triggerAll = NumExplod(90032504)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90032501
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, DL, R: Down]
type = Explod
triggerAll = NumExplod(90032504) || NumExplod(90032501)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "back"
anim = 1
ID = 90032502
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, DL, R: Down-Right]
type = Explod
triggerAll = NumExplod(90032504) || NumExplod(90032501) || NumExplod(90032502)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90032503
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, D, DL, L, DL, R: Right]
type = Explod
triggerAll = NumExplod(90032504) || NumExplod(90032501) || NumExplod(90032502) || NumExplod(90032503)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90032506
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1

;==============================================================================================
;====================<FORWARD, DOWN, DOWN-FORWARD/BACK, DOWN, DOWN-BACK>=======================
;==============================================================================================

;==============================================================================================
;Nothing special here, just the standard dragon punch motion!
;==============================================================================================

;================================<RIGHT, DOWN, DOWN-RIGHT>=====================================
[State -1, R, D, DR: Press Right]
type = Explod
triggerAll = NumExplod(90010003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "fwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90010206
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, R, D, DR: Release Right]
type = Explod
triggerAll = NumExplod(90000006)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
anim = 1
ID = 90010256
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, R, D, DR: Down]
type = Explod
triggerAll = NumExplod(90010206) || NumExplod(90010256)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd"
anim = 1
ID = 90010202
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, R, D, DR: Down-Right]
type = Explod
triggerAll = NumExplod(90010202)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dfwd" && Helper(90000005), command != "back" && Helper(90000005), command != "up"
anim = 1
ID = 90010203
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1



;=================================<LEFT, DOWN, DOWN-LEFT>======================================
[State -1, L, D, DL: Press Left]
type = Explod
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "back" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up" && Helper(90000005), command != "down"
anim = 1
ID = 90010304
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, L, D, DL: Release Left]
type = Explod
triggerAll = NumExplod(90000004)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command != "back" && Helper(90000005), command != "holdback"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown" || Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
anim = 1
ID = 90010354
removeTime = 5
pauseMoveTime = 5
superMoveTime = 5
ignoreHitPause = 1

[State -1, L, D, DL: Down]
type = Explod
triggerAll = NumExplod(90010304) || NumExplod(90010354)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "down" && Helper(90000005), command != "back" && Helper(90000005), command != "up" && Helper(90000005), command != "fwd"
anim = 1
ID = 90010302
removeTime = 10
pauseMoveTime = 10
superMoveTime = 10
ignoreHitPause = 1

[State -1, L, D, DL: Down-Left]
type = Explod
triggerAll = NumExplod(90010302)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel 
trigger1 = Helper(90000005), command = "dback" && Helper(90000005), command != "fwd" && Helper(90000005), command != "up"
anim = 1
ID = 90010301
removeTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
pauseMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
superMoveTime = 10 + ifElse(HitPauseTime, HitPauseTime - 1, 0)
ignoreHitPause = 1


;==============================================================================================
;===============================<REMOVE DIRECTIONAL DETECTORS>=================================
;==============================================================================================

;==============================================================================================
;this just needs a quick reminder about the detectors (should have already explained that there's a block of code at the very end of the system that removes them
;==============================================================================================
;---------------------------------------------------
;This block of RemoveExplods gets rid of any active release detector explods; if the specific direction isn't currently being input, or if the direction is being input but
;other directions are also being input, then the detector explod is removed.
;---------------------------------------------------

[State -1, Remove Down Detector]
type = RemoveExplod
triggerAll = NumExplod(90000002)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "down" && Helper(90000005), command != "holddown"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
id = 90000002
ignoreHitPause = 1

[State -1, Remove Down-Right Detector]
type = RemoveExplod
triggerAll = NumExplod(90000003)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = (Helper(90000005), command != "down" && Helper(90000005), command != "holddown") || (Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd")
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
id = 90000003
ignoreHitPause = 1

[State -1, Remove Right Detector]
type = RemoveExplod
triggerAll = NumExplod(90000006)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
id = 90000006
ignoreHitPause = 1

[State -1, Remove Up-Right Detector]
type = RemoveExplod
triggerAll = NumExplod(90000009)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = (Helper(90000005), command != "up" && Helper(90000005), command != "holdup") || (Helper(90000005), command != "fwd" && Helper(90000005), command != "holdfwd")
trigger2 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
id = 90000009
ignoreHitPause = 1

[State -1, Remove Up Detector]
type = RemoveExplod
triggerAll = NumExplod(90000008)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "up" && Helper(90000005), command != "holdup"
trigger2 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "back" || Helper(90000005), command = "holdback" || Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
id = 90000008
ignoreHitPause = 1

[State -1, Remove Up-Left Detector]
type = RemoveExplod
triggerAll = NumExplod(90000007)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = (Helper(90000005), command != "up" && Helper(90000005), command != "holdup") || (Helper(90000005), command != "back" && Helper(90000005), command != "holdback")
trigger2 = Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
id = 90000007
ignoreHitPause = 1

[State -1, Remove Left Detector]
type = RemoveExplod
triggerAll = NumExplod(90000004)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "back" && Helper(90000005), command != "holdback"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown" || Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
id = 90000004
ignoreHitPause = 1

[State -1, Remove Down-Left Detector]
type = RemoveExplod
triggerAll = NumExplod(90000001)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = (Helper(90000005), command != "down" && Helper(90000005), command != "holddown") || (Helper(90000005), command != "back" && Helper(90000005), command != "holdback")
trigger2 = Helper(90000005), command = "down" || Helper(90000005), command = "holddown"
trigger2 = Helper(90000005), command = "back" || Helper(90000005), command = "holdback"
trigger2 = Helper(90000005), command = "fwd" || Helper(90000005), command = "holdfwd" || Helper(90000005), command = "up" || Helper(90000005), command = "holdup"
id = 90000001
ignoreHitPause = 1



;==============================================================================================
;==============================<REMOVE RELEASE BUTTON DETECTORS>===============================
;==============================================================================================
[State -1, Remove x Detector]
type = RemoveExplod
triggerAll = NumExplod(90000201)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "x" && Helper(90000005), command != "holdx"
ID = 90000201
ignoreHitPause = 1

[State -1, Remove y Detector]
type = RemoveExplod
triggerAll = NumExplod(90000211)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "y" && Helper(90000005), command != "holdy"
ID = 90000211
ignoreHitPause = 1

[State -1, Remove z Detector]
type = RemoveExplod
triggerAll = NumExplod(90000221)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "z" && Helper(90000005), command != "holdz"
ID = 90000221
ignoreHitPause = 1

[State -1, Remove a Detector]
type = RemoveExplod
triggerAll = NumExplod(90000231)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "a" && Helper(90000005), command != "holda"
ID = 90000231
ignoreHitPause = 1

[State -1, Remove b Detector]
type = RemoveExplod
triggerAll = NumExplod(90000241)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "b" && Helper(90000005), command != "holdb"
ID = 90000241
ignoreHitPause = 1

[State -1, Remove c Detector]
type = RemoveExplod
triggerAll = NumExplod(90000251)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "c" && Helper(90000005), command != "holdc"
ID = 90000251
ignoreHitPause = 1

[State -1, Remove start Detector]
type = RemoveExplod
triggerAll = NumExplod(90000194)
triggerAll = NumHelper(90000005) && !IsHelper
triggerAll = !AILevel
trigger1 = Helper(90000005), command != "start" && Helper(90000005), command != "holdstart"
ID = 90000194
ignoreHitPause = 1


;==============================================================================================
;==========================================<GUARDING>==========================================
;==============================================================================================

;==============================================================================================
;Here, we override the MUGEN's default guard system, and add our own triggers. This will ensure
;that the player can always block as long as they are holding a direction away from the opponent.
;This block of code also adds "chicken guarding", which is allowing the player to air guard by holding
;not only back, but down-back and up-back.

;It is also recommended that you also override the guard states (120, 130, 131, 132, 140, 150, 151, 152, 154, 155)
;with an updated version that uses the EXPLODsive buffering system. A copy of those fixed states
;can be found in this character, and also in the release thread (here:PUT LINK HERE).
;==============================================================================================

[State -1, AssertSpecial: NoAirGuard]
type = null;AssertSpecial
triggerAll = !AILevel 
trigger1 = P2DisT x < -12 && StateType = A
trigger2 = vel x >= 0.1 
flag = NoAirGuard
ignoreHitPause = 0

[State -1, AssertSpecial: No StandGuard and NoCrouchGuard when landing from jump after switching sides]
type = AssertSpecial
triggerAll = !AILevel 
trigger1 = P2DisT x < -12 && StateType != A
flag = NoStandGuard
flag2 = NoCrouchGuard
ignoreHitPause = 0

[State -1, Stand Blocking]
type = ChangeState
triggerAll = !AILevel
triggerAll = InGuardDist
triggerAll = P2DisT x < -12 && StateType != A
triggerAll = StateType = S
triggerAll = ctrl
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000004)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000006))
value = 120

[State -1, Crouch Blocking]
type = ChangeState
triggerAll = !AILevel
triggerAll = InGuardDist
triggerAll = P2DisT x < -12 && StateType != A
triggerAll = StateType = C
triggerAll = ctrl
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000001)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000003))
value = 120

[State -1, Air Blocking]
type = null;ChangeState
triggerAll = !AILevel 
triggerAll = InGuardDist
triggerAll = StateType = A
triggerAll = ctrl
triggerAll = !(StateNo = [120,155])
triggerAll = (vel x <= 0)
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000004)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000006))
trigger2 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000001)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000003))
trigger3 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000007)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000009))
value = 120

[State -1, Air Blocking]
type = null;ChangeState
triggerAll = !AILevel 
triggerAll = InGuardDist
triggerAll = StateType = A
triggerAll = StateNo = 5210 && Time = 14
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000004)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000006))
trigger2 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000001)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000003))
trigger3 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000007)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000009))
value = 120

;==============================================================================================
;==============================================================================================
;=============================<End of EXPLODsive Buffering System>=============================
;==============================================================================================
;==============================================================================================

;===========================================================================
; HYPERS
;===========================================================================
; Destiny Mode
[State -1]
type = ChangeState
triggerall = enemy, name != "Saibamen Z2" && authorname = "Team Z2"
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = !AILevel
triggerall = RoundState = 2
triggerall = fvar(27)=0 ;No destiny mode
triggerall = NumExplod(90012602)
triggerall = NumExplod(90000210) && NumExplod(90000240) || NumExplod(90000215) && NumExplod(90000245)
triggerall = StateType != A  && !WinKo
triggerall = power >= 2000 && StateNo != 2800
trigger1 = Ctrl
trigger2 = StateNo=900
value = 2800


;Unleashed Gekiretsu Ranbu
[State -1, Unleashed Gekiretsu Ranbu]
type = ChangeState
triggerall= !AILevel
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90032506))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90032404))))
triggerall = NumExplod(90000230) || NumExplod(90000235) || NumExplod(90000240) || NumExplod(90000245) || NumExplod(90000250) || NumExplod(90000255)
triggerall = StateType != A  && !WinKo
triggerall = power >= 2000 && fvar(27)!=0 && StateNo != 2900 ;&& power >= 2000
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 3, >= 5
trigger9 = StateNo=1004 && AnimElem = 3, >= 5
trigger10 = StateNo=1007 && AnimElem = 3, >= 5
trigger11 = StateNo=1105					;Landing from specials
trigger12 = StateNo=1201					;Landing from Soaring Dragon kick
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact				;Masenko
trigger14 = StateNo = 1105 || StateNo = 1501 || StateNo = 1502 ;|| StateNo = 1255	;Ironman Pose after special
value = 2900
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul

;Gekiretsu Ranbu
[State -1, Gekiretsu Ranbu]
type = ChangeState
triggerall= !AILevel
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90032506))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90032404))))
triggerall = NumExplod(90000230) || NumExplod(90000235) || NumExplod(90000240) || NumExplod(90000245) || NumExplod(90000250) || NumExplod(90000255)
triggerall = StateType != A  && !WinKo
triggerall = power >= 3000 && StateNo != 2700 && fvar(27)=0 
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 3, >= 5
trigger9 = StateNo=1004 && AnimElem = 3, >= 5
trigger10 = StateNo=1007 && AnimElem = 3, >= 5
trigger11 = StateNo=1105					;Landing from specials
trigger12 = StateNo=1201					;Landing from Soaring Dragon kick
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact				;Masenko
trigger14 = StateNo = 1105 || StateNo = 1501 || StateNo = 1502 ;|| StateNo = 1255	;Ironman Pose after special
value = 2700
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul

; Air Chou Kamehameha
[State -1, Air Chou Kamehameha]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1,(NumExplod(90030006) || NumExplod(90030003)),(NumExplod(90030104) || NumExplod(90030101))) 
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
triggerall = Cond(fvar(27)=0, power >= 2000 && StateNo != 2600, StateNo != 2600)
;triggerall = command = "x"
triggerall = StateType=A && !WinKo
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movecontact
trigger3 = StateNo=2115 && (anim=[2115,2120]) && pos Y<-50		;Soaring Dragon Strike
trigger4 = (StateNo=1500 || StateNo=1550) && pos Y<-50			;Hurricane Kick
trigger4 = movecontact
trigger5 = (StateNo=1100 || StateNo=1150) && pos Y<-50			;Soaring Dragon Kick
trigger5 = movecontact
trigger6 = StateNo=1202 && animelemtime(1)>=0 && animelemtime(37)<0	;Dive Kick Flurry
trigger7 = (StateNo=[1251,1252]) && animelemtime(39)<0		;Ex Dive Kick Flurry
value = 2600

;Chou Kamehameha
[State -1, Chou Kamehameha]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90030006) || NumExplod(90030003))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90030104) || NumExplod(90030101))))
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
;triggerall = command = "x"
triggerall = StateType != A  && !WinKo
triggerall = Cond(fvar(27)=0, power >= 2000 && StateNo != 2400, StateNo != 2400)
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 3, >= 5
trigger9 = StateNo=1004 && AnimElem = 3, >= 5
trigger10 = StateNo=1007 && AnimElem = 3, >= 5
trigger11 = StateNo=1105						;Landing from specials
trigger12 = StateNo=1201						;Landing from Soaring Dragon kick
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact					;Masenko
trigger14 = StateNo = 1105 || StateNo = 1501 || StateNo = 1502 || StateNo = 1255;Ironman Pose after special
value = 2400



;Chou	Masenko LVL 1	2330	(fvar(27)=1)	destiny mode
;Chou	Masenko LVL 2	2300	(fvar(27)=1)
;Normal	Masenko LVL 1	2000	(fvar(27)=0)	no destiny mode
;Normal	Masenko LVL 2	2030	(fvar(27)=0)

;Chou Masenko Lvl 2
[State -1, Chou Masenko]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = fvar(27) = 1
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90030104) || NumExplod(90030101))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90030006) || NumExplod(90030003))))
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
triggerall = StateType != A  && !WinKo && StateNo != 2300
;triggerall = power >= 2000
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact   ;Wheel Kick
trigger12 = StateNo=270 && movecontact
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact						;Masenko
trigger14 = StateNo = 1105 || StateNo = 1501 || StateNo = 1502 || StateNo = 1255	;Ironman Pose after special
value = 2300

;Masenko Lvl 2
[State -1, Chou Masenko]
type = ChangeState
triggerall = !AILevel
triggerall = var(28) = 0  ;Masenko Limiter
;triggerall = RoundState = 2
triggerall = fvar(27) = 0
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90030104) || NumExplod(90030101))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90030006) || NumExplod(90030003))))
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
triggerall = StateType != A  && !WinKo && StateNo != 2030
triggerall = power >= 2000
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact   ;Wheel Kick
trigger12 = StateNo=270 && movecontact
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact						;Masenko
trigger14 = StateNo = 1105 || StateNo = 1255 || StateNo = 1501 || StateNo = 1502	;Ironman Pose after special
value = 2030



;Soaring Dragon Unleashed
[State -1, Soaring Dragon Unleashed]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90032506))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90032404))))
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
triggerall = StateType != A  && !WinKo
triggerall = power >= 2000 || fvar(27)>0
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact   ;Wheel Kick
trigger12 = StateNo=270 && movecontact
trigger13 = numhelper(2011)
trigger13 = helper(2011),movecontact					;Masenko
trigger14 = StateNo = 1105 || StateNo = 1255 || StateNo = 1501 || StateNo = 1502		;Ironman Pose after special
value = 2200



;===========================================================================
; SUPERS
;===========================================================================

; Super Hurricane Kick
[State -1, Super Hurricane Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, (NumExplod(90030104) || NumExplod(90030101)),(NumExplod(90030006) || NumExplod(90030003))) 
triggerall = NumExplod(90000230) || NumExplod(90000235) || NumExplod(90000240) || NumExplod(90000245) || NumExplod(90000250) || NumExplod(90000255)
triggerall = Cond(fvar(27)=0, power >= 1000 && StateNo != 2500, StateNo != 2500)
triggerall = StateType=A && !WinKo
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movecontact
trigger3 = (StateNo=1500 || StateNo=1550); && pos Y<-15			;Hurricane Kick
trigger3 = movecontact
trigger4 = (StateNo=1100 || StateNo=1150) && pos Y<-40			;Soaring Dragon Kick
trigger4 = movecontact
trigger5 = StateNo=1202 && animelemtime(1)>=0 && animelemtime(37)<0	;Dive Kick Flurry
trigger6 = (StateNo=[1251,1252]) && animelemtime(39)<0		;Ex Dive Kick Flurry
value = 2500

;Soaring Dragon Strike
[State -1, Soaring Dragon Strike]
type = ChangeState
triggerall= !AILevel
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90032506))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90032404))))
triggerall = NumExplod(90000200) || NumExplod(90000205) || NumExplod(90000210) || NumExplod(90000215) || NumExplod(90000220) || NumExplod(90000225)
triggerall = Cond(fvar(27)=0, power >= 1000 && StateType != A && !WinKo, StateType != A && !WinKo)
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact	;Wheel Kick
trigger12 = StateNo=270 && movecontact
trigger13 = StateNo = 1105 || StateNo = 1501 || StateNo = 1502 ;|| StateNo = 1255			;Ironman Pose after special
value = 2100


;Chou	Masenko LVL 1	2330	(fvar(27)=1)	destiny mode
;Chou	Masenko LVL 2	2300	(fvar(27)=1)
;Normal	Masenko LVL 1	2000	(fvar(27)=0)	no destiny mode
;Normal	Masenko LVL 2	2030	(fvar(27)=0)

;Lvl 1 Chou Masenko (Destiny mode)
[State -1, Masenko]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = fvar(27) = 1
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90030104) || NumExplod(90030101))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90030006) || NumExplod(90030003))))
triggerall = NumExplod(90000200) || NumExplod(90000205) || NumExplod(90000210) || NumExplod(90000215) || NumExplod(90000220) || NumExplod(90000225)
triggerall = StateType != A  && !WinKo && StateNo != 2330
;triggerall = power >= 1000
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact   ;Wheel Kick
trigger12 = StateNo=270 && movecontact
value = 2330


;Lvl 1 Masenko (normal mode)
[State -1, Masenko]
type = ChangeState
triggerall = !AILevel
triggerall = var(28) = 0  ;Masenko Limiter
;triggerall = RoundState = 2
triggerall = fvar(27) = 0
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && (NumExplod(90030104) || NumExplod(90030101))) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && (NumExplod(90030006) || NumExplod(90030003))))
triggerall = NumExplod(90000200) || NumExplod(90000205) || NumExplod(90000210) || NumExplod(90000215) || NumExplod(90000220) || NumExplod(90000225)
triggerall = StateType != A  && !WinKo && StateNo != 2000
triggerall = power >= 1000
trigger1 = Ctrl
trigger2 = StateNo = 100 || StateNo = 101
trigger3 = StateNo = 1300 && movecontact  ;Slash Chop
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger8 = StateNo=1001 && AnimElem = 5, >= 5
trigger9 = StateNo=1004 && AnimElem = 5, >= 5
trigger10 = StateNo=1007 && AnimElem = 5, >= 5
trigger11 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movecontact   ;Wheel Kick
trigger12 = StateNo=270 && movecontact
value = 2000


;===========================================================================
; SPECIALS
;===========================================================================

;EX Hurricane Kick
[State -1, EX Hurricane Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010104)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010006)))
triggerall = (ifElse(NumExplod(90000230), 1, 0) + ifElse(NumExplod(90000240), 1, 0) + ifElse(NumExplod(90000250), 1, 0) >= 2) || (ifElse(NumExplod(90000235), 1, 0) + ifElse(NumExplod(90000245), 1, 0) + ifElse(NumExplod(90000255), 1, 0) >= 2) || NumExplod(90000235) && NumExplod(90000245) || NumExplod(90000245) && NumExplod(90000255) || NumExplod(90000235) && NumExplod(90000255)
triggerall = StateType != A  && !WinKo
triggerall = power >= 500 || fvar(27)>0 && power >= 250
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1550

;Hurricane Kick
[State -1, Hurricane Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010104)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010006)))
triggerall = NumExplod(90000230) || NumExplod(90000235) 
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1500

;Hurricane Kick
[State -1, Hurricane Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010104)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010006)))
triggerall =  NumExplod(90000240) || NumExplod(90000245) 
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1505

;Hurricane Kick
[State -1, Hurricane Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010104)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010006)))
triggerall = NumExplod(90000250) || NumExplod(90000255)
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1506

;EX Ki Blast
[State -1, EX Ki Blast]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010104)))
triggerall = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2)
triggerall = StateType != A  && !WinKo
triggerall = power >= 500 || fvar(27)>0 && power >= 250
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1050

;Ki Blast (Light) 1
[State -1, Ki Blast (Light)]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010104)))
triggerall = NumExplod(90000200) || NumExplod(90000205)
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1000

;Ki Blast (Medium) 1
[State -1, Ki Blast (Medium)]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010104)))
triggerall = NumExplod(90000210) || NumExplod(90000215)
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1003

;Ki Blast (Hard) 1
[State -1, Ki Blast (Hard)]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010104)))
triggerall = NumExplod(90000220) || NumExplod(90000225)
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1006

;EX Soaring Dragon Kick
[State -1, EX Soaring Dragon Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010203)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010301)))
triggerall = (ifElse(NumExplod(90000230), 1, 0) + ifElse(NumExplod(90000240), 1, 0) + ifElse(NumExplod(90000250), 1, 0) >= 2) || (ifElse(NumExplod(90000235), 1, 0) + ifElse(NumExplod(90000245), 1, 0) + ifElse(NumExplod(90000255), 1, 0) >= 2) || NumExplod(90000235) && NumExplod(90000245) || NumExplod(90000245) && NumExplod(90000255) || NumExplod(90000235) && NumExplod(90000255)
triggerall = StateType != A  && !WinKo
triggerall = power >= 500 || fvar(27)>0 && power >= 250
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
value = 1150

;Soaring Dragon Kick LK
[State -1, Soaring Dragon Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010203)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010301)))
triggerall = NumExplod(90000230) || NumExplod(90000235) 
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
trigger7 = StateNo = 1502
value = 1100

;Soaring Dragon Kick MK
[State -1, Soaring Dragon Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010203)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010301)))
triggerall = NumExplod(90000240) || NumExplod(90000245) 
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
trigger7 = StateNo = 1502
value = 1101

;Soaring Dragon Kick SK
[State -1, Soaring Dragon Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90010203)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90010301)))
triggerall = NumExplod(90000250) || NumExplod(90000255)
triggerall = StateType != A  && !WinKo
trigger1 = ctrl
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movecontact
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movecontact
trigger4 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movecontact
trigger5 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movecontact
trigger6 = StateNo = 100 || StateNo = 101
trigger7 = StateNo = 1502
value = 1102

;EX Dive Kick Flurry
[State -1, EX Dive Kick Flurry]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90010006),NumExplod(90010104))
triggerall = (ifElse(NumExplod(90000230), 1, 0) + ifElse(NumExplod(90000240), 1, 0) + ifElse(NumExplod(90000250), 1, 0) >= 2) || (ifElse(NumExplod(90000235), 1, 0) + ifElse(NumExplod(90000245), 1, 0) + ifElse(NumExplod(90000255), 1, 0) >= 2) 
triggerall = StateType=A && !WinKo
triggerall = power >= 500 || fvar(27)>0 && power >= 250
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movecontact
value = 1250

;Dive Kick Flurry
[State -1, Dive Kick Flurry]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90010006),NumExplod(90010104))
triggerall = NumExplod(90000230) || NumExplod(90000235) || NumExplod(90000240) || NumExplod(90000245) || NumExplod(90000250) || NumExplod(90000255)
triggerall = var(15):=(NumExplod(90000230) || NumExplod(90000235)) + 2*(NumExplod(90000240) || NumExplod(90000245)) + 3*(NumExplod(90000250) || NumExplod(90000255))
triggerall = StateType=A && !WinKo
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movecontact
value = 1200

; Slashing Chop (aka Focus Attack)
[State -1, Slashing Chop]
type = ChangeState
triggerall= !AILevel
triggerall = RoundState = 2
triggerall = StateNo !=[1300,1302]
triggerall = StateNo != 106
triggerall = NumExplod(90000220) && NumExplod(90000250) || command = "holdz" && command = "holdc"
trigger1 = StateType = S
trigger1 = ctrl
value = 1300

;Zetto Counter - Ground
[State -1, Z Counter - Ground]
type = ChangeState
trigger1 = !AILevel
trigger1 = StateNo=150 || StateNo=152
trigger1 = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000004)))
trigger1 = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2) || (ifElse(NumExplod(90000230), 1, 0) + ifElse(NumExplod(90000240), 1, 0) + ifElse(NumExplod(90000250), 1, 0) >= 2) || (ifElse(NumExplod(90000235), 1, 0) + ifElse(NumExplod(90000245), 1, 0) + ifElse(NumExplod(90000255), 1, 0) >= 2)
trigger1 = RoundState=2 && power>=1000 && StateType!=A
value = 750

;ZettoCounter - Air
[State -1, Z Counter - Air]
type = ChangeState
trigger1 = !AILevel
trigger1 = StateNo=154  
trigger1 = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000004)))
trigger1 = (ifElse(NumExplod(90000200), 1, 0) + ifElse(NumExplod(90000210), 1, 0) + ifElse(NumExplod(90000220), 1, 0) >= 2) || (ifElse(NumExplod(90000205), 1, 0) + ifElse(NumExplod(90000215), 1, 0) + ifElse(NumExplod(90000225), 1, 0) >= 2) || (ifElse(NumExplod(90000230), 1, 0) + ifElse(NumExplod(90000240), 1, 0) + ifElse(NumExplod(90000250), 1, 0) >= 2) || (ifElse(NumExplod(90000235), 1, 0) + ifElse(NumExplod(90000245), 1, 0) + ifElse(NumExplod(90000255), 1, 0) >= 2)
trigger1 = RoundState=2 && power>=1000 && StateType=A
value = 760


;===========================================================================
; COMMAND & SYSTEM MOVES
;===========================================================================

; Wheel Kick Mega
[State -1, Wheel Kick Mega]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = StateType!=A
trigger1 = StateNo = 250 && movecontact
trigger1 = NumExplod(90000250) 
;trigger2 = StateNo = 260 && animelemtime(10) > 0 && animelemtime(13) < 0		;After Wheel Kick (outdated)
;trigger2 = command="b" 
value = 270

; New f,f+MK
[State -1, New f,f+MK]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = StateType!=A
trigger1 = StateNo = 100 || StateNo = 101
trigger1 = NumExplod(90000240) && !NumExplod(90000001) && !NumExplod(90000002)  && !NumExplod(9000003)
trigger1 = ifElse(Facing = 1, NumExplod(90000006),NumExplod(90000004))
value = 265

; Running Launcher Kick
[State -1, Launcher Kick]
type = ChangeState
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = StateType!=A
trigger1 = StateNo = 100 || StateNo = 101
trigger1 = NumExplod(90000250) && !NumExplod(90000001) && !NumExplod(90000002)  && !NumExplod(9000003)
trigger1 = ifElse(Facing = 1, NumExplod(90000006),NumExplod(90000004))
value = 455

;Destiny Mode Charge
[State -1]
type = ChangeState
triggerall = !AILevel
triggerall = fvar(27)>0  ;Destiny Mode
triggerall = RoundState = 2
triggerall = StateType != A
triggerall = fvar(28) < 300
triggerall = StateNo != 2810
triggerall = Ctrl
trigger1 = NumExplod(90000210) && NumExplod(90000240) || command = "holdb" && command = "holdy"
value = 2810

;Power Charge
[State -1]
type = ChangeState
triggerall = !AILevel
triggerall = fvar(27)<=0  ;No Destiny Mode
triggerall = RoundState = 2
triggerall = StateType != A
triggerall = Power < 3000
triggerall = StateNo != 900
triggerall = Ctrl
;trigger1 = command = "b" && command = "y"
trigger1 = NumExplod(90000210) && NumExplod(90000240) || command = "holdb" && command = "holdy"
value = 900

; Punch Throw (Tomoe Nage)
[State -1, throw1]
type = ChangeState
triggerall= !AILevel
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000004)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000006))) && NumExplod(90000800) 
trigger1 = RoundState=2 && ctrl && StateType=S && StateNo!=100
value = 800

; Kick Throw (Headbutt)
[State -1, throw2]
type = ChangeState
triggerall= !AILevel
triggerall = ((ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000006)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000004))) && NumExplod(90000800)  || NumExplod(90000800)
trigger1 = RoundState=2 && ctrl && StateType=S && StateNo!=100
value = 820

;===========================================================================
; OMNI KICKS
;===========================================================================

;Up Back Kick
[State -1, Up Back Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall =  ifElse(Facing = 1, NumExplod(90000027),NumExplod(90000029))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1470

;Back Kick
[State -1, Back Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90000024),NumExplod(90000026))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1460

;Down Back Kick
[State -1, Down Back Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90000021),NumExplod(90000023))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1450

;Down Fwd Kick
[State -1, Down Fwd Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90000023),NumExplod(90000021))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1430

;Down Kick
[State -1, Down Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000022)
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1440

;Up Fwd Kick
[State -1, Up Fwd Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90000029),NumExplod(90000027))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1410

;Fwd Kick
[State -1, Fwd Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = ifElse(Facing = 1, NumExplod(90000026),NumExplod(90000024))
triggerall = NumExplod(90000250)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1420

;Up Kick
[State -1, Up Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000028)
triggerall = NumExplod(90000250) 
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = [610,617]) ;|| (StateNo = 620) 
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 645) || (StateNo = 650)
trigger3 = MoveContact
value = 1400

;===========================================================================
; NORMALS
;===========================================================================

;Jump Down Medium Punch
[State -1, Jump Down Medium Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000210)
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = MoveContact
value = 615

; Stand Light Punch
[State -1, Stand Light Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000200) ||  command = "x"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateNo = 100 || StateNo = 101
;trigger3 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 200

; Stand Medium Punch
[State -1, Stand Medium Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000210) ||  command = "y"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateType != A && movecontact
trigger2 = (StateNo = 200) || (StateNo = 230)
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A && movecontact
trigger4 = (StateNo = 400) || (StateNo = 430)
;trigger5 =  StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 210

; Stand Strong Punch
[State -1, Stand Strong Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000220) ||  command = "z"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateType != A && movecontact
trigger2 = (StateNo = 200) || (StateNo = 230) || (StateNo = 210) || (StateNo = 240) || (StateNo = 246)
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A && movecontact
trigger4 = (StateNo = 400) || (StateNo = 430) || (StateNo = 410) || (StateNo = 440)
;trigger5 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 220

; Stand Light Kick
[State -1, Stand Light Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000230) ||  command = "a"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateNo = 100 || StateNo = 101
;trigger3 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 230

; Standing Medium Kick
[State -1, Standing Medium Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000240) ||  command = "b"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateType != A
trigger2 = (StateNo = 200) || (StateNo = 230)
trigger2 = movecontact
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A && movecontact
trigger4 = (StateNo = 400) || (StateNo = 430)
;trigger5 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 240

; Stand Medium Kick Combo
[State -1, Stand Medium Kick Combo]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000240) ||  command = "b"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
triggerall = StateType = S
trigger1 = StateNo = 210 && movecontact
trigger2 = StateNo = 240 && movecontact
value = 246

; Standing Strong Kick
[State -1, Standing Strong Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000250) ||  command = "c"
triggerall = (!NumExplod(90000021) && !NumExplod(90000022) && !NumExplod(90000023))
trigger1 = StateType = S
trigger1 = ctrl
trigger2 = StateType != A
trigger2 = (StateNo = 200) || (StateNo = 210) || (StateNo = 230) || (StateNo = 240) || (StateNo = 246)
trigger2 = movecontact
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A && movecontact
trigger4 = (StateNo = 400) || (StateNo = 410) || (StateNo = 420) || (StateNo = 430) || (StateNo = 440)
;trigger5 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 250

; Crouching Light Punch
[State -1, Crouching Light Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000200) ||  command = "x"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 200) || (StateNo = 230)
trigger3 = StateNo = 100 || StateNo = 101
;trigger4 =  StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 400

; Crouching Medium Punch
[State -1, Crouching Medium Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000210) ||  command = "y"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 400) || (StateNo = 200) || (StateNo = 230) || (StateNo = 430)
trigger3 = StateNo = 100 || StateNo = 101
;trigger4 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 410

; Crouching Strong Punch
[State -1, Crouching Strong Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000220) ||  command = "z"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 400) || (StateNo = 410) || (StateNo = 430) || (StateNo = 440)
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A & MoveContact
trigger4 = (StateNo = 200) || (StateNo = 210) || (StateNo = 230) || (StateNo = 240) || (StateNo = 246)
;trigger5 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 420

; Crouching Light Kick
[State -1, Crouching Light Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000230) ||  command = "a"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 200) || (StateNo = 230)
trigger3 = StateNo = 100 || StateNo = 101
;trigger4 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 430

; Crouching Medium Kick
[State -1, Crouching Medium Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000240) ||  command = "b"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023) 
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 400) || (StateNo = 200) || (StateNo = 230) || (StateNo = 430)
trigger3 = StateNo = 100 || StateNo = 101
;trigger4 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 440

; Crouching Strong Kick
[State -1, Crouching Strong Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000250) ||  command = "c"
triggerall = NumExplod(90000021) || NumExplod(90000022) || NumExplod(90000023)
triggerall = StateType != A
trigger1 = ctrl
trigger2 = MoveContact
trigger2 = (StateNo = 400) || (StateNo = 410) || (StateNo = 430) || (StateNo = 440)
trigger3 = StateNo = 100 || StateNo = 101
trigger4 = StateType != A & MoveContact
trigger4 = (StateNo = 200) || (StateNo = 210) || (StateNo = 230) || (StateNo = 240) || (StateNo = 246)
;trigger5 = StateNo = 265 && movehit && animelemtime(10)>0 ;After f,f,MK
value = 450

;Jump Light Punch
[State -1, Jump Light Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000200) ||  command = "x"
triggerall = StateNo != 600
triggerall = StateType = A
trigger1 = ctrl
value = 600

;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000210) ||  command = "y"
triggerall = StateType = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = MoveContact
value = 610

;Jump Medium Punch combo
[State -1, Jump Medium Punch combo]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000210) ||  command = "y"
triggerall = StateType = A
trigger1 = StateNo = 610
trigger1 = movecontact
trigger2 = StateNo = 640
trigger2 = movecontact
trigger3 = StateNo = 615
trigger3 = movecontact
value = 617

;Jump Strong Punch
[State -1, Jump Strong Punch]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000220) ||  command = "z"
triggerall = StateType = A 
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 640) || (StateNo = 645)
trigger2 = MoveContact
value = 620

;Jump Light Kick
[State -1, Jump Light Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000230) ||  command = "a"
triggerall = StateType = A
trigger1 = ctrl
value = 630

;Jump Medium Kick
[State -1, Jump Medium Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000240) ||  command = "b"
triggerall = StateType = A
triggerall = (StateNo!=640); && (StateNo!=645)
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = movecontact
value = 640

;Jump Medium Kick combo
[State -1, Jump Medium Kick combo]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000240) ||  command = "b"
triggerall = StateType = A
trigger1 = StateNo = 610
trigger1 = movecontact
trigger2 = StateNo = 640
trigger2 = movecontact
trigger3 = StateNo = 615
trigger3 = movecontact
value = 645

;Jump Strong Kick
[State -1, Jump Strong Kick]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000250) ||  command = "c"
triggerall = StateType = A
trigger1 = ctrl
trigger1 = StateNo != 650
trigger2 = (StateNo = 600) || (StateNo = 630) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 640) || (StateNo = 645)
trigger2 = MoveContact
value = 650

;===========================================================================
; SYSTEM
;===========================================================================

; Taunt
[State -1, Taunt]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000195)  ||  command = "start"
triggerall = StateNo!=195
trigger1 = StateType != A
trigger1 = ctrl
value = 195
;
;;Air Dash Down
;check state 50 in override.cns, there's a changestate for the Air Dash - Down.
[State -1, Down]
type = ChangeState
value = 118
triggerall = !AILevel
triggerall = var(10) > 0 ;limiter
triggerall = pos Y < -20
triggerall = fvar(27) > 0
triggerall = (NumExplod(90000562)) 
trigger1 = (StateType = A) && (ctrl)
trigger2 = prevstateno = [10230,10233]
trigger3 = StateNo = 1440 && MoveContact
trigger4 = StateNo = 1405 && MoveContact

;Air Dash Forward
[State -1, Fwd]
type = ChangeState
value = 110
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = var(10) > 0 ;limiter
triggerall = pos Y < -20
;triggerall = StateNo != 105
triggerall = ifElse(Facing = 1, NumExplod(90001016),NumExplod(90001064))
trigger1 = (StateType = A) && (ctrl) 
trigger2 = StateNo = 1410 && MoveContact
trigger3 = StateNo = 1420 && MoveContact
trigger4 = StateNo = 1430 && MoveContact
trigger5 = StateNo = 1405 && MoveContact

;Air Dash Up
[State -1, Up]
type = ChangeState
value = 117
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = var(10) > 0 ;limiter
triggerall = pos Y < -20
;triggerall = StateNo != 105
triggerall = NumExplod(90000518)
trigger1 = (StateType = A) && (ctrl)
trigger2 = StateNo = 1400 && MoveContact
trigger3 = StateNo = 1405 && MoveContact

;Air Dash Back
[State -1, Back]
type = ChangeState
value = 115
triggerall = !AILevel
;triggerall = RoundState = 2
triggerall = var(10) > 0 ;limiter
;triggerall = vel x <= 0
triggerall = pos Y < -20
;triggerall = StateNo != 105
triggerall = ifElse(Facing = 1, NumExplod(90001064),NumExplod(90001016))
trigger1 = (StateType = A) && (ctrl) 

; Run Fwd
[State -1, Run Fwd]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90001016)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90001064))
triggerall = StateType = S && ctrl
trigger1 = RoundState=2 && (StateNo!=[100,106])
value = 100

; Run Back
[State -1, Run Back]
type = ChangeState
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90001064)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90001016))
triggerall = StateType = S
trigger1 = ctrl
trigger2 = StateNo=195 && animelemtime(3)>=0
value = 105

; Super Jump
;This state executes only after performing the air launcher
[State -1, Jump Launcher]
type = ChangeState
value = 10230
triggerall= !AILevel
;triggerall = RoundState = 2
triggerall = NumExplod(90000008) || NumExplod(90000009) || NumExplod(90000007)
trigger1 = (StateNo = 450 || StateNo = 455) && animelemtime(7)>0 && MoveHit

[State -1, Super Jump Forward]
type = ChangeState
value = 10232
triggerall= !AILevel
;triggerall = RoundState = 2
trigger1 = StateType = S
trigger1 = ctrl
trigger1 = NumExplod(90000408) 
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000009)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000007))

[State -1, Super Jump Backward]
type = ChangeState
value = 10233
triggerall= !AILevel
;triggerall = RoundState = 2
trigger1 = StateType = S
trigger1 = ctrl
trigger1 = NumExplod(90000408)
trigger1 = (ifElse(P2DisT x < -12, Facing = -1, Facing = 1) && NumExplod(90000007)) || (ifElse(P2DisT x < -12, Facing = 1, Facing = -1) && NumExplod(90000009))

[State -1, Super Jump Straight Up]
type = ChangeState
value = 10231
triggerall= !AILevel
;triggerall = RoundState = 2
trigger1 = StateType = S
trigger1 = ctrl
trigger1 = NumExplod(90000408)

;chickenblock
[State -1, ChangeState]
type = ChangeState
triggerall = AILevel = 0
triggerall = InGuardDist
triggerall = StateType = A
trigger1 = command = "holdback" && command = "holdup"
trigger1 = ctrl
trigger2 = StateNo = 5210 && Time = 14
trigger2 = (command = "holdback" && command = "holdup") || (command = "holdback" && command = "holddown") || (command = "holdback" )
value = 120

;===========================================================================
;===========================================================================
;===========================================================================
;===========================================================================
;===========================================================================
; AI
;===========================================================================
;===========================================================================
;===========================================================================
;===========================================================================
;===========================================================================


;===========================================================================
; SYSTEM AI
;===========================================================================
[State -1, Air Dash AI]
type = ChangeState
value = Ifelse(enemynear,Movetype=A&&enemynear, vel x>0&&random<150,115,110)
triggerall = AILevel >= 1 && RoundState = 2 && numenemy && var(10) > 0 && pos Y < -20
triggerall = StateNo != 105 && StateType = A && (p2bodydist x>=80) && (p2bodydist y=[-44,44])
triggerall = ceil(random<=80*(AILevel**2/64.0))
trigger1 = ctrl
trigger2 = StateNo=105 && (random<350)


[State -1, Air Dash Up AI]
type = ChangeState
value = 117
triggerall = AILevel >= 1 && RoundState = 2 && numenemy && var(10) > 0 && pos Y < -20
triggerall = StateNo != 105 && StateType = A && (p2bodydist x>=70) && (p2bodydist y=[-175,-45])
triggerall = ceil(random<=80*(AILevel**2/64.0))
trigger1 = ctrl
trigger2 = StateNo=105 && (random<500)


[State -1, Air Dash Down AI]
type = ChangeState
value = 118
triggerall = AILevel >= 1 && RoundState = 2 && numenemy && var(10) > 0 && pos Y < -20
triggerall = StateNo != 105 && StateType = A && enemynear,StateType = A && enemynear,movetype = A && (p2bodydist x>=80) && (p2bodydist y=[45,155])
triggerall = ceil(random<=50*(AILevel**2/64.0))
trigger1 = ctrl


[State -1, Fall Recovery AI]
type=ChangeState
value= ifelse((pos y>=-20), 5200, 5210)
trigger1= AILevel && numenemy
trigger1= RoundState=2 && alive
trigger1= StateNo=5050 && canrecover
trigger1= vel y>=-1 && ceil(random<=50*(AILevel**2/64.0))


[State -1, Run AI]
type=ChangeState
value=100
trigger1= AILevel && numenemy
trigger1= RoundState=2 && StateType=S
trigger1= ctrl && (StateNo!=[100,106])
trigger1= (enemynear,movetype!=A) && p2bodydist x>=140 && ceil(random<=20*(AILevel**2/64.0))


[State -1, Jump AI]
type=ChangeState
value=40
trigger1= AILevel && numenemy && ceil(random<=50*(AILevel**2/64.0))
trigger1= RoundState=2 && StateType!=A && ctrl
trigger1= enemynear,movetype=A && p2bodydist x<160 && enemynear,hitdefattr=SC,AT


[State -1, Dash Backward AI]
type=ChangeState
value=105
triggerall= AILevel && numenemy
triggerall= RoundState=2 && StateType=S
triggerall= ctrl && (StateNo!=[100,106])
trigger1= (enemynear,movetype=A) && backedgedist>=80 && (p2bodydist x=[80,120]) && (enemynear,vel x)
trigger1= random<ifelse((enemynear,hitdefattr=SC,AT),150,50) && ceil(random=300*(AILevel**2/64.0))
trigger2= (p2bodydist x=[0,80]) && backedgebodydist>=50
trigger2= enemynear,StateNo=5120 && enemynear,animtime=-3 && ceil(random<=100*(AILevel**2/64.0))



;[State -1, Guard AI]
;type = ChangeState
;value = 120
;triggerall = AILevel && numenemy		;triggerall
;triggerall = RoundState=2 && inguarddist 	;triggerall
;;trigger1   = ctrl && (StateNo!=[120,155])&& !(enemynear,ctrl) && enemynear,Movetype=A	;trigger1
;;trigger1   = !(enemynear,hitdefattr=SCA,AT) && (enemynear,time<120)			;trigger1
;;trigger1   = StateType!=A || p2StateType=A					;trigger1
;trigger1   = random<ifelse((p2StateNo=[200,699]), 50*(AILevel**2/64.0), ifelse((p2StateNo=[1000,2999]), 100*(AILevel**2/64.0), 500)) 	;trigger2
;trigger1   = ctrl && p2bodydist x<=-5		;trigger2

;[State -1, Guard AI]
;type = ChangeState
;value = 120
;triggerall= AILevel && numenemy&& StateNo!=[120,155]
;triggerall= Ctrl||StateNo = 21
;triggerall=enemynear,Movetype=A
;trigger1 = inguarddist

[State -1, Guard AI] ;AlexSin
type = ChangeState
value = 120
triggerall = AILevel && numenemy && RoundState = 2 && inguarddist && (StateNo != [120,155])
trigger1   = !(enemynear,hitdefattr=SCA,AT) && (enemynear,time<120)
trigger1   = (StateType!=A || p2StateType=A)
trigger1   = random<ifelse((p2StateNo=[200,699]), 50*(AILevel**2/64.0), ifelse((p2StateNo=[1000,2999]), 100*(AILevel**2/64.0), 500))
;trigger1   = random<(ifelse((P2StateNo=[200, 699]),100,ifElse((P2StateNo = [1000,2999]),333, 1000))*(AILevel ** 2 / 64.0))
trigger1   = ctrl && p2bodydist x<=-5


[State -1, Super Jump AI]
type = ChangeState
value = 10232
triggerall = AILevel && numenemy && StateType != A && RoundState = 2 && (p2bodydist y = [-320,-40])
triggerall = StateNo != 100 && pos y = 0 
trigger1 = ctrl && enemy,vel y < -1 && (p2bodydist x = [ 10, 70]) && enemynear,movetype != A && ceil(random<30*(AILevel**2/64.0))
trigger2 = ctrl && enemy,vel y < -1 && ceil(random<30*(AILevel**2/64.0))
trigger2 = enemynear,movetype = H && (enemynear,StateNo=5040)
trigger2 = p2bodydist x <= 50 && ceil(random<60*(AILevel**2/64.0))


[State -1, Launcher AI];Super Jump after launcher AI
type = ChangeState
value = 10230
triggerall = AILevel && numenemy && StateType != A && RoundState = 2 && pos y = 0
trigger1 = ctrl && enemynear,MoveType != H && P2BodyDist Y < -120 && enemy,vel y != 0
trigger2 = (StateNo = 450 || StateNo = 455) && animelemtime(7)>0 && MoveHit && ceil(random<200*(AILevel**2/64.0)) 


[State -1, Zetto Counter AI]
type=ChangeState
value=750
trigger1= AILevel && numenemy && RoundState=2 && StateType!=A && ceil(power>=1000+(AILevel**2/64.0))
trigger1= StateNo=150 || StateNo=152
trigger1= ceil(random<=5*(AILevel**2/64.0))
trigger1= (p2bodydist x=[0,50]) && (life<.5*lifemax)


[State -1, Air Zetto Counter AI]
type=ChangeState
value=760
trigger1= AILevel && numenemy && RoundState=2 && StateType=A && ceil(power>=1000+(AILevel**2/64.0))
trigger1= StateNo=154
trigger1= ceil(random<=5*(AILevel**2/64.0))
trigger1= (p2bodydist x=[0,50]) && (life<.5*lifemax)


[State -1, New F,F+MK Kick AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && StateType!=A && ceil(random<50*(AILevel**2/64.0))
triggerall= (enemy,StateNo!=[120,155])&&(enemy,StateNo!=[5100,5120])&&(enemynear,StateType!=L)
triggerall= (enemynear,StateNo!=40) && (p2bodydist x=[10,50]) && (p2bodydist y=[-80,5])
trigger1 = (StateNo = 100 || StateNo = 101) 
value = 265


[State -1, Power Charge AI]
type=ChangeState
value=900
triggerall= AILevel && fvar(27)<=0 && numenemy && RoundState=2 && StateType!=A
triggerall= power<const(data.power) && Movetype!=A && enemynear,Movetype!=A && !(enemynear,ctrl)
triggerall=  power < const(data.power) && power < powermax 
triggerall= !inguarddist && p2bodydist x>=140 && ceil(random<50*(AILevel**2/64.0))
triggerall = StateNo != 900
triggerall= ctrl
trigger1=(enemynear,Movetype=H||enemynear,StateType=L)
trigger2=enemynear,vel x<0 
trigger3=enemynear,StateNo=[120,155]


[State -1, Throw AI]
type = ChangeState
value = Ifelse(random<=500,800,820)
triggerall = AILevel && ceil(random<100*(AILevel**2/64.0))
triggerall = RoundState=2 && StateType!=A && enemynear,StateType!=L && (enemynear,StateNo!=[5120,5201])
triggerall = enemynear,movetype!=H && enemynear,StateType!=A && enemynear,Hitover && (p2bodydist x =[0,30])
triggerall = ctrl||StateNo=100||StateNo=52
trigger1 = ceil(random<50*(AILevel**2/64.0))
trigger2 = enemynear,StateNo=[120,145]
trigger2 = ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo=100
trigger4=(p2bodydist x=[0,30]) && random<80
trigger5=(p2StateNo=[120,145]) && (p2bodydist x=[0,30]) && ceil(random<50*(AILevel**2/64.0))

[State -1, Standing Light Punch AI]
type = ChangeState
value = 200
triggerall = AILevel && numenemy && RoundState = 2 && StateType != A
triggerall =(p2bodydist x = [0, 40])&&(p2bodydist y = [-80,5])&&P2StateType != C&&P2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = [100,101]) && ceil(random<50*(AILevel**2/64.0))
trigger3 = ctrl&&(enemynear,ctrl) && ceil(random<50*(AILevel**2/64.0))

[State -1, Standing Medium Punch AI]
type = ChangeState
value = 210
triggerall = AILevel && numenemy && RoundState=2 && StateType != A  && P2StateType != C
triggerall = (p2bodydist x = [0, 45]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = [200,209])|| (StateNo = [230,239])||(StateNo = [400,409])||(StateNo = [430,439]))&& movehit
trigger2 = ceil(random<200*(AILevel**2/64.0))
trigger3 = ctrl&&(enemynear,ctrl) && ceil(random<50*(AILevel**2/64.0))

[State -1, Standing Heavy Punch AI]
type = ChangeState
value = 220
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [15, 55]) && (p2bodydist y = [ -100, 80]) && p2StateType != L && P2StateType != C
trigger1 = ctrl && ceil(random<75*(AILevel**2/64.0))
trigger2 = ((StateNo = [210,219])|| (StateNo = [240,249])||(StateNo = [410,419])||(StateNo = [440,449]))&& movehit
trigger2 = ceil(random<100*(AILevel**2/64.0))

[State -1, Standing Light Kick AI]
type = ChangeState
value = 230
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && (p2bodydist x = [0, 35]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = [100,101]) && random < 100
trigger3 = ctrl&&(enemynear,ctrl) && random < 200

[State -1, Standing Medium Kick AI]
type = ChangeState
value = 240
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && P2StateType != C
triggerall = (p2bodydist x = [0, 55]) && p2StateType != L
trigger1 = ctrl && ceil(random<80*(AILevel**2/64.0))
trigger2 = ((StateNo = [210,219])|| (StateNo = [230,239])||(StateNo = [410,419])||(StateNo = [430,439]))&& movehit
trigger2 = ceil(random<150*(AILevel**2/64.0))
trigger3 = ctrl&&(enemynear,ctrl) && ceil(random<200*(AILevel**2/64.0))

[State -1, Standing Medium Kick Combo AI]
type = ChangeState
value = 246
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && P2StateType != C
triggerall = (p2bodydist x = [0, 65]) && p2StateType != L && random<250
trigger1 = ((StateNo = 200)|| (StateNo = 240))&& movehit
trigger1 = ceil(random<200*(AILevel**2/64.0))

[State -1, Standing Heavy Kick AI]
type = ChangeState
value = 250
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && P2StateType != C
triggerall = (p2bodydist x = [0, 50]) && (p2bodydist y = [ -70, 50]) && p2StateType != L
trigger1 = ctrl && ceil(random<100*(AILevel**2/64.0))
trigger2 = ((StateNo = 210)|| (StateNo = [240,249])||(StateNo = [410,420])||(StateNo = [440,449]))&& movehit
trigger2 = ceil(random<150*(AILevel**2/64.0))

[State -1, 360 Split Kick AI]
type = ChangeState
value = 270
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && P2StateType != C
triggerall = (p2bodydist x = [0, 70]) && p2StateType != L && ceil(random<=400*(AILevel**2/64.0))
trigger1 = StateNo=250 && Movehit



[State -1, Crouching Light Punch]
type = ChangeState
value = 400
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [0, 30]) &&(p2bodydist y = [-50,25]) && P2StateType != A && P2StateType != L
trigger1 = ctrl && ceil(random<75*(AILevel**2/64.0))
trigger2 = (StateNo = [100,101]) && ceil(random<100*(AILevel**2/64.0))

[State -1, Crouching Medium Punch]
type = ChangeState
value = 410
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [0, 40]) &&(p2bodydist y = [-50,25]) && P2StateType != A && P2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = [200,209])|| (StateNo = [230,239])||(StateNo = [400,409])||(StateNo = [430,439]))&& movehit
trigger2 = random < 800

[State -1, Crouching Heavy Kick]
type = ChangeState
value = 450
triggerall = AILevel && numenemy && RoundState=2 && StateType != A && P2StateType != A
triggerall = (p2bodydist x = [0, 50]) && (p2bodydist y = [ -50, 50]) && p2StateType != L && p2StateType = S
trigger1 = ctrl && ceil(random<80*(AILevel**2/64.0))
trigger2 = ((StateNo = [200,210])|| (StateNo = [230,249])||(StateNo = [400,410])||(StateNo = [430,449]))&& movehit
trigger2 = random < 400

[State -1, Crouching Heavy Punch]
type = ChangeState
value = 420
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [0, 40]) &&(p2bodydist y = [-75,5]) && P2StateType != L
trigger1 = ctrl && ceil(random<92*(AILevel**2/64.0)) ;ceil(random<100*(AILevel**2/64.0))
trigger2 = ((StateNo = [200,219])|| (StateNo = [230,249])||(StateNo = [400,419])||(StateNo = [430,449]))&& movehit
trigger2 = random < 500 ;750



[State -1, Crouching Light Kick]
type = ChangeState
value = 430
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [0, 40]) &&(p2bodydist y = [-50,25]) && P2StateType != A
trigger1 = ctrl && ceil(random<30*(AILevel**2/64.0)) && P2StateType != L
trigger2 = ctrl && !numtarget(1098) && var(7)<1 && ceil(random<100*(AILevel**2/64.0)) && (enemynear,StateNo=5110)&&(p2bodydist x = [-8, 22])
trigger2 = enemynear,StateType=L && enemynear,StateNo!=5120 && p2dist y=0

[State -1, Crouching Medium Kick]
type = ChangeState
value = 440
triggerall = AILevel && numenemy && RoundState=2 && StateType != A
triggerall = (p2bodydist x = [0, 45]) &&(p2bodydist y = [-50,25]) && P2StateType != A
trigger1 = ctrl && ceil(random<40*(AILevel**2/64.0)) && P2StateType != L
trigger2 = ((StateNo = [210,219])|| (StateNo = [230,239])||(StateNo = [410,419])||(StateNo = [430,439]))&& movehit
trigger2 = random < 350 && P2StateType != L
trigger3 = ctrl && !numtarget(1098) && var(7)<1 && ceil(random<100*(AILevel**2/64.0)) && (enemynear,StateNo=5110)&&(p2bodydist x = [-8, 22])
trigger3 = enemynear,StateType=L && enemynear,StateNo!=5120 && p2dist y=0




[State -1, Jumping Light Punch]
type = ChangeState
value = 600
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A && StateNo != 600
triggerall = (p2bodydist x = [0,70]) && (p2bodydist y = [ -80, 30]) && p2StateType != L
trigger1 = ctrl && ceil(random<100*(AILevel**2/64.0))

[State -1, Jumping Medium Punch]
type = ChangeState
value = 610
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A
triggerall = (p2bodydist x = [0, 70]) && (p2bodydist y = [ -70, 20]) && p2StateType != L
trigger1 = ctrl && random < (ifelse((vel x > 0 && p2StateType = A), ceil(random<60*(AILevel**2/64.0)), ceil(random<20*(AILevel**2/64.0))))
trigger2 = (StateNo = 600||StateNo = 630)&& movehit && random < 500

[State -1, Jumping Down Medium Punch]
type = ChangeState
value = 615
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A
triggerall = (p2bodydist x = [40, 90]) && (p2bodydist y = [ -50, 150]) && p2StateType != L
trigger1 = ctrl && random < (ifelse((vel x > 0 && p2StateType = A), ceil(random<25*(AILevel**2/64.0)), ceil(random<150*(AILevel**2/64.0))))
trigger2 = (StateNo = 600||StateNo = 630)&& movehit && random < 500

[State -1, Jumping Medium Punch Combo]
type = ChangeState
value = 617
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A
triggerall = (p2bodydist x = [0, 70]) 
trigger1 = ((StateNo = 610)||(StateNo = 615)||(StateNo = 640))&& movecontact && random < 350

[State -1, Jumping Heavy Punch]
type = ChangeState
value = 620
triggerall = AILevel && numenemy && RoundState=2 && StateType = A
triggerall = (p2bodydist x = [0, 80]) && (p2bodydist y = [ -90, 30]) && p2StateType != L
trigger1 = ctrl && ceil(random<20*(AILevel**2/64.0))
trigger2 = (StateNo = 600||StateNo = 630)&& movehit && random < 50 && enemynear,StateType=A
trigger3 = (StateNo = 610||StateNo = 640)&& movehit && random < 100  && enemynear,StateType=A

[State -1, Jumping Light Kick]
type = ChangeState
value = 630
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A && (enemynear,StateType=A)
triggerall = (p2bodydist x = [5, 50]) && (p2bodydist y = [ -20, 50]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))

[State -1, Jumping Medium Kick]
type = ChangeState
value = 640
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A
triggerall = (p2bodydist x = [-30,80]) && (p2bodydist y = [ -30, 70]) && p2StateType != L
trigger1 = ctrl && ceil(random<60*(AILevel**2/64.0))
trigger2 = (StateNo = 600||StateNo = 630)&& movehit && random < 300
trigger3 = ctrl && (enemynear,StateType=A) && ceil(random<100*(AILevel**2/64.0))

[State -1, Jumping Heavy Kick]
type = ChangeState
value = 650
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A
triggerall = (p2bodydist x = [0, 70]) && (p2bodydist y = [ -50, 40]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0)) && p2StateType != A
trigger2 = (StateNo = 600||StateNo = 630)&& movehit && random < 150 && enemynear,StateType=A
trigger3 = (StateNo = 610||StateNo = 617||StateNo = 630||StateNo = 640)&& movehit && random < 150 && enemynear,StateType=A




[State -1, Fwd Angle Kick]
type = ChangeState
value = Ifelse((p2bodydist y < -45)&&((p2bodydist x =[0,25])),1400,Ifelse((p2bodydist y < -45)&&((p2bodydist x >25)),1410,Ifelse((p2bodydist y =[-45,25])&&((p2bodydist x >15)),1420,1430)))
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A && ceil(random<150*(AILevel**2/64.0))
triggerall = (p2bodydist x = [ 0, 80]) && (p2bodydist y = [ -90, 90]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = [600,650]))&& movehit && random < 250 



[State -1, Back Angle Kick]
type = ChangeState
value = Ifelse((p2bodydist y < -45)&&((p2bodydist x =[-25,0])),1450,Ifelse((p2bodydist y < -45)&&((p2bodydist x <-25)),1460,Ifelse((p2bodydist y =[-45,25])&&((p2bodydist x <0)),1470,1440)))
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A && ceil(random<150*(AILevel**2/64.0))
triggerall = (p2bodydist x = [ -80, 0]) && (p2bodydist y = [ -90, 90]) && p2StateType != L
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = [600,650]))&& movehit && random < 250 

;===========================================================================
; AI SPECIALS
;===========================================================================

[State -1, Ki Blast AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && StateType != A
triggerall = (enemy,StateNo!=[120,155])&&(enemy,StateNo!=[5100,5120])&&(enemynear,StateType!=L)&&(enemynear,StateType!=A)
triggerall = (enemynear,StateNo!=40) && (p2bodydist x>=15) && (p2bodydist y=[-80,5])
trigger1 = ctrl && ceil(random<20*(AILevel**2/64.0))
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 250) || (StateNo = 260)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger4 = ((StateNo = 400) || (StateNo = 410)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger5 = ((StateNo = 430) || (StateNo = 440)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger6 = ctrl && ceil(random<50*(AILevel**2/64.0)) && enemynear,StateNo=275 && enemynear,movetype=H && enemynear,StateType=A
value = Ifelse(power>500 && ceil(random<25*(AILevel**2/64.0)),1050,Ifelse(power>250 && fvar(27)>0 && ceil(random<25*(AILevel**2/64.0)),1050,IfElse(random<500,1006,Ifelse(random<300,1003,1000))))

[State -1, Hurricane Kick AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && StateType != A
triggerall = (enemynear,StateType != L)  && (enemynear,StateNo != [120,155]) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x =[-10,110]) && (p2bodydist y =[-90,5]) && (enemynear,StateType != C)
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220)) && movehit && ceil(random<40*(AILevel**2/64.0))
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 250) || (StateNo = 260)) && movehit && ceil(random<40*(AILevel**2/64.0))
trigger4 = ((StateNo = 400) || (StateNo = 410)) && movehit && ceil(random<40*(AILevel**2/64.0))
trigger5 = ((StateNo = 430) || (StateNo = 440)) && movehit && ceil(random<40*(AILevel**2/64.0))
trigger6 = ctrl && ceil(random<50*(AILevel**2/64.0)) && enemynear,StateNo=275 && enemynear,movetype=H && enemynear,StateType=A
value = Ifelse(power>500&&random<25,1550,IfElse(power > 250 && fvar(27)>0 && random < 25,1550,1500))

[State -1, Soaring Dragon Kick AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && StateType != A
triggerall = (p2StateNo != [120, 155]) && (enemynear,StateType != L) && (enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x =[-5,65]) && (p2bodydist y =[-120,5]) && ((enemynear,StateType != C)||(enemynear,StateType=A))
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger3 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 250) || (StateNo = 260)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger4 = ((StateNo = 400) || (StateNo = 410)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger5 = ((StateNo = 430) || (StateNo = 440)) && movehit && ceil(random<25*(AILevel**2/64.0))
trigger6 = ctrl && ceil(random<100*(AILevel**2/64.0)) && enemynear,StateNo=275 && enemynear,movetype=H && enemynear,StateType=A
value = Ifelse(power > 500 && random < 25, 1150, IfElse(power > 250 && fvar(27) > 0 && random < 25, 1150, 1100))

[State -1, Dive Kick Flurry AI]
type = ChangeState
triggerall = AILevel  && numenemy && RoundState = 2 && StateType = A && (enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x =[60,120]) && (p2bodydist y =[-10,250]) && Pos Y<=-50
trigger1 = ctrl && ceil(random<30*(AILevel**2/64.0))
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movehit && ceil(random<60*(AILevel**2/64.0))
trigger3 = ctrl && random<50 && enemynear,StateNo=652 && enemynear,movetype=H && enemynear,StateType=A
value = Ifelse((power >= 500+(AILevel**2/64.0) && random < 10), 1250,IfElse((power >= 250+(AILevel**2/64.0) && random < 10 && fvar(27)>0),1250,1200))

[State -1, Slashing Chop AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && (StateNo !=[1300,1302]) && StateNo != 106 && StateType = S
triggerall = (enemynear,hitdefattr=S,NP,SP) && (p2bodydist y = [ -70, 0]) && (p2StateType != L) && (enemynear, vel y >= 0)
triggerall = (enemynear, const(size.head.pos.y) <= -40) || (enemynear, StateType != A)
trigger1 = ctrl && ceil(random<50*(AILevel**2/64.0))
value = 1300

;===========================================================================
; SUPERS
;===========================================================================
[State -1, Super Hurricane Kick AI]
type = ChangeState
triggerall = AILevel && RoundState = 2 && StateType = A
triggerall = power >= 1000 && StateNo != 2500 && (enemynear,StateNo!=[5100,5220]) && (enemynear,StateType=A)
triggerall = (p2bodydist x =[-40,60]) && (p2bodydist y =[-45,-15]) && Pos Y<=-50
trigger1 = ctrl && ceil(random<100*(AILevel**2/64.0))
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 615) || (StateNo = 617) || (StateNo = 630) || (StateNo = 640) || (StateNo = 645)
trigger2 = movehit && ceil(random<50*(AILevel**2/64.0))
trigger3 = (StateNo=1500 || StateNo=1550) && pos Y<-15	
trigger3 = movehit && ceil(random<50*(AILevel**2/64.0))
trigger4 = (StateNo=1100 || StateNo=1150) && pos Y<-40			
trigger4 = movehit && ceil(random<50*(AILevel**2/64.0))
trigger5 = StateNo=1202 && animelemtime(1)>=0 && animelemtime(37)<0 && (enemynear,movetype=H) && (enemynear,StateNo!=5040)					
value = 2500

[State -1, Soaring Dragon Strike AI]
type = ChangeState
triggerall = AILevel && RoundState = 2 && StateType != A 
triggerall = power >= 1000 || fvar(27)>0
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x =[40,140]) && (p2bodydist y =[-80,5]) &&(enemynear, StateType != A) &&(enemynear, Movetype != A)
trigger1 = Ctrl && ceil(random<30*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<20*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<20*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<20*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<20*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger11 = ceil(random<30*(AILevel**2/64.0)) && (StateNo = 1105 || StateNo = 1255 || StateNo = 1501 || StateNo = 1502)						
value = 2100

[State -1, Masenko AI]
type = ChangeState
triggerall = AILevel && var(28) = 0 && RoundState = 2 && StateType != A && StateNo != 2000
triggerall = power >= 1000 && fvar(27)=0
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x <=80) && (p2bodydist y =[-80,5]) 
trigger1 = Ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))
value = 2000

[State -1, Masenko lvl 2 AI]
type = ChangeState
triggerall = AILevel && var(28) = 0 && RoundState = 2 && StateType != A && StateNo != 2030
triggerall = power >= 2000 && fvar(27)=0
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x <=80) && (p2bodydist y =[-80,5]) 
trigger1 = Ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger11 = ceil(random<30*(AILevel**2/64.0)) && (StateNo = 1255)						
value = 2030

;===========================================================================
; HYPERS AI
;===========================================================================

[State -1, Unleashed Gekiretsu Ranbu AI]
type = ChangeState
triggerall = AILevel && var(28) = 0 && RoundState = 2 && StateType != A && StateNo != 2900
triggerall = power >= 2000 && fvar(27)!=0
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220]) && (enemynear,StateType!=A)
triggerall = (p2bodydist x =[0,80]) && (p2bodydist y =[-80,5])  ;x 60, 140
trigger1 = Ctrl && ceil(random<150*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<20*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))
;trigger11 = numhelper(2011)
;trigger11 = helper(2011),movehit
value = 2900
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul

[State -1, Gekiretsu Ranbu AI]
type = ChangeState
triggerall = AILevel && RoundState = 2 && StateType != A && StateNo != 2700 && power >= 3000 
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220]) && (enemynear,StateType!=A)
triggerall = (p2bodydist x =[0,80]) && (p2bodydist y =[-80,5])   ;x 60, 180
triggerall = fvar(27)=0
trigger1 = Ctrl && ceil(random<150*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<20*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))							
value = 2700
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul

[State -1, Air Chou Kamehameha AI]
type = ChangeState
triggerall = AILevel && numenemy && RoundState = 2 && StateType = A   && power >= 2000 && StateNo != 2600 && Pos y<=-40
triggerall = (enemy,StateNo!=[5100,5120]) && (enemynear,StateType!=L) && (enemynear,StateType!=C) && (p2bodydist x=[60,180]) && (p2bodydist y=[-20,180])
trigger1 = ctrl && (Random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = movehit && (Random<100*(AILevel**2/64.0))
trigger3 = (StateNo = 1100) || (StateNo = 1110)  
trigger3 = movehit && (Random<80*(AILevel**2/64.0))
trigger4 = (StateNo=[1200,1252])   
trigger4 = (movehit = [2,8]) && (Random<50*(AILevel**2/64.0))
trigger3 = StateNo=2115 && (anim=[2115,2120]) && pos Y<-50		
trigger3 = movehit && (Random<25*(AILevel**2/64.0))
trigger4 = (StateNo=1500 || StateNo=1550) && pos Y<-50			
trigger4 = movehit && (Random<25*(AILevel**2/64.0))
trigger5 = (StateNo=1100 || StateNo=1150) && pos Y<-50			
trigger5 = movehit && (Random<25*(AILevel**2/64.0))
trigger6 = StateNo=1202 && animelemtime(1)>=0 && animelemtime(37)<0
trigger6 = movehit && (Random<25*(AILevel**2/64.0))	
trigger7 = (StateNo=[1251,1252]) && animelemtime(39)<0
trigger7 = movehit && (Random<25*(AILevel**2/64.0))						
value = 2600

[State -1, Chou Kamehameha AI]
type = ChangeState
triggerall = AILevel && RoundState = 2 && StateType != A && StateNo != 2400
triggerall = power >= 2000 
triggerall = (enemy,StateNo!=[120,155])&&(enemy,StateNo!=[5100,5120])&&(enemynear,StateType!=L)&&(enemynear,StateType!=A)
triggerall = (enemynear,StateNo!=40) && (p2bodydist x>=120) && (p2dist y=[-70,5])
trigger1 = Ctrl && ceil(random<150*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<20*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<50*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<50*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<50*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<50*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))				
value = 2400

[State -1, Chou Masenko lvl 2 AI]
type = ChangeState
triggerall = fvar(27)>=1
triggerall = AILevel && RoundState = 2 && StateType != A && StateNo != 2300
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x <=80) && (p2bodydist y =[-80,5]) 
trigger1 = Ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0)) && (p2bodydist x = [0,200]) && (p2dist y=[-70,5])
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))						;Landing from Soaring Dragon kick						
trigger11 = ceil(random<30*(AILevel**2/64.0)) && (StateNo = 1255)
value = 2300

[State -1, Chou Masenko lvl 1 AI]
type = ChangeState
triggerall = fvar(27)>=1
triggerall = AILevel && RoundState = 2 && StateType != A && StateNo != 2330
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x <=80) && (p2bodydist y =[-80,5]) 
trigger1 = Ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0)) && (p2bodydist x = [0,130]) && (p2dist y=[-70,5])
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))						;Landing from Soaring Dragon kick						
value = 2330

[State -1, Soaring Dragon Unleashed AI]
type = ChangeState
triggerall = AILevel && RoundState = 2 && StateType != A 
triggerall = power >= 2000 || fvar(27)>0
triggerall = (enemynear,StateType != L) && !(enemynear, hitfall)&&(enemynear,StateNo!=[5100,5220])
triggerall = (p2bodydist x =[40,140]) && (p2bodydist y =[-80,5]) &&(enemynear, StateType != A)
trigger1 = Ctrl && ceil(random<50*(AILevel**2/64.0))
trigger2 = (StateNo = 100 || StateNo = 101) && ceil(random<50*(AILevel**2/64.0))
trigger3 = StateNo = 1300 && movehit && ceil(random<30*(AILevel**2/64.0))
trigger4 = ((StateNo = 200) || (StateNo = 210) || (StateNo = 220) || (StateNo = 215)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger5 = ((StateNo = 230) || (StateNo = 240) || (StateNo = 246) || (StateNo = 250)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger6 = ((StateNo = 400) || (StateNo = 410) || (StateNo = 420)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger7 = ((StateNo = 430) || (StateNo = 440) || (StateNo = 450) || (StateNo = 455)) && movehit && ceil(random<30*(AILevel**2/64.0))
trigger8 = ((StateNo=1001) || (StateNo=1004 )|| (StateNo=1007)) && AnimElem = 5, >= 5 && (enemynear,movetype=H) && ceil(random<25*(AILevel**2/64.0))
trigger9 = StateNo=260 && animelemtime(10) > 0 && animelemtime(13) < 0 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger10 = StateNo=270 && movehit && ceil(random<50*(AILevel**2/64.0))
trigger11 = ceil(random<30*(AILevel**2/64.0)) && (StateNo = 1255)
value = 2200

[State -1, Destiny Mode AI]
type = ChangeState
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = AILevel && RoundState = 2 && StateType != A  && power >= 2000 && StateNo != 2800 && fvar(27) = 0
triggerall = ((enemynear,StateType=L)||(enemynear,Movetype!=A)) && (p2bodydist x>100) && Life>=200
trigger1 = Ctrl && (Random<100*(AILevel**2/64.0))
trigger2 = StateNo=900 && Movetype = I && (Random<50*(AILevel**2/64.0))
value = 2800

[State -1, Destiny Mode Charge AI]
type = ChangeState
triggerall = AILevel && fvar(27)>0  
triggerall = RoundState = 2 && StateType != A && fvar(28) < 300 && StateNo != 2810
triggerall = Ctrl
trigger1=(enemynear,Movetype=H||enemynear,StateType=L)
trigger2=enemynear,vel x<0 
trigger3=(enemynear,StateNo=[120,155])||(enemynear,StateNo=20&&enemynear,anim=21)
value = 2810
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul

