using System;
using Server.Items;
using System.Collections;

namespace Server.Items
{
	public class SlayerLongbow : ElvenCompositeLongbow
	{
		public override int LabelNumber{ get{ return 1073506; } } // slayer longbow
		
		[Constructable]
		public SlayerLongbow() : base()
		{
			int sl = Utility.RandomMinMax( 1, 27 );
			
			if ( sl > 10 && sl < 14 )
			   sl = 14;
			   
         Slayer2 = (SlayerName) sl;
		}
		
// 		private static SlayerName GetRandomSlayer()
// 		{
// 			// TODO: Check random algorithm on OSI
// 
// 			SlayerGroup[] groups = SlayerGroup.Groups;
// 
// 			if ( groups.Length == 0 )
// 				return SlayerName.None;
// 
// 			SlayerGroup group = groups[Utility.Random( groups.Length )]; //-1 To Exclude the Fey Slayer which appears ONLY on a certain artifact.
// 			SlayerEntry entry;
// 
// 			if ( 10 > Utility.Random( 100 ) ) // 10% chance to do super slayer
// 			{
// 				entry = group.Super;
// 			}
// 			else
// 			{
// 				SlayerEntry[] entries = group.Entries;
// 
// 				if ( entries.Length == 0 )
// 					return SlayerName.None;
// 
// 				entry = entries[Utility.Random( entries.Length )];
// 			}
// 
// 			return entry.Name;
// 		}

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

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

			writer.WriteEncodedInt( 0 ); // version
		}

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

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