Resource icon

HermanTheCrafter

Code:
/*
*  Scripter : Jezika
*  Created at :  7/12/2013 12:39:37 PM
*/
using System;
using Server;
using Server.Items;
using Server.Mobiles;

namespace Server.Mobiles
{
    [CorpseName( "Herman" )]
    public class Herman : BaseCreature
    {
        [Constructable]
        public Herman() : base( AIType.AI_Melee, FightMode.Aggressor, 10, 1, 0.6, 0.4 )
        {
            this.Name = "Ghost of Herman The Crafter";
            this.Hue = 2032;
            this.Body = 146;
            this.BaseSoundID = 163;

	    PackItem( new WarHammer() );

            this.SetStr( 200 );
            this.SetDex( 135 );
            this.SetInt( 120 );
            this.SetHits( 250000 );
            this.SetDamage( 150, 200 );
            this.SetDamageType( ResistanceType.Physical, 20 );
            this.SetDamageType( ResistanceType.Cold, 20 );
            this.SetDamageType( ResistanceType.Fire, 20 );
            this.SetDamageType( ResistanceType.Energy, 20 );
            this.SetDamageType( ResistanceType.Poison, 20 );
            this.SetResistance( ResistanceType.Physical, 60 );
            this.SetResistance( ResistanceType.Cold, 50 );
            this.SetResistance( ResistanceType.Fire, 50 );
            this.SetResistance( ResistanceType.Energy, 50 );
            this.SetResistance( ResistanceType.Poison, 50 );
            this.Fame = 15000;
            this.VirtualArmor = 20;

			SetSkill( SkillName.Anatomy, 120.0 );
			SetSkill( SkillName.Fencing, 100.0, 120.0 );
			SetSkill( SkillName.Macing, 135.0, 157.5 );
			SetSkill( SkillName.Wrestling, 135.0, 157.5 );
			SetSkill( SkillName.MagicResist, 83.5, 92.5 );
			SetSkill( SkillName.Swords, 125.0 );
			SetSkill( SkillName.Tactics, 125.0 );
			SetSkill( SkillName.Lumberjacking, 125.0 );
        }

        public override bool AutoDispel{ get{ return true; } }
        public override bool BardImmune{ get{ return true; } }
		public override bool Uncalmable{ get{ return true; } }
        public override bool Unprovokable{ get{ return true; } }

		public override void OnDeath( Container c )
		{
			base.OnDeath( c );

            c.DropItem( new Gold(3500));}

public override void GenerateLoot()
		{
			

			
			if (Utility.Random(100) < 98)
            		{

                		int level;

                		double random = Utility.RandomDouble();

                		if (0.025 >= random)
                    		level = 120;

                		else
                    		level = 115;

                		switch (Utility.Random(7))
                		{
                    			case 0: AddToBackpack(new PowerScroll(SkillName.Blacksmith, level)); break;
                    			case 1: AddToBackpack(new PowerScroll(SkillName.Tailoring, level)); break;
                    			case 2: AddToBackpack(new PowerScroll(SkillName.Carpentry, level)); break;
                    			case 3: AddToBackpack(new PowerScroll(SkillName.Tinkering, level)); break;
					case 4: AddToBackpack(new PowerScroll(SkillName.Alchemy, level)); break;
					case 5: AddToBackpack(new PowerScroll(SkillName.Inscribe, level)); break;
					case 6: AddToBackpack(new PowerScroll(SkillName.Fletching, level)); break;
					
                		}
            		}
			
		}






		public override WeaponAbility GetWeaponAbility()
		{
			switch ( Utility.Random(3 ) )
			{
				default:
                case 0: return WeaponAbility.Dismount;
                case 1: return WeaponAbility.DoubleStrike;
                case 2: return WeaponAbility.BleedAttack;
            }
        }

        public Herman( 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();
        }
    }
}
Author
Jezika
Views
307
First release
Last update
Rating
0.00 star(s) 0 ratings