;#ADD004BASIC#

[remap]
	x=x
	y=y
	z=z
	a=a
	b=b
	c=c
	s=s
[defaults]
	command.time=16
	command.buffer.time=1


;---------------
;---------------
[command]
	name="hp1"
	command=~D,F,D,F,x
	time=32
[command]
	name="hp1_s"
	command=~D,F,D,F,y
	time=32
[command]
	name="hp1"
	command=~D,F,x+y
[command]
	name="hp1_s"
	command=~D,F,y+z
;------
[command]
	name="hp2"
	command=~D,B,D,B,x
	time=32
[command]
	name="hp2_s"
	command=~D,B,D,B,y
	time=32
[command]
	name="hp2"
	command=~D,B,x+y
[command]
	name="hp2_s"
	command=~D,B,y+z
;------
[command]
	name="hp3"
	command=~D,F,D,F,a
	time=32
[command]
	name="hp3_s"
	command=~D,F,D,F,b
	time=32
[command]
	name="hp3"
	command=~D,F,a+b
[command]
	name="hp3_s"
	command=~D,F,b+c


;-----------------

[command]
	name="sp1"
	command=~D,F,x
[command]
	name="sp1_s"
	command=~D,F,y
;------
[command]
	name="sp2"
	command=~D,B,x
[command]
	name="sp2_s"
	command=~D,B,y
;------
[command]
	name="sp3"
	command=~D,F,a
[command]
	name="sp3_s"
	command=~D,F,b
;------
[command]
	name="sp4"
	command=~D,B,a
[command]
	name="sp4_s"
	command=~D,B,b
;------
[command]
	name="sp5"
	command=a+b
	time=1

;-----------------
[command]
	name="ff"
	command=F,F
	time=10
[command]
	name="bb"
	command=B,B
	time=10

;-----------------
[command]
	name="recovery"
	command=x+y
	time=1
[command]
	name="recovery"
	command=z
	time=1
[command]
	name="ab"
	command=a+b
	time=1
[command]
	name="ab"
	command=c
	time=1

