Inheritance: System.EventArgs
コード例 #1
0
 public static void InvokeGuildGumpRequest(GuildGumpRequestArgs e)
 {
     if (GuildGumpRequest != null)
     {
         GuildGumpRequest(e);
     }
 }
コード例 #2
0
ファイル: Guild.cs プロジェクト: Leodinas/uolite
        public static void EventSink_GuildGumpRequest( GuildGumpRequestArgs args )
        {
            PlayerMobile pm = args.Mobile as PlayerMobile;
            if( !NewGuildSystem || pm == null )
                return;

            if( pm.Guild == null )
                pm.SendGump( new CreateGuildGump( pm ) );
            else
                pm.SendGump( new GuildInfoGump( pm, pm.Guild as Guild ) );
        }
コード例 #3
0
ファイル: EventSink.cs プロジェクト: Godkong/Origins
 public static void InvokeGuildGumpRequest( GuildGumpRequestArgs e )
 {
     if( GuildGumpRequest != null )
         GuildGumpRequest( e );
 }
コード例 #4
0
        private static void EventSink_GuildGumpRequest(GuildGumpRequestArgs e)
        {
            Mobile beholder = e.Mobile;

            if (Core.SE)
            {
                Guild guild = beholder.Guild as Guild;

                if (beholder.Map == beholder.Map && beholder.InRange(beholder, 12))
                {
                    if (guild == null || guild.Disbanded)
                    {
                        beholder.CloseGump(typeof(JoinGuildGump));

                        beholder.SendGump(new JoinGuildGump(beholder, guild));
                    }
                    else if (guild.Accepted.Contains(beholder))
                    {
                        #region Factions
                        PlayerState guildState = PlayerState.Find(guild.Leader);

                        PlayerState targetState = PlayerState.Find(beholder);

                        Faction guildFaction = (guildState == null ? null : guildState.Faction);

                        Faction targetFaction = (targetState == null ? null : targetState.Faction);

                        if (guildFaction != targetFaction || (targetState != null && targetState.IsLeaving))
                        {
                            return;
                        }

                        if (guildState != null && targetState != null)
                        {
                            targetState.Leaving = guildState.Leaving;
                        }
                        #endregion

                        guild.Accepted.Remove(beholder);

                        guild.AddMember(beholder);

                        (beholder as PlayerMobile).GuildRank = 1;

                        beholder.CloseGump(typeof(SEGuildGump));

                        beholder.SendGump(new SEGuildGump(beholder, guild));
                    }
                    else
                    {
                        beholder.SendGump(new SEGuildGump(beholder, guild));
                    }
                }
            }
            else
            {
                beholder.SendLocalizedMessage(1063363);                   // * Requires the "Samurai Empire" expansion

                return;
            }
        }
コード例 #5
0
ファイル: Guild.cs プロジェクト: cynricthehun/UOLegends
        public static void EventSink_GuildGumpRequest( GuildGumpRequestArgs args )
        {
            if( !Core.SE )
                return;

            args.Mobile.SendMessage( "The new Guild system is not implemented yet" );
        }
コード例 #6
0
 public static void InvokeGuildGumpRequest(GuildGumpRequestArgs e)
 {
     GuildGumpRequest?.Invoke(e);
 }
コード例 #7
0
ファイル: EventSink.cs プロジェクト: zerodowned/angelisland
		public static void InvokeGuildGumpRequest(GuildGumpRequestArgs e)
		{
			if (GuildGumpRequest != null)
			{
				foreach (GuildGumpRequestHandler currentDelegate in GuildGumpRequest.GetInvocationList())
				{
					try
					{
						currentDelegate.Invoke(e);
					}
					catch (Exception ex)
					{
						// Log an exception
						EventSink.InvokeLogException(new LogExceptionEventArgs(ex));
					}
				}
			}
		}