Server.Items.Guildstone.OnDoubleClick C# (CSharp) Méthode

OnDoubleClick() public méthode

public OnDoubleClick ( Mobile from ) : void
from Mobile
Résultat void
		public override void OnDoubleClick( Mobile from )
		{
			if( m_Guild == null || m_Guild.Disbanded )
			{
				Delete();
			}
			else if( !from.InRange( GetWorldLocation(), 2 ) )
			{
				from.SendLocalizedMessage( 500446 ); // That is too far away.
			}
			else if( m_Guild.Accepted.Contains( from ) )
			{
				m_Guild.Accepted.Remove( from );
				m_Guild.AddMember( from );

				GuildGump.EnsureClosed( from );
				from.SendGump( new GuildGump( from, m_Guild ) );
			}
			else if( from.AccessLevel < AccessLevel.GameMaster && !m_Guild.IsMember( from ) )
			{
				from.Send( new MessageLocalized( Serial, ItemID, MessageType.Regular, 0x3B2, 3, 501158, "", "" ) ); // You are not a member ...
			}
			else
			{
				GuildGump.EnsureClosed( from );
				from.SendGump( new GuildGump( from, m_Guild ) );
			}
		}