/**********************************************************
RunUO 2.0 AoV C# script file
Official Age of Valor Script :: www.uovalor.com
Last modified by 
Filepath: scripts\_custom\items\Craftable artys\ml peerless\BladeOfAgony.cs
Lines of code: 73
***********************************************************/


using System;
using Server;

namespace Server.Items
{
	
	public class  BladeOfAgonyRecipe : BaseRecipe
	{
	
		[Constructable]
		public BladeOfAgonyRecipe()
		{
		}		
		
		//overrides:		
		public override Type CraftedItem { get { return typeof(BladeOfAgony); } }
		public override string artyname { get { return "Blade of Agony"; } }
		
		public override void InitRequirements()
		{
		base.InitRequirements(); //MUST be first! 
		
		//add required stuff
		
		RareResources.Add(new ReqRes("Pristine DreadHorn",typeof(PristineDreadHorn),1));
		RareResources.Add(new ReqRes("Dark Sapphire",typeof(DarkSapphire),25));
		RareResources.Add(new ReqRes("Scourge",typeof(Scourge),15));
		RareResources.Add(new ReqRes("Blight",typeof(Blight),10));
		CommonResources.Add(new ReqRes("Diamond",typeof(Diamond),50));
		CommonResources.Add(new ReqRes("Iron Ingot",typeof(IronIngot),12));
		}
			
		
		public BladeOfAgonyRecipe( Serial serial ) : base( serial )
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );		
			writer.Write( (int) 0 ); // version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );
			int version = reader.ReadInt();
		}	
	}	
		
	
	
	public class BladeOfAgony : Longsword
	{
		public override int InitMinHits{ get{ return 255; } }
		public override int InitMaxHits{ get{ return 255; } }

		[Constructable]
		public BladeOfAgony()
		{
			Hue = 1907;
			Name = "Blade of Agony";
			Attributes.WeaponSpeed = 40;
			HitSound = 0x2F7;
			WeaponAttributes.SelfRepair = 2;
			WeaponAttributes.HitLeechMana = 50;
			WeaponAttributes.HitLeechStam = 50;
			Attributes.RegenMana = 7;
			
			AosElementDamages.Physical=0;
			AosElementDamages.Fire=0;
			AosElementDamages.Cold=100;
			AosElementDamages.Poison=0;
			AosElementDamages.Energy=0;
			AosElementDamages.Chaos=0;			
		}


		public BladeOfAgony( Serial serial ) : base( serial )
		{
		}

		public override void Serialize( GenericWriter writer )
		{
			base.Serialize( writer );

			writer.Write( (int) 0 );
		}
		
		public override void Deserialize(GenericReader reader)
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();
		}
	}
}