̃́Adef_clc.luaJҗl̂ł͂܂B
th123_ait"document.txt"̌`^āA͈͂ŏ̂łB
鎩pƂłB



def_clc.luadl




EAPI
calculation()
	def_clc.luaŒ`Ăeϐ1FuɍXVB
		create_thread("calculation")
	Ƃ悤Ƀ}CNXbhƂĎŝgB
	Ӂ
	def_clc.luaŒ`ĂeϐE֐gpOɁAKcalculation}CNXbhƂĎsĂƁB
	sȂƁAeϐE֐𐳂gp邱ƂłȂB

biorhythm(rad1,rad2,F1,F2)
	ireact_wait֐pj
	battle_time𗘗p[Bϐbio_mathAF1,F2̒l傫قǊ֐l傫Ȃ₷B
	ۂ̊֐ĺǍvZœB
		math.floor( ((math.sin(math.rad(rad1)*battle_time))*F1 + math.floor((math.cos(math.rad(rad2)*battle_time))*F1) + F2)*bio_math/10000 )
	@Tv͎̒ʂB
		(֐l)  =  A*F1 + (B*F1 + F2)*C
		A,B,C͕ϐ
		-1  A  1
		-1  B  1
		 0  C  1
		A,B̒ĺuΐ펞ԁvbattle_time̒lŌiA=Bł͂Ȃj
		C̒ĺuƑ̍sߒvbio_math̒lŌ

react_wait(f)
	}BXCb`It̂ƂAKXfBCB
	fBC邩ǂAt[邩biorhythm֐̒lɈˑB
	f̒l傫قǃfBC\AfBCɂȂ₷B

key_resetEX()
	L[z[hɑΉkey_reset()Bz[h̃L[ȊOSăItɂB

my_spell_more(cost)
	Ŏw肵RXgJ[hQ[WĂ邩ǂiܓVljBRXg𖞂Ăΐ^B

card_check(card_ID)
	Ŏw肵J[hDɑ݂邩ǂBPł݂ΐ^B

card_1st(card_ID)
	Ŏw肵J[hD̈ԖڂɎĂB

card_use(card_ID)
	Ŏw肵J[hgpB

obj_coming_in(range)
	Ŏw肵͈́ijɁA֌ĂĂGIuWFNg݂邩ǂBPł݂ΐ^B

obj_range_in(range, ff)
	݂ffŎw肵t[ArangeŎw肵͈́i,jɁAUIuWFNg̔肪݂邩肷֐B







Eϐ
O[oϐ̈yield֐ĂԂтɁucalculation֐ōXVvϐQB
OIɁA݂̎dlł́ucalculation֐ōXVȂvϐꕔ݂B̒ɂ́Adef_clc.luåOœKXXVȂ΂ȂȂ݂̂B

Eϐꗗ
my_preactF
enemy_preactF
	ij̉ߋ̍s̃[Vl̔zBftHgŃTCY3600B

my_preframeF
enemy_preframeF
	ij̉ߋ̍s̃t[BftHgŃTCY3600B

my_allframeF
enemy_allframeF
	ij̍s̑t[B

old_btF
	1FObattle_timeB

RnI_BF
RnI_CF
	BiCj{^̃z[h󋵁B0Ńz[hȂA1Ńz[hB
	݂̎dlł́Acalculation֐ōXVȂBdef_clc.luåOœKXXVKvB
B_countF
C_countF
	BiCj{^̃z[hoߎԁB
	݂̎dlł́Acalculation֐ōXVȂBdef_clc.luåOœKXXVKvB
	
	gpi1t[̏jF13_iku_main.ai蔲
		--ȈՔŁF_̓{ێp
		if RnI_B==1 then
			B_count = B_count+1
		else
			B_count = 0
		end
		
		if RnI_C==1 then
			C_count = C_count+1
		else
			C_count = 0
		end
		
		if (my_act>=50 and my_act<=145) or
		(RnI_B==1 and get_key_stat(ACT_B)==0) or 
		(B_count>=300) then  
			RnI_B = 0
		end
		
		if (my_act>=50 and my_act<=145) or
		(RnI_C==1 and get_key_stat(ACT_C)==0) or
		(C_count>=300) then  
			RnI_C = 0
		end
		
		if (my_act>=50 and my_act<=166) or (my_act<300 and not(my_act>=50 and my_act<=199) and enemy_act>=300 and enemy_act<400) then
			if RnI_B==1 then
				key_off(ACT_B);
			end
			if RnI_C==1 then
				key_off(ACT_C);
			end
		end
	
	gpiz[hs̏jF13_iku_main.ai蔲
		print("a_̓{");
		key_resetEX();
		key_resetEX();
		lvr22h(ACT_B);
		wait(2);
		RnI_B = 1
		B_count = 0


old_xF
old_exF
	1FÓiejxB

my_xspeedEXF
enemy_xspeedEXF
	(ene)my_xspeedɑAZ瓱ꂽijxxB

old_m_ysF
old_e_ysF
	1FO̎ijyxB

m_gsF
e_gsF
	1FO̎ij̏d͉xB

old_obj_disF
	1FOobj_disB

obj_speedEXF
	Z瓱ꂽIuWFNgxB

obj_disEXF
	obj_disɑAZ瓱ꂽɍł߂G_[ẄʒuB

old_obj_disEXF
	1FOobj_disEXB
	݂̎dlł͎gpłȂAĂȂB

enemy_hitarea_rightF
enemy_hitarea_leftF
enemy_hitarea_topF
enemy_hitarea_bottomF
	̋炢̉Ei,,j[̔zBftHgŃTCY10B

pre0_enemy_obj_nF
	1FOenemy_obj_nB

true_mathF
	(caution_state_obj֐pϐ)
	̎͂ɑ݂ÃIuWFNǧBcaution_state_obj֐sÅ֐ltrue_mathɋLB
	calculation֐ōXVȂBcaution_state_obj֐ŝݍXVB

bio_mathF
	(biorhythm֐pϐ)
	XCb`It̂ƂA݂ȂxBcalculation֐ōXVBbio_math̒l傫ԂقǁA݂Ȃ₷B

graund_mathF
air_mathF
	肪AĒni󒆁jɋt[B

enemy_obj_actF
enemy_obj_xF
enemy_obj_yF
enemy_obj_hpF
enemy_obj_imgF
enemy_obj_frameF
enemy_obj_xspeedF
enemy_obj_yspeedF
enemy_obj_idF
enemy_obj_attackarea_nF
enemy_obj_hit_nF
	̃IuWFNgf[^̔zBftHgŃTCY1024B
	ꂼget_obj_data֐̊e߂lɑΉĂB
	calculation֐Ŏ̂悤ɍXVB
		for i=0,enemy_obj_n-1,1 do
			enemy_obj_act[i],enemy_obj_x[i],enemy_obj_y[i],enemy_obj_hp[i],enemy_obj_img[i],enemy_obj_frame[i],enemy_obj_xspeed[i],enemy_obj_yspeed[i],enemy_obj_id[i],enemy_obj_attackarea_n[i],enemy_obj_hit_n[i] = get_obj_data(1,i);
		end

pre0_enemy_obj_actF
pre0_enemy_obj_xF
pre0_enemy_obj_yF
pre0_enemy_obj_hpF
pre0_enemy_obj_imgF
pre0_enemy_obj_frameF
pre0_enemy_obj_xspeedF
pre0_enemy_obj_yspeedF
pre0_enemy_obj_idF
pre0_enemy_obj_attackarea_nF
pre0_enemy_obj_hit_nF
	1FȎ̃IuWFNgf[^̔zBftHgŃTCY1024B
	ꂼenemy_obj_act,c,enemy_obj_hit_nɑΉĂB

enemy_obj_attackarea_leftF
enemy_obj_attackarea_topF
enemy_obj_attackarea_rightF
enemy_obj_attackarea_bottomF
	̊eIuWFNg̍U̍i,E,j[W̔zBftHgŃTCY1024B
	CfNXɒӁBuiԖڂ̃IuWFNgnԖڂ̍Uv̏ꍇAui*100+nvŎQƂB
	calculation֐Ŏ̂悤ɍXVB
		for i=0,enemy_obj_n-1,1 do
			for n=0,enemy_obj_attackarea_n[i]-1,1 do
				enemy_obj_attackarea_left[(i+1)*100+(n+1)],enemy_obj_attackarea_top[(i+1)*100+(n+1)],enemy_obj_attackarea_right[(i+1)*100+(n+1)],enemy_obj_attackarea_bottom[(i+1)*100+(n+1)] = get_obj_attackarea(1,i,n);
			end
		end

enemy_obj_xaccelF
enemy_obj_yaccelF
	̊eIuWFNgxiyjx̔zBftHgŃTCY1024B

countDF
	ėpJEgBăR}h͂̌o߃t[B
	݂̎dlł́Acalculation֐ōXVȂBdef_clc.luåOœKXXVKvB
	gpF07_yuyuko_main.ai蔲
		key_resetEX();
		countD = 0;
		key_on(ACT_D);
		key_on(u_back);
		while countD<=30 and not((enemy_act==306 and dis<=200 and dis_y<=100 and is_dir_front) or (enemy_act==307 and dis<=400 and dis_y<=150 and is_dir_front) or (enemy_act==309 and dis<=200 and ey<=y-150)) do
			countD = countD +1;
			yield();
		end
		countD = 0;
		key_on(front);
		while countD<=20 and not((enemy_act==306 and dis<=200 and dis_y<=100 and is_dir_front) or (enemy_act==307 and dis<=400 and dis_y<=150 and is_dir_front) or (enemy_act==309 and dis<=200 and ey<=y-150)) do
			countD = countD +1;
			yield();
		end
		countD = 0;
		key_resetEX();


after_guard_countF
	K[h̃JEgBK[hJnɍől60ɏBK[hpŒl-1iŏl1jB


loop_countF
	while[ṽ[vJEgB
	݂̎dlł͎gpłȂAĂȂB

my_backsideF
enemy_backsideF
	iǰʒ[܂ł̋B

my_airEXF
enemy_airEXF
	ijgpłāE󒆃_bV̎c񐔁B
	ienejmy_air͎ijnォ󒆂ɍsĂāE󒆃_bVgp񐔁B

recovary_timeF
	isj

flag_kishituF
	užvgptOB
	0ŉȂA1ŁužvgpA2Łužv

atk_countF
shoot_countF
	Ag̑ŌEˌsϋɐBlقǐϋɓIɑŌEˌsƂB
	̐K[hɑ΂đŌAK[hɑ΂Ďˌ_B

datk_countF
	_bVU𑊎ɃK[h񐔁B

break_waitF
	(react_wait֐pϐ)
	l0Breact_wait֐yield[visҋ@jrbreakꍇAreact_wait֐I1̒lƂB
	݂̎dlł́Areact_wait֐ycalculation֐0ɏȂBdef_clc.luåOœKXKvB
	

