public void Target( Mobile m )
		{
			if ( Caster == m )
			{
				Caster.SendLocalizedMessage( 1061832 ); // You cannot exact vengeance on yourself.
			}
			else if ( CheckHSequence( m ) )
			{
				SpellHelper.Turn( Caster, m );

				/* Summons a Revenant which haunts the target until either the target or the Revenant is dead.
				 * Revenants have the ability to track down their targets wherever they may travel.
				 * A Revenant's strength is determined by the Necromancy and Spirit Speak skills of the Caster.
				 * The effect lasts for ((Spirit Speak skill level * 80) / 120) + 10 seconds.
				 */

				TimeSpan duration = TimeSpan.FromSeconds( ((GetDamageSkill( Caster ) * 80) / 120) + 10 );

				Revenant rev = new Revenant( Caster, m, duration );

				if ( BaseCreature.Summon( rev, false, Caster, m.Location, 0x81, TimeSpan.FromSeconds( duration.TotalSeconds + 2.0 ) ) )
					rev.FixedParticles( 0x373A, 1, 15, 9909, EffectLayer.Waist );
			}

			FinishSequence();
		}
		public override void OnDamage(int amount, Mobile from, bool willKill)
		{
			if ( from != null )
                {
                                         if ( willKill == true )
		         {
				from.SendMessage( "Killing this pure and innocent creature has turned you into a criminal!" );
				from.Criminal = true;

				if ( Utility.Random( 5 ) < 1 )
				{
					Revenant rev = new Revenant( this, from, TimeSpan.FromSeconds( 180 ) );

					int x = from.X + Utility.RandomMinMax( -2, 2 );
					int y = from.Y + Utility.RandomMinMax( -2, 2 );
					int z = from.Z;

					Point3D loc = new Point3D( x, y ,z );

					rev.DamageMin = 16;
					rev.DamageMax = 20;
					rev.MoveToWorld( loc, from.Map );
					from.SendMessage( "A revenant has been sent to revenge the raindeer's death!" );
                                                      }
				}
			}

			base.OnDamage(amount, from, willKill);
		}
Esempio n. 3
0
        public override void OnDamage(int amount, Mobile from, bool willKill)
        {
            if (from != null)
            {
                if (willKill == true)
                {
                    from.SendMessage("Killing this pure and innocent creature has turned you into a criminal!");
                    from.Criminal = true;

                    if (Utility.Random(5) < 1)
                    {
                        Revenant rev = new Revenant(this, from, TimeSpan.FromSeconds(180));

                        int x = from.X + Utility.RandomMinMax(-2, 2);
                        int y = from.Y + Utility.RandomMinMax(-2, 2);
                        int z = from.Z;

                        Point3D loc = new Point3D(x, y, z);

                        rev.DamageMin = 16;
                        rev.DamageMax = 20;
                        rev.MoveToWorld(loc, from.Map);
                        from.SendMessage("A revenant has been sent to revenge the raindeer's death!");
                    }
                }
            }

            base.OnDamage(amount, from, willKill);
        }