Server.Items.Corpse.IsCriminalAction C# (CSharp) Méthode

IsCriminalAction() public méthode

public IsCriminalAction ( Server.Mobile from ) : bool
from Server.Mobile
Résultat bool
		public bool IsCriminalAction( Mobile from )
		{
			if ( from == m_Owner || from.AccessLevel >= AccessLevel.GameMaster )
				return false;

			Party p = Party.Get( m_Owner );

			if ( p != null && p.Contains( from ) )
			{
				PartyMemberInfo pmi = p[m_Owner];

				if ( pmi != null && pmi.CanLoot )
					return false;
			}

			return ( NotorietyHandlers.CorpseNotoriety( from, this ) == Notoriety.Innocent );
		}

Usage Example

 public static bool CanUseWithDeed(Mobile from, Corpse corpse)
 {
     if (corpse.IsCriminalAction(from))
     {
         from.SendMessage("You did not earn the right to use this creature in the deed.");
         return false;
     }
     else return true;
 }
All Usage Examples Of Server.Items.Corpse::IsCriminalAction