Server.Items.MonsterStatuette.OnMovement C# (CSharp) Method

OnMovement() public method

public OnMovement ( Mobile m, Point3D oldLocation ) : void
m Mobile
oldLocation Point3D
return void
		public override void OnMovement( Mobile m, Point3D oldLocation )
		{
			if ( m_TurnedOn && IsLockedDown && (!m.Hidden || m.AccessLevel == AccessLevel.Player) && Utility.InRange( m.Location, this.Location, 2 ) && !Utility.InRange( oldLocation, this.Location, 2 ) )
			{
				int[] sounds = MonsterStatuetteInfo.GetInfo( m_Type ).Sounds;

				if( sounds.Length > 0 )
					Effects.PlaySound( this.Location, this.Map, sounds[Utility.Random( sounds.Length )] );
			}

			base.OnMovement( m, oldLocation );
		}