;-----------------
[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="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









;--------------------
[statedef -1]
;--------------------



;---
;--- get_hit_voice ; ꐺ
[state 0]
	type=playsnd
	trigger1=stateno=5000 || stateno=5010 || stateno=5020 || stateno=5070 || stateno=5100
	trigger1=time=1 && alive && random<500
	value=5000,(random%3)
	channel=0
;---
[state 0] ; blocking/just defence
	type=playsnd
	trigger1=stateno=195500 && time=1
	value=0,ifelse(random<500,24,0)
	channel=0



;---
;---
; combo flag
[state 0]
	type=varset
	trigger1=var(41)
	var(41)=0
[state 0]
	type=varset
	triggerall=movecontact
	triggerall=!var(41)
	triggerall=roundstate=2
	trigger1=stateno=200 || (stateno=220 && anim=225) || stateno=230 || (stateno=250 && anim=255)
	trigger2=stateno=400 || stateno=420 || stateno=430 || stateno=440
	var(41)=1



;--------------------
; hyper / super
;--------------------

; Bu-shin-Mu-so-Ren-ge (Max2)
; _oA (Max2)
[state 0]
	type=changestate
	value=3400
	triggerall=command="hp2" || command="hp2_s"
	triggerall=var(51)<1
	triggerall=power>=2000
	trigger1=statetype!=a && ctrl

;---
; Ajara-Ten-gu 
; YV
[state 0]
	type=changestate
	value=3200
	triggerall=command="hp1" || command="hp1_s"
	triggerall=var(51)<1
	triggerall=power>=1000
	trigger1=statetype=a && ctrl

;---
; Bu-shin-Gurai-Ha 
; _j
[state 0]
	type=changestate
	value=3100
	triggerall=command="hp1" || command="hp1_s"
	triggerall=var(51)<1
	triggerall=power>=1000
	trigger1=statetype!=a && (ctrl || var(41))

;---
; Te-sshin-Hou 
; SS
[state 0]
	type=changestate
	value=3000
	triggerall=command="hp3" || command="hp3_s"
	triggerall=var(51)<1
	triggerall=power>=1000
	trigger1=statetype!=a && (ctrl || var(41))



;--------------------
; special
;--------------------

; Gen-ko
; R
[state 0]
	type=changestate
	value=1050
	triggerall=command="sp1" || command="sp1_s"
	triggerall=var(51)<1
	trigger1=statetype!=a && (ctrl || var(41))

;---
; Haya-gake
; 삯
[state 0]
	type=changestate
	value=1100
	triggerall=command="sp3" || command="sp3_s"
	triggerall=var(51)<1
	trigger1=statetype!=a && (ctrl || var(41))

;---
; Saka-Haya-gake
; t삯
[state 0]
	type=changestate
	value=1200
	triggerall=command="sp4" || command="sp4_s"
	triggerall=var(51)<1
	trigger1=statetype!=a && (ctrl || var(41))

;---
; Re-ppu-Kyaku
; 󕗋r
[state 0]
	type=changestate
	value=1300
	triggerall=command="sp5"
	triggerall=var(51)<1
	trigger1=statetype!=a && (ctrl || var(41))

;---
; Ha-ssou-Kyaku - Back-Jump
; zr - Op
[state 0]
	type=changestate
	value=1400
	triggerall=command="holdfwd"
	triggerall=var(51)<1
	triggerall=(stateno!=1400) && (prevstateno!=1400) && (stateno!=1450) && (prevstateno!=1450)
	trigger1=statetype=a && ctrl && (pos y<-15) && (backedgebodydist<10)

;---
; Ha-ssou-Kyaku - Air-Throw / Air-Kick / Jump-Down
; zr - 󒆓/󒆏R/ߗ
[state 0]
	type=changestate
	value=1450
	triggerall=command="sp2" || command="sp2_s" || command="sp4" || command="sp4_s"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl && (pos y<-15) && (backedgebodydist<10)

;---
; Ten-gu-Daoshi
; V|
[state 0]
	type=changestate
	value=1500
	triggerall=command="sp1" || command="sp1_s"
	triggerall=var(51)<1
	trigger1=(pos y<-15) && (var(32)!=[2,3])
	trigger1=statetype=a && ctrl






;--------------------
; normal
;--------------------


;;--- leap
;[state 0]
;	type=changestate
;	value=48
;	triggerall=(sysvar(4)=0) && roundstate=2
;	triggerall=statetype!=a && (ctrl || var(41))
;	triggerall=(sysfvar(0)>id) && playeridexist(floor(sysfvar(0)))
;	triggerall=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(22)=2)
;	trigger1=(command="x" && command="a") && (command!="holdup") && var(51)<1
;	trigger2=var(51)>0 && sysfvar(4)<1 && (p2bodydist x<82) && random<80

;;--- guard-break
;[state 0]
;	type=changestate
;	value=8210
;	triggerall=(sysvar(4)=0) && power>=1000 && roundstate=2
;	triggerall=statetype!=a && (ctrl || var(41))
;	triggerall=(sysfvar(0)>id) && playeridexist(floor(sysfvar(0)))
;	triggerall=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(22)=2)
;	trigger1=(command="y" && command="b") && var(51)<1
;	trigger2=var(51)>0 && sysfvar(4)<1 && (p2bodydist x<60) && random<85

;;--- guard-cancel / zero-counter
;[state 0]
;	type=changestate
;	value=8200
;	triggerall=(sysvar(4)=0) && power>=1000 && roundstate=2
;	triggerall=(stateno=150 || stateno=152) && time>1 && alive
;	trigger1=(command="ab") && var(51)<1
;	trigger2=var(51)>0 && sysfvar(4)<1 && (p2bodydist x<82)
;	trigger2=(sysfvar(0)>id) && playeridexist(floor(sysfvar(0)))
;	trigger2=(playerid(floor(sysfvar(0))),var(0)=90900) && random<(roundno+matchno+var(51)+var(51)+var(51))*28
;	trigger2=(random>life*3) || (playerid(floor(sysfvar(0))),var(36)>40) ;;{0,50}

