Stop() 공개 메소드

public Stop ( ) : void
리턴 void
예제 #1
0
        private static void OnLoad()
        {
            Persistence.Deserialize(
                _FilePath,
                reader =>
            {
                var version = reader.ReadInt();
                var count   = reader.ReadInt();

                switch (version)
                {
                case 0:
                    {
                        for (var i = 0; i < count; ++i)
                        {
                            var sender   = reader.ReadMobile();
                            var message  = reader.ReadString();
                            var type     = (PageType)reader.ReadInt();
                            PageEntry pe = new PageEntry(sender, message, type)
                            {
                                Handler      = reader.ReadMobile(),
                                Sent         = reader.ReadDateTime(),
                                PageLocation = reader.ReadPoint3D(),
                                PageMap      = reader.ReadMap()
                            };
                            pe.Stop();

                            PageQueue.Enqueue(pe);
                        }
                    }
                    break;
                }
            });
        }
예제 #2
0
		private static void OnLoad()
		{
			Persistence.Deserialize(
				_FilePath,
				reader =>
				{
					var version = reader.ReadInt();
					var count = reader.ReadInt();

					switch (version)
					{
						case 0:
							{
								for (var i = 0; i < count; ++i)
								{
									var sender = reader.ReadMobile();
									var message = reader.ReadString();
									var type = (PageType)reader.ReadInt();
									PageEntry pe = new PageEntry(sender, message, type)
									{
										Handler = reader.ReadMobile(),
										Sent = reader.ReadDateTime(),
										PageLocation = reader.ReadPoint3D(),
										PageMap = reader.ReadMap()
									};
									pe.Stop();

									PageQueue.Enqueue(pe);
								}
							}
							break;
					}
				});
		}
예제 #3
0
        public static void Remove(PageEntry e)
        {
            if (e == null)
            {
                return;
            }

            e.Stop();

            m_List.Remove(e);
            m_KeyedBySender.Remove(e.Sender);

            if (e.Handler != null)
            {
                m_KeyedByHandler.Remove(e.Handler);
            }

            if (m_List.Count == 0)
            {
                foreach (NetState ns in GameServer.Instance.Clients)
                {
                    Mobile m = ns.Mobile;

                    if (m != null && m.AccessLevel >= AccessLevel.Counselor)
                    {
                        m.CloseGump <PagePendingGump>();
                    }
                }
            }
        }
예제 #4
0
        public static void Remove(PageEntry e)
        {
            if (e == null)
            {
                return;
            }

            e.Stop();

            m_List.Remove(e);
            m_KeyedBySender.Remove(e.Sender);

            if (e.Handler != null)
            {
                m_KeyedByHandler.Remove(e.Handler);
            }
        }
예제 #5
0
        private static void OnLoad()
        {
            Persistence.Deserialize(
                _FilePath,
                reader =>
            {
                int version = reader.ReadInt();

                switch (version)
                {
                case 1:
                    {
                        int c = reader.ReadInt();

                        for (int i = 0; i < c; ++i)
                        {
                            new ResponseEntry(reader);
                        }
                    }
                    goto case 0;

                case 0:
                    {
                        int count = reader.ReadInt();

                        for (int i = 0; i < count; ++i)
                        {
                            Mobile sender  = reader.ReadMobile();
                            string message = reader.ReadString();
                            PageType type  = (PageType)reader.ReadInt();
                            PageEntry pe   = new PageEntry(sender, message, type)
                            {
                                Handler      = reader.ReadMobile(),
                                Sent         = reader.ReadDateTime(),
                                PageLocation = reader.ReadPoint3D(),
                                PageMap      = reader.ReadMap()
                            };
                            pe.Stop();

                            PageQueue.Enqueue(pe);
                        }
                    }
                    break;
                }
            });
        }
예제 #6
0
        public static void Remove(PageEntry e)
        {
            if (e == null)
            {
                return;
            }

            Server.Admin.AdminNetwork.Distribute(new Server.Admin.RemovePage(e));

            e.Stop();

            m_List.Remove(e);
            m_KeyedBySender.Remove(e.Sender);

            if (e.Handler != null)
            {
                m_KeyedByHandler.Remove(e.Handler);
            }
        }
예제 #7
0
		public static void Remove( PageEntry e )
		{
			if ( e == null )
				return;

			e.Stop();

			m_List.Remove( e );
			m_KeyedBySender.Remove( e.Sender );

			if ( e.Handler != null )
				m_KeyedByHandler.Remove( e.Handler );
		}
예제 #8
0
        public static void Remove( PageEntry e )
        {
            if ( e == null )
                return;

            e.Stop();

            m_List.Remove( e );
            m_KeyedBySender.Remove( e.Sender );

            if ( e.Handler != null )
                m_KeyedByHandler.Remove( e.Handler );

            if ( m_List.Count == 0 )
            {
                foreach ( GameClient ns in GameServer.Instance.Clients )
                {
                    Mobile m = ns.Mobile;

                    if ( m != null && m.AccessLevel >= AccessLevel.Counselor )
                        m.CloseGump( typeof( PagePendingGump ) );
                }
            }
        }