@LabelIndex 259438
@StringIndex 32738
class 0 trader_arodin : merchant_for_newbie {
property:
	BuySellList SellList0 = {{"long_sword";20};{"throw_knife";20};{"bow_of_forest";20};{"short_spear";20};{"falchion";20};{"sword_breaker";20};{"composition_bow";20};{"buzdygan";20};{"morning_star";20};{"iron_hammer";20};{"long_spear";20};{"saber";20};{"steel_sword";20};{"handiwork_dagger";20};{"assassin_knife";20};{"strengthening_bow";20};{"hand_axe";20};{"heavy_mace";20};{"work_hammer";20};{"trident";20};{"bastard_sword";20};{"poniard_dagger";20};{"long_bow";20};{"dark_elven_bow";20};{"pike";20};{"dwarven_trident";20};{"cestus";20};{"viper_s_canine";20};{"bagh-nakh";20};{"single-edged_jamadhr";20}};
	BuySellList SellList1 = {{"apprentice_s_staff";20};{"relic_of_saints";20};{"mage_staff";20};{"crucifix_of_blessing";20};{"voodoo_doll";20};{"bone_staff";20};{"scroll_of_wisdom";20};{"priest_sword";20};{"branch_of_life";20};{"proof_of_revenge";20};{"mace_of_prayer";20};{"doom_hammer";20};{"mystic_staff";20};{"staff_of_mana";20};{"divine_tome";20};{"sword_of_magic";20};{"sword_of_mystic";20};{"sword_of_occult";20};{"dagger_of_mana";20};{"mystic_knife";20};{"conjure_knife";20}};
	BuySellList SellList4 = {{"11614";20};{"11605";20};{"11613";20};{"11617";20};{"11606";20};{"11623";20};{"11626";20};{"11618";20};{"11622";20};{"11635";20};{"11646";20};{"11632";20};{"11629";20};{"11647";20};{"11631";20};{"11608";20};{"11642";20}};
	BuySellList SellList5 = {{"11610";20};{"11619";20};{"11611";20};{"11612";20};{"11609";20};{"11627";20};{"11630";20};{"11634";20};{"11633";20};{"11637";20};{"11655";20};{"11656";20};{"11657";20};{"11662";20};{"11664";20};{"11672";20}};

handler:
	EventHandler TALK_SELECTED(fhtml0,talker) {
		if( _from_choice == 0 ) {
			if( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 1 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) {
				_choiceN = ( _choiceN + 1 );
				_code = 0;
				myself::AddChoice(0,"Acts of Evil (In Progress)");
			}
			if( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 2 && gg::OwnItemCount(talker,4239) < 20 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) {
				_choiceN = ( _choiceN + 1 );
				_code = 1;
				myself::AddChoice(1,"Acts of Evil (In Progress)");
			}
			if( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 2 && gg::OwnItemCount(talker,4239) >= 20 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) {
				_choiceN = ( _choiceN + 1 );
				_code = 2;
				myself::AddChoice(2,"Acts of Evil (In Progress)");
			}
			if( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 3 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) {
				_choiceN = ( _choiceN + 1 );
				_code = 3;
				myself::AddChoice(3,"Acts of Evil (In Progress)");
			}
			if( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) >= 4 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) {
				_choiceN = ( _choiceN + 1 );
				_code = 4;
				myself::AddChoice(4,"Acts of Evil (In Progress)");
			}
			if( _choiceN > 1 ) {
				myself::ShowChoicePage(talker,1);
				return;
			}
		}
		if( _from_choice || _choiceN == 1 ) {
			switch(_code) {
				case 0: {
					if( _from_choice == 0 || ( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 1 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) ) {
						myself::SetCurrentQuestID(171);
						if( myself::GetInventoryInfo(talker,0) >= ( myself::GetInventoryInfo(talker,1) * 0.800000 ) || myself::GetInventoryInfo(talker,2) >= ( myself::GetInventoryInfo(talker,3) * 0.800000 ) ) {
							myself::ShowSystemMessage(talker,1118);
							return;
						}
						myself::SetMemoState(talker,171,2);
						myself::SetFlagJournal(talker,171,2);
						myself::ShowQuestMark(talker,171);
						myself::SoundEffect(talker,"ItemSound.quest_middle");
						myself::ShowPage(talker,"trader_arodin_q0171_01.htm");
					}
					break;
				}
				case 1: {
					if( _from_choice == 0 || ( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 2 && gg::OwnItemCount(talker,4239) < 20 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) ) {
						myself::SetCurrentQuestID(171);
						if( myself::GetInventoryInfo(talker,0) >= ( myself::GetInventoryInfo(talker,1) * 0.800000 ) || myself::GetInventoryInfo(talker,2) >= ( myself::GetInventoryInfo(talker,3) * 0.800000 ) ) {
							myself::ShowSystemMessage(talker,1118);
							return;
						}
						myself::ShowPage(talker,"trader_arodin_q0171_02.htm");
					}
					break;
				}
				case 2: {
					if( _from_choice == 0 || ( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 2 && gg::OwnItemCount(talker,4239) >= 20 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) ) {
						myself::SetCurrentQuestID(171);
						if( myself::GetInventoryInfo(talker,0) >= ( myself::GetInventoryInfo(talker,1) * 0.800000 ) || myself::GetInventoryInfo(talker,2) >= ( myself::GetInventoryInfo(talker,3) * 0.800000 ) ) {
							myself::ShowSystemMessage(talker,1118);
							return;
						}
						myself::ShowPage(talker,"trader_arodin_q0171_03.htm");
					}
					break;
				}
				case 3: {
					if( _from_choice == 0 || ( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) == 3 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) ) {
						myself::SetCurrentQuestID(171);
						if( myself::GetInventoryInfo(talker,0) >= ( myself::GetInventoryInfo(talker,1) * 0.800000 ) || myself::GetInventoryInfo(talker,2) >= ( myself::GetInventoryInfo(talker,3) * 0.800000 ) ) {
							myself::ShowSystemMessage(talker,1118);
							return;
						}
						myself::DeleteItem1(talker,4240,gg::OwnItemCount(talker,4240));
						myself::SetMemoState(talker,171,4);
						myself::SetFlagJournal(talker,171,4);
						myself::ShowQuestMark(talker,171);
						myself::SoundEffect(talker,"ItemSound.quest_middle");
						myself::ShowPage(talker,"trader_arodin_q0171_04.htm");
					}
					break;
				}
				case 4: {
					if( _from_choice == 0 || ( gg::HaveMemo(talker,171) == 1 && gg::GetMemoState(talker,171) >= 4 && myself::GetOneTimeQuestFlag(talker,171) == 0 ) ) {
						myself::SetCurrentQuestID(171);
						if( myself::GetInventoryInfo(talker,0) >= ( myself::GetInventoryInfo(talker,1) * 0.800000 ) || myself::GetInventoryInfo(talker,2) >= ( myself::GetInventoryInfo(talker,3) * 0.800000 ) ) {
							myself::ShowSystemMessage(talker,1118);
							return;
						}
						myself::ShowPage(talker,"trader_arodin_q0171_05.htm");
					}
					break;
				}
			}
			return;
		}
		super;
	}

}