;;--- guard-cancel-escape
;[state 0]
;	type=changestate
;	value=ifelse(command="holdback",115,110)
;	triggerall=(sysvar(4)=0) && power>=500 && roundstate=2
;	triggerall=(stateno=150 || stateno=152) && time>1 && alive
;	trigger1=(command="recovery") && var(51)<1
;	trigger2=var(51)>0 && sysfvar(4)<1 && random<50
;[state 0]
;	type=poweradd
;	triggerall=(sysvar(4)=0)
;	trigger1=(stateno=110 || stateno=115) && time=1
;	trigger1=(prevstateno=150 || prevstateno=152)
;	value=-500

;--- roll
[state 0]
	type=changestate
	value=ifelse(command="holdback",115,110)
	triggerall=command="recovery"
	triggerall=statetype!=a && ctrl
	triggerall=var(51)<1 && !var(4)
	trigger1=(sysfvar(0)>id) && playeridexist(floor(sysfvar(0)))
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(22)!=[2,3])
	trigger2=(sysfvar(0)<=0)

;---
; run
[state 0]
	type=changestate
	value=100
	trigger1=command="ff"
	trigger1=var(51)<1
	trigger1=statetype=s && ctrl && stateno!=100

; backstep
[state 0]
	type=changestate
	value=105
	trigger1=command="bb"
	trigger1=var(51)<1
	trigger1=statetype=s && ctrl && stateno!=105


;--------------------
; Throw
;--------------------

;  (P: / K:G܂)
[state 0]
	type=changestate
	value=800
	triggerall=(command="b" || command="y") && (command="holdfwd" || command="holdback")
	trigger1=statetype=s && ctrl && (stateno!=[100,101])
	trigger1=p2statetype!=a && p2movetype!=h && p2statetype!=l && (p2bodydist x=[-25,25])


;--------------------
; Leap-Attack (JHP)
; WvU (P)
[state 0]
	type=changestate
	value=620
	trigger1=stateno=58 && (vel y>=-1)


;--------------------
; basic
;--------------------

; Taunt
; 
[state 0]
	type=changestate
	value=195
	triggerall=command="start"
	triggerall=var(51)<1
	trigger1=statetype=s && ctrl

;---
; SF+LP / O + Pp`
[state 0]
	type=changestate
	value=210
	triggerall=command="x" && command="holdfwd" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype=s && ctrl

; SF+LK / O + LbN
[state 0]
	type=changestate
	value=240
	triggerall=command="a" && command="holdfwd" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype=s && ctrl

;---
; SLP / p`
[state 0]
	type=changestate
	value=200
	triggerall=command="x" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype!=a && ctrl
	trigger2=(stateno=200||stateno=230||stateno=400||stateno=430) && (time>4 || movecontact)

; SHP / p`
[state 0]
	type=changestate
	value=220
	triggerall=command="y" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype=s && ctrl

; SLK / LbN
[state 0]
	type=changestate
	value=230
	triggerall=command="a" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype!=a && ctrl
	trigger2=(stateno=200||stateno=230||stateno=400||stateno=430) && (time>4 || movecontact)

; SHK / LbN
[state 0]
	type=changestate
	value=250
	triggerall=command="b" && command!="holddown"
	triggerall=var(51)<1
	trigger1=statetype=s && ctrl

;---
; CLP / p`
[state 0]
	type=changestate
	value=400
	triggerall=command="x" && command="holddown"
	triggerall=var(51)<1
	trigger1=statetype!=a && ctrl
	trigger2=(stateno=200||stateno=230||stateno=400||stateno=430) && (time>4 || movecontact)

; CMP / p` ; 410

; CHP / p`
[state 0]
	type=changestate
	value=420
	triggerall=command="y" && command="holddown"
	triggerall=var(51)<1
	trigger1=statetype=c && ctrl
	trigger2=(stateno=400||stateno=430) && (movecontact)

