class 1 sophia : citizen
{
handler:
	EventHandler TALK_SELECTED(fhtml0,i0,talker)
	{
		if( _from_choice == 0 )
		{
			if( myself::HaveMemo(talker,333) == 0 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 0;
				myself::AddChoice(0,"Hunt of the Black Lion");
			}
			if( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 0 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 1;
				myself::AddChoice(1,"Hunt of the Black Lion (Continue)");
			}
			if( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) < 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) < 1 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 2;
				myself::AddChoice(2,"Hunt of the Black Lion (Continue)");
			}
			if( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) < 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) >= 1 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 3;
				myself::AddChoice(3,"Hunt of the Black Lion (Continue)");
			}
			if( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) >= 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) == 0 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 4;
				myself::AddChoice(4,"Hunt of the Black Lion (Continue)");
			}
			if( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) >= 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) >= 1 )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 5;
				myself::AddChoice(5,"Hunt of the Black Lion (Continue)");
			}
			if( ( myself::HaveMemo(talker,42) == 1 && ( ( 1 == 1 && myself::OwnItemCount(talker,7549) >= 1 ) || 1 == 0 ) ) && myself::GetMemoState(talker,42) == ( ( 3 * 10 ) + 1 ) )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 6;
				myself::AddChoice(6,"Help My Uncle! (Continue)");
			}
			if( myself::HaveMemo(talker,42) == 1 && myself::GetMemoState(talker,42) == ( ( 4 * 10 ) + 1 ) )
			{
				_choiceN = ( _choiceN + 1 );
				_code = 7;
				myself::AddChoice(7,"Help My Uncle! (Continue)");
			}
			if( _choiceN > 1 )
			{
				myself::ShowChoicePage(talker,1);
				return;
			}
		}
		if( _from_choice || _choiceN == 1 )
		{
			switch(_code)
			{
				case 0:
				{
					if( _from_choice == 0 || myself::HaveMemo(talker,333) == 0 )
					{
						myself::SetCurrentQuestID(333);
						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;
						}
						if( myself::GetMemoCount(talker) < 26 )
						{
							if( talker.level < 25 )
							{
								myself::ShowPage(talker,"sophia_q0333_01.htm");
							}
							else if( talker.level >= 25 && myself::OwnItemCount(talker,1369) == 0 )
							{
								myself::ShowPage(talker,"sophia_q0333_02.htm");
							}
							else if( talker.level >= 25 && myself::OwnItemCount(talker,1369) == 1 )
							{
								myself::FHTML_SetFileName(fhtml0,"sophia_q0333_03.htm");
								myself::FHTML_SetInt(fhtml0,"quest_id",333);
								myself::ShowFHTML(talker,fhtml0);
							}
						}
						else
						{
							myself::ShowPage(talker,"fullquest.htm");
						}
					}
					break;
				}
				case 1:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 0 ) )
					{
						myself::SetCurrentQuestID(333);
						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,"sophia_q0333_14.htm");
					}
					break;
				}
				case 2:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) < 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) < 1 ) )
					{
						myself::SetCurrentQuestID(333);
						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,"sophia_q0333_15.htm");
					}
					break;
				}
				case 3:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) < 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) >= 1 ) )
					{
						myself::SetCurrentQuestID(333);
						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,"sophia_q0333_15a.htm");
					}
					break;
				}
				case 4:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) >= 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) == 0 ) )
					{
						myself::SetCurrentQuestID(333);
						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;
						}
						i0 = ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) );
						if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
						{
							if( i0 < 20 )
							{
							}
							else if( i0 < 50 )
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,1);
							}
							else if( i0 < 100 )
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,2);
							}
							else
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,3);
							}
							talker.quest_last_reward_time = myself::GetCurrentTick();
							myself::GiveItem1(talker,57,( ( ( ( myself::OwnItemCount(talker,3848) * 35 ) + ( myself::OwnItemCount(talker,3851) * 35 ) ) + ( myself::OwnItemCount(talker,3850) * 35 ) ) + ( myself::OwnItemCount(talker,3849) * 35 ) ));
							myself::DeleteItem1(talker,3848,myself::OwnItemCount(talker,3848));
							myself::DeleteItem1(talker,3849,myself::OwnItemCount(talker,3849));
							myself::DeleteItem1(talker,3850,myself::OwnItemCount(talker,3850));
							myself::DeleteItem1(talker,3851,myself::OwnItemCount(talker,3851));
							myself::ShowPage(talker,"sophia_q0333_22.htm");
							myself::SetMemoState(talker,333,0);
							myself::AddLog(3,talker,333);
						}
					}
					break;
				}
				case 5:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,333) == 1 && ( ( ( myself::OwnItemCount(talker,3671) + myself::OwnItemCount(talker,3672) ) + myself::OwnItemCount(talker,3673) ) + myself::OwnItemCount(talker,3674) ) == 1 && ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) ) >= 1 && ( ( ( myself::OwnItemCount(talker,3440) + myself::OwnItemCount(talker,3441) ) + myself::OwnItemCount(talker,3442) ) + myself::OwnItemCount(talker,3443) ) >= 1 ) )
					{
						myself::SetCurrentQuestID(333);
						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;
						}
						i0 = ( ( ( myself::OwnItemCount(talker,3848) + myself::OwnItemCount(talker,3849) ) + myself::OwnItemCount(talker,3850) ) + myself::OwnItemCount(talker,3851) );
						if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
						{
							if( i0 < 20 )
							{
							}
							else if( i0 < 50 )
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,1);
							}
							else if( i0 < 100 )
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,2);
							}
							else
							{
								talker.quest_last_reward_time = myself::GetCurrentTick();
								myself::GiveItem1(talker,3675,3);
							}
							talker.quest_last_reward_time = myself::GetCurrentTick();
							myself::GiveItem1(talker,57,( myself::OwnItemCount(talker,3848) * 35 ));
							myself::GiveItem1(talker,57,( myself::OwnItemCount(talker,3849) * 35 ));
							myself::GiveItem1(talker,57,( myself::OwnItemCount(talker,3850) * 35 ));
							myself::GiveItem1(talker,57,( myself::OwnItemCount(talker,3851) * 35 ));
							myself::DeleteItem1(talker,3848,myself::OwnItemCount(talker,3848));
							myself::DeleteItem1(talker,3849,myself::OwnItemCount(talker,3849));
							myself::DeleteItem1(talker,3850,myself::OwnItemCount(talker,3850));
							myself::DeleteItem1(talker,3851,myself::OwnItemCount(talker,3851));
							myself::ShowPage(talker,"sophia_q0333_23.htm");
							myself::SetMemoState(talker,333,0);
							myself::AddLog(3,talker,333);
						}
					}
					break;
				}
				case 6:
				{
					if( _from_choice == 0 || ( ( myself::HaveMemo(talker,42) == 1 && ( ( 1 == 1 && myself::OwnItemCount(talker,7549) >= 1 ) || 1 == 0 ) ) && myself::GetMemoState(talker,42) == ( ( 3 * 10 ) + 1 ) ) )
					{
						myself::SetCurrentQuestID(42);
						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::SetHTMLCookie(talker,42,3);
						myself::ShowPage(talker,"sophia_q0042_0301.htm");
					}
					break;
				}
				case 7:
				{
					if( _from_choice == 0 || ( myself::HaveMemo(talker,42) == 1 && myself::GetMemoState(talker,42) == ( ( 4 * 10 ) + 1 ) ) )
					{
						myself::SetCurrentQuestID(42);
						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,"sophia_q0042_0403.htm");
					}
					break;
				}
			}
			return;
		}
		super;
	}

	EventHandler QUEST_ACCEPTED(quest_id,talker)
	{
		if( quest_id == 333 )
		{
			myself::SetCurrentQuestID(333);
			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;
			}
			if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
			{
				talker.quest_last_reward_time = myself::GetCurrentTick();
				myself::SetMemo(talker,quest_id);
				myself::AddLog(1,talker,333);
				myself::SoundEffect(talker,"ItemSound.quest_accept");
				myself::ShowPage(talker,"sophia_q0333_04.htm");
			}
			return;
		}
		super;
	}

	EventHandler MENU_SELECTED(ask,i0,quest_id,reply,talker)
	{
		if( ask == 333 )
		{
			myself::SetCurrentQuestID(333);
			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;
			}
		}
		if( ask == 333 )
		{
			if( reply == 1 )
			{
				myself::ShowPage(talker,"sophia_q0333_05.htm");
			}
			if( reply == 2 )
			{
				myself::ShowPage(talker,"sophia_q0333_06.htm");
			}
			if( reply == 3 )
			{
				myself::ShowPage(talker,"sophia_q0333_07.htm");
			}
			if( reply == 4 )
			{
				myself::ShowPage(talker,"sophia_q0333_08.htm");
			}
			if( reply == 5 )
			{
				myself::ShowPage(talker,"sophia_q0333_09.htm");
			}
			if( reply == 6 )
			{
				if( myself::OwnItemCount(talker,3671) == 0 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3671,1);
						myself::ShowPage(talker,"sophia_q0333_10.htm");
					}
				}
			}
			if( reply == 7 )
			{
				if( myself::OwnItemCount(talker,3672) == 0 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3672,1);
						myself::ShowPage(talker,"sophia_q0333_11.htm");
					}
				}
			}
			if( reply == 8 )
			{
				if( myself::OwnItemCount(talker,3673) == 0 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3673,1);
						myself::ShowPage(talker,"sophia_q0333_12.htm");
					}
				}
			}
			if( reply == 9 )
			{
				if( myself::OwnItemCount(talker,3674) == 0 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3674,1);
						myself::ShowPage(talker,"sophia_q0333_13.htm");
					}
				}
			}
			if( reply == 10 )
			{
				if( myself::OwnItemCount(talker,3675) < 10 )
				{
					myself::ShowPage(talker,"sophia_q0333_16.htm");
				}
				else if( myself::OwnItemCount(talker,3675) >= 10 && myself::OwnItemCount(talker,3676) < 4 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3676,1);
						i0 = gg::Rand(100);
						if( i0 < 25 )
						{
							myself::GiveItem1(talker,1061,20);
						}
						else if( i0 < 50 )
						{
							if( myself::IsInCategory(0,talker.occupation) )
							{
								myself::GiveItem1(talker,1463,100);
							}
							else
							{
								myself::GiveItem1(talker,2510,50);
							}
						}
						else if( i0 < 75 )
						{
							myself::GiveItem1(talker,736,20);
						}
						else
						{
							myself::GiveItem1(talker,735,3);
						}
						myself::DeleteItem1(talker,3675,10);
						myself::ShowPage(talker,"sophia_q0333_17a.htm");
					}
				}
				else if( myself::OwnItemCount(talker,3675) >= 10 && myself::OwnItemCount(talker,3676) >= 4 && myself::OwnItemCount(talker,3676) <= 7 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,3676,1);
						i0 = gg::Rand(100);
						if( i0 < 25 )
						{
							myself::GiveItem1(talker,1061,25);
						}
						else if( i0 < 50 )
						{
							if( myself::IsInCategory(0,talker.occupation) )
							{
								myself::GiveItem1(talker,1463,200);
							}
							else
							{
								myself::GiveItem1(talker,2510,100);
							}
						}
						else if( i0 < 75 )
						{
							myself::GiveItem1(talker,736,20);
						}
						else
						{
							myself::GiveItem1(talker,735,3);
						}
						myself::DeleteItem1(talker,3675,10);
						myself::ShowPage(talker,"sophia_q0333_18b.htm");
					}
				}
				else if( myself::OwnItemCount(talker,3675) >= 10 && myself::OwnItemCount(talker,3676) >= 8 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						if( myself::OwnItemCount(talker,3676) > 8 )
						{
							myself::DeleteItem1(talker,3676,( myself::OwnItemCount(talker,3676) - 8 ));
						}
						i0 = gg::Rand(100);
						if( i0 < 25 )
						{
							myself::GiveItem1(talker,1061,50);
						}
						else if( i0 < 50 )
						{
							if( myself::IsInCategory(0,talker.occupation) )
							{
								myself::GiveItem1(talker,1463,400);
							}
							else
							{
								myself::GiveItem1(talker,2510,200);
							}
						}
						else if( i0 < 75 )
						{
							myself::GiveItem1(talker,736,30);
						}
						else
						{
							myself::GiveItem1(talker,735,4);
						}
						myself::DeleteItem1(talker,3675,10);
						myself::ShowPage(talker,"sophia_q0333_19b.htm");
					}
				}
			}
			if( reply == 11 )
			{
				if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
				{
					talker.quest_last_reward_time = myself::GetCurrentTick();
					myself::DeleteItem1(talker,3671,myself::OwnItemCount(talker,3671));
					myself::DeleteItem1(talker,3672,myself::OwnItemCount(talker,3672));
					myself::DeleteItem1(talker,3673,myself::OwnItemCount(talker,3673));
					myself::DeleteItem1(talker,3674,myself::OwnItemCount(talker,3674));
					myself::ShowPage(talker,"sophia_q0333_20.htm");
				}
			}
			if( reply == 12 )
			{
				myself::ShowPage(talker,"sophia_q0333_21.htm");
			}
			if( reply == 13 )
			{
				myself::ShowPage(talker,"sophia_q0333_24a.htm");
			}
			if( reply == 14 )
			{
				myself::ShowPage(talker,"sophia_q0333_25b.htm");
			}
			if( reply == 15 )
			{
				if( myself::OwnItemCount(talker,1369) >= 1 && myself::HaveMemo(talker,333) == 1 )
				{
					if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
					{
						talker.quest_last_reward_time = myself::GetCurrentTick();
						myself::GiveItem1(talker,57,12400);
						myself::DeleteItem1(talker,3675,myself::OwnItemCount(talker,3675));
						myself::DeleteItem1(talker,3676,myself::OwnItemCount(talker,3676));
						myself::DeleteItem1(talker,3677,myself::OwnItemCount(talker,3677));
						myself::DeleteItem1(talker,1369,myself::OwnItemCount(talker,1369));
						myself::DeleteItem1(talker,3671,myself::OwnItemCount(talker,3671));
						myself::DeleteItem1(talker,3672,myself::OwnItemCount(talker,3672));
						myself::DeleteItem1(talker,3673,myself::OwnItemCount(talker,3673));
						myself::DeleteItem1(talker,3674,myself::OwnItemCount(talker,3674));
						myself::ShowPage(talker,"sophia_q0333_26.htm");
						myself::RemoveMemo(talker,333);
						myself::AddLog(2,talker,333);
						myself::SoundEffect(talker,"ItemSound.quest_finish");
					}
				}
			}
		}
		if( ask == 42 )
		{
			myself::SetCurrentQuestID(42);
			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;
			}
		}
		if( ask == 42 )
		{
			i0 = myself::GetHTMLCookie(talker,42,( 4 - 1 ));
			if( i0 != -1 )
			{
				if( reply == 1 && myself::HaveMemo(talker,42) == 1 )
				{
					if( ( ( ( 1 == 1 && myself::OwnItemCount(talker,7549) >= 1 ) || 1 == 0 ) && ( ( 0 == 1 && myself::OwnItemCount(talker,0) >= 0 ) || 0 == 0 ) ) && ( ( 0 == 1 && myself::OwnItemCount(talker,0) >= 0 ) || 0 == 0 ) )
					{
						if( ( myself::GetCurrentTick() - talker.quest_last_reward_time ) > 1 )
						{
							talker.quest_last_reward_time = myself::GetCurrentTick();
							myself::DeleteItem1(talker,7549,1);
							myself::DeleteItem1(talker,0,0);
							myself::DeleteItem1(talker,0,0);
							myself::ShowPage(talker,"sophia_q0042_0401.htm");
							myself::SetMemoState(talker,42,( ( 4 * 10 ) + 1 ));
							myself::SetFlagJournal(talker,42,5);
						}
					}
					else
					{
						myself::ShowPage(talker,"sophia_q0042_0402.htm");
					}
				}
			}
		}
		super;
	}

}
