
//============================================================================
/**
 *
 *@file		sub_159.s
 *@brief	戦闘シーケンス
 *			いやしのねがい追加効果シーケンス
 *@author	HisashiSogabe
 *@data		2006.02.14
 *
 */
//============================================================================
	.text

	.include	"waza_seq_def.h"

SUB_159:
	PSP_VALUE				VAL_SET,SIDE_ATTACK,ID_PSP_hp,0
	//ゲージを0にする処理
	VALUE					VAL_SET,BUF_PARA_HP_CALC_WORK,JIBAKU_HP
	HP_GAUGE_CALC			SIDE_ATTACK
	GOSUB					SUB_SEQ_WAZA_OUT_EFF
	KIZETSU_CHECK			SIDE_ATTACK
	VALUE					VAL_NBIT,BUF_PARA_SERVER_STATUS_FLAG,SERVER_STATUS_FLAG_KIZETSU
	GOSUB					SUB_SEQ_KIZETSU
SUB_159_LOOP:
	RESHUFFLE_CHECK			SIDE_ATTACK,POKE_LIST_ON,SUB_159_END
	POKEMON_LIST
	POKEMON_LIST_WAIT
	POKEMON_RESHUFFLE		SIDE_RESHUFFLE
	KURIDASU_MESSAGE		SIDE_RESHUFFLE
	SERVER_WAIT
	POKEMON_APPEAR			SIDE_RESHUFFLE
	SERVER_WAIT
	HP_GAUGE_IN				SIDE_RESHUFFLE
	SERVER_WAIT
	GOSUB					SUB_SEQ_MAKIBISI_CHECK
	//気絶していたら、気絶エフェクトへ
	IF						IF_FLAG_NBIT,BUF_PARA_SERVER_STATUS_FLAG,SERVER_STATUS_FLAG_KIZETSU,SUB_159_NEXT
	GOSUB					SUB_SEQ_KIZETSU
	RESHUFFLE_CHECK			SIDE_ATTACK,POKE_LIST_ON,SUB_159_END
	BRANCH					SUB_159_LOOP
SUB_159_NEXT:
	PSP_VALUE				VAL_SET,SIDE_ATTACK,ID_PSP_condition,0
	STATUS_SET				SIDE_ATTACK,STATUS_NORMAL
	PSP_VALUE_WORK			VAL_GET,SIDE_ATTACK,ID_PSP_hpmax,BUF_PARA_HP_CALC_WORK
	VALUE_WORK				VAL_SET,BUF_PARA_CLIENT_WORK,BUF_PARA_ATTACK_CLIENT
	MESSAGE_PARAM			IyasinonegaiMsg,TAG_NONE
	GOSUB					SUB_SEQ_NEGAIGOTO
SUB_159_END:
	SEQ_END