; CMK / LbN
[state 0]
	type=changestate
	value=440
	triggerall=command="a" && command="holddown" && (command="holdfwd" || command="holdback")
	triggerall=var(51)<1
	trigger1=statetype!=a && ctrl
	trigger2=(stateno=200||stateno=230||stateno=400||stateno=430) && movecontact

; CLK / LbN
[state 0]
	type=changestate
	value=430
	triggerall=command="a" && command="holddown"
	triggerall=var(51)<1
	trigger1=statetype!=a && ctrl
	trigger2=(stateno=200||stateno=230||stateno=400||stateno=430) && (time>4 || movecontact)

; CHK / LbN
[state 0]
	type=changestate
	value=450
	triggerall=command="b" && command="holddown"
	triggerall=var(51)<1
	trigger1=statetype=c && ctrl

;---
; J D+LP / IƂ ( + P)
[state 0]
	type=changestate
	value=700
	triggerall=command="x" && command="holddown"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl

;---
; JLP / p`
[state 0]
	type=changestate
	value=600
	triggerall=command="x"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl

; JHP /  󋭃p`
[state 0]
	type=changestate
	value=620
	triggerall=command="y"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl

; JLK / LbN
[state 0]
	type=changestate
	value=630
	triggerall=command="a"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl

; JHK / 󋭃LbN
[state 0]
	type=changestate
	value=650
	triggerall=command="b"
	triggerall=var(51)<1
	trigger1=statetype=a && ctrl









;--------------------
; [ai]
;--------------------

; ai trigger
[state 0]
	type=varset
	trigger1=var(51)>0 && sysfvar(4)<1 && roundstate=2
	trigger1=!ishelper && movetype!=h && gethitvar(isbound)=0
	var(50)=ifelse(statetype=a, 1, ifelse(statetype=s, 2, 3))
[state 0]
	type=varset
	trigger1=var(50)>0
	trigger1=var(51)<1 || roundstate!=2 || sysfvar(4)>0
	var(50)=0

;-------------------
; SLP ;  P200
[state 0] ; stand attack***
	type=changestate
	value=200
	triggerall=var(50)>1
	trigger1=ctrl && p2statetype!=l && (p2bodydist x=[-32,32]) && random<560
	trigger2=stateno=200 && var(41) && (p2bodydist x=[-18,18]) && random<500

; S-Attack ;  P200 K230 /  P220 K250
[state 0] ; stand attack***
	type=changestate
	value=ifelse(random<350, ifelse(random<500,200,230),  220+(random<500)*30  )
	triggerall=var(50)>1 && ctrl && p2statetype!=l

	trigger1=sysfvar(0)>0 && playeridexist(floor(sysfvar(0)))
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && playerid(floor(sysfvar(0))),var(18)%10=1

	trigger2=(p2bodydist x=[-32,32]) && p2statetype=s && random<420
	trigger3=(stateno=[100,101]) && (p2bodydist x=[-26,26]) && random<360
	trigger4=stateno=52 && animtime=0 && (prevstateno=[600,699]) && (p2bodydist x=[-42,42]) && random<660

; Far-SHP / SMP / SMK ;  -  P220 / O+P(P)210 / O+K(K)240
[state 0] ; stand attack***
	type=changestate
	value=ifelse(random<150, ifelse(random<500,210,240), 220)
	trigger1=var(50)>1 && ctrl && (p2bodydist x=[30,65]) && p2statetype!=l && p2statetype=s && (gametime%600<200) && random<250

;---
; C-Attack ;  P400 K430 /  P420 K450
[state 0] ; crouching attack
	type=changestate
	value=ifelse(random<750, ifelse(random<500,450,430), 400 )
	triggerall=var(50)>1 && ctrl && p2statetype!=l

	trigger1=sysfvar(0)>0 && playeridexist(floor(sysfvar(0)))
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(18)/10)%10=1

	trigger2=(p2bodydist x=[-40,40]) && p2movetype!=a && p2statetype=s && random<180
	trigger3=(prevstateno=52) && (p2bodydist x=[-42,42]) && random<200

