@LabelIndex 142824
@StringIndex 18529
class 0 least_succubus : warrior_aggressive_casting_sleep_magic {
handler:
	EventHandler MY_DYING(always_list,code_info,i9,last_attacker,lparty,member,random1_list,target) {
		always_list = gg::AllocCodeInfoList();
		random1_list = gg::AllocCodeInfoList();
		target = last_attacker;
		if( gg::HaveMemo(target,3) == 1 && gg::OwnItemCount(target,1083) == 0 ) {
			random1_list::SetInfo(0,target);
		}
		if( gg::HaveMemo(target,3) == 1 && gg::OwnItemCount(target,1083) == 0 ) {
			random1_list::SetInfo(0,target);
		}
		if( gg::IsNull(lparty) == 0 ) {
			for(i9 = 0; i9 < lparty.member_count; i9++) {
				target = myself::GetMemberOfParty(lparty,i9);
				if( gg::HaveMemo(target,3) == 1 && gg::OwnItemCount(target,1083) == 0 ) {
					random1_list::SetInfo(0,target);
				}
			}
		}
		while( gg::IsNull(code_info = always_list::Next()) == 0 ) {
			switch (code_info.code) {
			}
		}
		code_info = random1_list::RandomSelectOne();
		if( gg::IsNull(code_info) == 0 ) {
			switch(code_info.code) {
				case 0: {
					myself::SetCurrentQuestID(3);
					target = code_info::RandomSelectOne();
					if( gg::IsNull(target) == 0 && myself::DistFromMe(target) <= 1500 ) {
						myself::GiveItem1(target,1083,1);
						myself::SoundEffect(target,"ItemSound.quest_middle");
						if( gg::OwnItemCount(target,1081) >= 1 && gg::OwnItemCount(target,1082) >= 1 ) {
							myself::SetFlagJournal(target,3,2);
							myself::ShowQuestMark(target,3);
						}
					}
					break;
				}
			}
		}
		super;
	}

}
