Esempio n. 1
0
 public static void InvokeVirtueGumpRequest(VirtueGumpRequestEventArgs e)
 {
     if (VirtueGumpRequest != null)
     {
         VirtueGumpRequest(e);
     }
 }
Esempio n. 2
0
 public static void InvokeVirtueGumpRequest(VirtueGumpRequestEventArgs e)
 {
     if (EventSink.VirtueGumpRequest != null)
     {
         EventSink.VirtueGumpRequest.Invoke(e);
     }
 }
Esempio n. 3
0
        private static void EventSink_VirtueGumpRequest(VirtueGumpRequestEventArgs e)
        {
            Mobile beholder = e.Beholder;
            Mobile beheld   = e.Beheld;

            if (beholder == beheld && beholder.Kills >= 5)
            {
                beholder.SendLocalizedMessage(1049609);                   // Murderers cannot invoke this virtue.
            }
            else if (beholder.Map == beheld.Map && beholder.InRange(beheld, 12))
            {
                beholder.CloseGump(typeof(VirtueGump));
                beholder.SendGump(new VirtueGump(beholder, beheld));
            }
        }
Esempio n. 4
0
		private static void EventSink_VirtueGumpRequest( VirtueGumpRequestEventArgs e )
		{
			Mobile beholder = e.Beholder;
			Mobile beheld = e.Beheld;

			if ( beholder == beheld && beholder.Kills >= 5 )
			{
				beholder.SendLocalizedMessage( 1049609 ); // Murderers cannot invoke this virtue.
			}
			else if ( beholder.Map == beheld.Map && beholder.InRange( beheld, 12 ) )
			{
				beholder.CloseGump( typeof( VirtueGump ) );
				beholder.SendGump( new VirtueGump( beholder, beheld ) );
			}
		}
Esempio n. 5
0
 public static void InvokeVirtueGumpRequest( VirtueGumpRequestEventArgs e )
 {
     if ( VirtueGumpRequest != null )
         VirtueGumpRequest( e );
 }
Esempio n. 6
0
 public static void InvokeVirtueGumpRequest(VirtueGumpRequestEventArgs e)
 {
     VirtueGumpRequest?.Invoke(e);
 }
Esempio n. 7
0
		public static void InvokeVirtueGumpRequest(VirtueGumpRequestEventArgs e)
		{
			if (VirtueGumpRequest != null)
			{
				foreach (VirtueGumpRequestEventHandler currentDelegate in VirtueGumpRequest.GetInvocationList())
				{
					try
					{
						currentDelegate.Invoke(e);
					}
					catch (Exception ex)
					{
						// Log an exception
						EventSink.InvokeLogException(new LogExceptionEventArgs(ex));
					}
				}
			}
		}