; CHP ;  P420
[state 0]
	type=changestate
	value=420
	triggerall=var(50)>1 && p2statetype!=l
	trigger1=stateno=52 && (animtime=0) && (prevstateno=[600,699]) && (p2bodydist x=[-32,32]) && random<500
	trigger2=(stateno=400 || stateno=430) && movecontact && (p2bodydist x=[-26,26]) && random<200
	;;--- ΋
	trigger3=ctrl && sysfvar(0)>0 && playeridexist(floor(sysfvar(0)))
	trigger3=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(18)/1000)%10=1
	trigger3=(p2bodydist x=[-30,30]) && (p2bodydist y>=-80) && random<500

; CLP/CLK ;  P400 K430
[state 0]
	type=changestate
	value=ifelse(random<500,400,430)
	triggerall=var(50)>1 && p2statetype!=l && (p2bodydist x=[-30,30])
	trigger1=(stateno=200||stateno=230||stateno=400||stateno=430) && var(41) && random<300

; CNK ;  K440
[state 0] ; crouching attack
	type=changestate
	value=440
	trigger1=var(50)>1 && ctrl && (p2bodydist x=[35,75]) && p2statetype!=l && p2statetype!=a && (gametime%850=[350,650]) && random<150

; CHK ;  K450
[state 0]
	type=changestate
	value=450
	trigger1=var(50)>1 && ctrl && (p2bodydist x=[10,60]) && p2statetype=s && p2movetype!=a && random<150

;---
; Jumpping-Attack
; 󒆍U
[state 0]
	type=changestate
	value=ifelse(random<200, 600+(random<700)*30, 620+(random<600)*30 )
	triggerall=var(50)=1 && ctrl && (p2movetype!=h || random<200 || p2statetype!=a)
	trigger1=sysfvar(0)>0 && playeridexist(floor(sysfvar(0))) && (prevstateno!=8200) && (prevstateno!=712) && (prevstateno!=720)
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(18)/100)%10=1
	trigger2=(p2bodydist x=[-62,62]) && (p2bodydist y<68) && (vel y>0) && random<500
	trigger3=(p2bodydist x=[-26,26]) && (p2bodydist y=[-26,26]) && random<700

; Air - Fall-Down
; 󒆍U - IƂ
[state 0] ; jump attack
	type=changestate
	value=700
	trigger1=var(50)=1 && ctrl && (p2bodydist x=[-26,26]) && (p2bodydist y<-38) && p2movetype!=h && random<80

;---
; Far_Retrain
; 
[state 0]
	type=changestate
	value=ifelse(random<400,400,200) +(random<400)*30
	trigger1=var(50)>1 && ctrl && (sysfvar(0)>0) && playeridexist(floor(sysfvar(0)))
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && playerid(floor(sysfvar(0))),var(18)%10=2

;---
; Upper - Reppu
; ΋} : ΋ -  ; (󕗋r)
[state 0]
	type=changestate
	value=1300
	triggerall=var(50)>1 && ctrl && p2statetype!=l

	trigger1=sysfvar(0)>0 && playeridexist(floor(sysfvar(0)))
	trigger1=(playerid(floor(sysfvar(0))),var(0)=90900) && (playerid(floor(sysfvar(0))),var(18)/1000)%10=1

	trigger2=p2movetype=a && (p2bodydist x=[-32,32]) && random<420
	trigger3=p2statetype=a && (p2bodydist x=[-30,30]) && (p2bodydist y=[-80,0]) && random<500
	trigger4=stateno=0 && (prevstateno=5121) && p2movetype=a && (p2bodydist x=[-30,38]) && random<110

