Exemplo n.º 1
0
        public override void OnDoubleClickSecureTrade(Mobile from)
        {
            if (!from.InRange(this.GetWorldLocation(), 2))
            {
                from.SendLocalizedMessage(500446); // That is too far away.
            }
            else if (this.m_Entries.Count == 0)
            {
                from.SendLocalizedMessage(1062381); // The book is empty.
            }
            else
            {
                from.SendGump(new BOBGump((PlayerMobile)from, this));

                SecureTradeContainer cont = this.GetSecureTradeCont();

                if (cont != null)
                {
                    SecureTrade trade = cont.Trade;

                    if (trade != null && trade.From.Mobile == from)
                    {
                        trade.To.Mobile.SendGump(new BOBGump((PlayerMobile)(trade.To.Mobile), this));
                    }
                    else if (trade != null && trade.To.Mobile == from)
                    {
                        trade.From.Mobile.SendGump(new BOBGump((PlayerMobile)(trade.From.Mobile), this));
                    }
                }
            }
        }
 // Methods
 public SecureTradeInfo(SecureTrade owner, Mobile m, SecureTradeContainer c)
 {
     this.m_Owner     = owner;
     this.m_Mobile    = m;
     this.m_Container = c;
     this.m_Mobile.AddItem(this.m_Container);
 }
Exemplo n.º 3
0
        public override void OnDoubleClickSecureTrade(Mobile from)
        {
            if (!from.InRange(GetWorldLocation(), 2))
            {
                from.LocalOverheadMessage(MessageType.Regular, 0x3B2, 1019045); // I can't reach that.
            }
            else if (m_Entries.Count == 0)
            {
                from.SendLocalizedMessage(1062381); // The book is empty.
            }
            else
            {
                from.SendGump(new BOBGump((PlayerMobile)from, this));

                SecureTradeContainer cont = GetSecureTradeCont();

                if (cont != null)
                {
                    SecureTrade trade = cont.Trade;

                    if (trade != null && trade.From.Mobile == from)
                    {
                        trade.To.Mobile.SendGump(new BOBGump((PlayerMobile)(trade.To.Mobile), this));
                    }
                    else if (trade != null && trade.To.Mobile == from)
                    {
                        trade.From.Mobile.SendGump(new BOBGump((PlayerMobile)(trade.From.Mobile), this));
                    }
                }
            }
        }
Exemplo n.º 4
0
        public SecureTradeInfo(SecureTrade owner, Mobile m, SecureTradeContainer c)
        {
            m_Owner     = owner;
            m_Mobile    = m;
            m_Container = c;

            m_Mobile.AddItem(m_Container);
        }
Exemplo n.º 5
0
        public SecureTradeInfo(SecureTrade owner, Mobile m, SecureTradeContainer c)
        {
            Owner     = owner;
            Mobile    = m;
            Container = c;

            Mobile.AddItem(Container);
        }
Exemplo n.º 6
0
        public SecureTradeInfo(SecureTrade owner, Mobile m, SecureTradeContainer c)
        {
            Owner     = owner;
            Mobile    = m;
            Container = c;

            Mobile.AddItem(Container);

            VirtualCheck = new VirtualCheck(0, 0);
            Container.DropItem(VirtualCheck);
        }