using System;
using System.Collections;
using Server.Items;
using Server.Targeting;
using Server.Misc;

namespace Server.Mobiles
{
	[CorpseName( "a goblin corpse" )]
	public class Goblin : BaseCreature
	{
		[Constructable]
		public Goblin() : base( AIType.AI_Melee, FightMode.Closest, 10, 1, 0.2, 0.4 )
		{
			Name = "a goblin";
			Body = 242;
			BaseSoundID = 0x5DA;
			Clan = Clan.Humanoid;

			SetStr( 55, 66 );
			SetDex( 25, 36 );
			SetInt( 10, 20 );

			SetHits( 45, 58 );

			SetDamage( 3, 9 );

			SetSkill( SkillName.MagicResist, 50.1, 75.0 );
			SetSkill( SkillName.Tactics, 55.1, 80.0 );
			SetSkill( SkillName.HandToHand, 50.1, 70.0 );

			Fame = 600;
			Karma = -600;

			VirtualArmor = 16;

			PackItem( new Buckler() );
			PackItem( new Hatchet() );
		}

		public override void GenerateLoot()
		{
			AddLoot( LootPack.Poor );
		}

		public override bool CanRummageCorpses{ get{ return true; } }
		public override int Meat{ get{ return 1; } }

		public Goblin( 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();
		}
	}
}