;---
; Dash
; ڋ߁Eړ 삯 / t삯
[state 0]
	type=changestate
	value=ifelse(random<650, 1100, 1200)
	triggerall=var(50)>1 && (gametime%600>300)
	trigger1=ctrl && (p2bodydist x!=[-52,52]) && p2statetype!=a && random<180 && random<(p2bodydist x*2)
	trigger2=var(41) && random<ifelse(moveguarded, 165, 77)

;---
; Air-Jump (In-Corner)
; zr h - Op + zr h- 󒆓/󒆏R/ߗ
[state 0]
	type=changestate
	value=1400 +(random<750)*50
	trigger1=var(50)=1 && ctrl && (gametime%600>260) && random<320
	trigger1=(pos y<-15) && (backedgebodydist<10) && (stateno!=1400) && (prevstateno!=1400) && (stateno!=1450) && (prevstateno!=1450)

;---
; Gen-ko
; R
[state 0]
	type=changestate
	value=1050
	triggerall=var(50)>1
	trigger1=ctrl && (p2bodydist x!=[-100,100]) && p2statetype!=a && random<50 && (gametime%60=[1,10])
	trigger2=(stateno=220||stateno=250||stateno=420||stateno=440) && var(41) && (p2bodydist x!=[-28,28]) && random<250

;---
; Ten-gu (Air-Throw)
; V| (󒆓)
[state 0]
	type=changestate
	value=1500
	triggerall=var(50)=1 && ctrl && (pos y<-15) && (p2bodydist x=[-36,36]) && (p2bodydist y=[-45,25])
	trigger1=(gametime%240>120) && random<250

;---
; Super - Combos
;  - _j
[state 0]
	type=changestate
	value=3100
	triggerall=var(50)>1 && power>=1000
	trigger1=var(41) && random<20 && (gametime%80>60)
	trigger2=ctrl && p2statetype=a && (p2bodydist x=[-32,32]) && (p2bodydist y=[-32,0]) && random<100
	trigger3=(stateno=220||stateno=250||stateno=420) && var(41) && movehit && random<260

; Super - Dash
;  - SS
[state 0]
	type=changestate
	value=3000
	triggerall=var(50)>1 && power>=1000
	trigger1=(ctrl || var(41)) && (p2bodydist x=[-42,42]) && random<80 && (gametime%120=[60,65])

; Super - Air-Throw
;  - YV (󒆓)
[state 0]
	type=changestate
	value=3200
	triggerall=var(50)=1 && ctrl && power>=1000 && (pos y<-15) && (p2bodydist x=[-36,36]) && (p2bodydist y=[-45,25])
	trigger1=(gametime%320>180) && random<160

;---
; Throw - Super (Max2)
;  - _oA (Max2)
[state 0]
	type=changestate
	value=3400
	trigger1=var(50)>1 && ctrl && power>=2000
	trigger1=p2statetype!=a && p2movetype!=h && p2statetype!=l && (p2bodydist x=[-28,28])
	trigger1=random<(matchno+roundno+1)*88 && random<var(51)*98 ;*ntv

; Throw - Normal
; ʏ퓊
[state 0]
	type=changestate
	value=800
	trigger1=var(50)>1 && ctrl && (stateno!=[100,101])
	trigger1=p2statetype!=a && p2movetype!=h && p2statetype!=l && (p2bodydist x=[-13,13])
	trigger1=random<(matchno+roundno+1)*88 && random<var(51)*98 ;*ntv

;---
; Taunt
; 
[state 0]
	type=changestate
	value=195
	trigger1=var(50)>1 && ctrl && p2movetype=h && p2bodydist x>200 && random<50


;---------------
;---------------
;=========
; AI switch
[state 0]
	type=varset
	trigger1=(sysfvar(0)>0) && playeridexist(floor(sysfvar(0)))
	trigger1=playerid(floor(sysfvar(0))),stateno=90900 && var(51)!=playerid(floor(sysfvar(0))),var(51)
	var(51)=playerid(floor(sysfvar(0))),var(51)
;---
[state 0]
	type=varset
	trigger1=(sysvar(4)=0) && (matchno=1)
	var(51)=ailevel


;=========
;[EOF]
