class 1 lich_king_acron : warrior_aggressive
{
handler:
	EventHandler ATTACKED(attacker,c0,c1,i0,i1,npc0)
	{
		myself::SetCurrentQuestID(94);
		c1 = attacker;
		if( c1.master )
		{
			c1 = c1.master;
		}
		i0 = myself.sm.param3;
		if( i0 > 0 )
		{
			c0 = myself::Maker_FindNpcByKey(i0);
			if( c0 )
			{
				myself::AddAttackDesire(c0,1,100000);
			}
		}
		if( myself::HaveMemo(c1,94) == 1 && c1.occupation == 13 && ( myself::GetMemoState(c1,94) == 13 || myself::GetMemoState(c1,94) == 14 ) )
		{
			if( c1.is_pc == 1 )
			{
				if( c1.dbid == myself.sm.param2 )
				{
					myself.i_quest0 = ( myself.i_quest0 + 1 );
					if( myself.i_quest0 == 1 )
					{
						if( c1.is_pc == 1 )
						{
							myself::Say(myself::MakeFString(9466,c1.name,"","","",""));
						}
					}
					if( myself.i_quest0 > 15 )
					{
						myself::SetMemoState(c1,94,14);
						if( c1.is_pc == 1 )
						{
							myself::Say(myself::MakeFString(9467,c1.name,"","","",""));
						}
						c0 = myself::Maker_FindNpcByKey(myself.sm.param3);
						npc0 = gg::GetNPCFromID(c0.id);
						if( gg::IsNull(npc0) == 0 )
						{
							npc0.i_quest0 = 1;
						}
						myself::Despawn();
					}
				}
			}
		}
		super;
	}

	EventHandler TIMER_FIRED_EX(c0,i0,npc0,timer_id)
	{
		myself::SetCurrentQuestID(94);
		if( timer_id == 99906 )
		{
			i0 = myself.sm.param3;
			if( i0 > 0 )
			{
				c0 = myself::Maker_FindNpcByKey(i0);
				if( c0 )
				{
					myself::AddAttackDesire(c0,1,100000);
					myself::Say(myself::MakeFString(9464,"","","","",""));
				}
				else
				{
					myself::AddTimerEx(99906,500);
				}
			}
		}
		else if( timer_id == 99907 )
		{
			myself::Say(myself::MakeFString(9465,"","","","",""));
			c0 = myself::Maker_FindNpcByKey(myself.sm.param3);
			npc0 = gg::GetNPCFromID(c0.id);
			if( gg::IsNull(npc0) == 0 )
			{
				npc0.i_quest0 = 2;
			}
			myself::Despawn();
		}
		super;
	}

	EventHandler CREATED()
	{
		myself::SetCurrentQuestID(94);
		myself::AddTimerEx(99906,500);
		myself::AddTimerEx(99907,( 1000 * ( 60 - 1 ) ));
		super;
	}

}
