示例#1
0
        public override void OnDoubleClick(Mobile from)
        {
            if (TentCheck(from) == false)
            {
                from.SendMessage("You Already own a Tent");
            }
            else
            {

                if (IsChildOf(from.Backpack))
                {
                    if (Validate(from) == true)
                    {
                        TentWalls v = new TentWalls();
                        v.Location = from.Location;
                        v.Map = from.Map;

                        TentRoof w = new TentRoof();
                        w.Location = from.Location;
                        w.Map = from.Map;

                        TentFloor y = new TentFloor();
                        y.Location = from.Location;
                        y.Map = from.Map;

                        TentTrim z = new TentTrim();
                        z.Location = from.Location;
                        z.Map = from.Map;

                        TentVerifier tentverifier = new TentVerifier();
                        from.AddToBackpack(tentverifier);

                        SecureTent chest = new SecureTent((PlayerMobile)from);
                        chest.Location = new Point3D(from.X + 2, from.Y - 1, from.Z);
                        chest.Map = from.Map;

                        TentDestroyer x = new TentDestroyer(v, w, y, z, (PlayerMobile)from, (SecureTent)chest, (TentVerifier)tentverifier);
                        x.Location = new Point3D(from.X + 4, from.Y - 2, from.Z);
                        x.Map = from.Map;

                        from.SendGump(new TentGump(from));
                        this.Delete();
                    }
                    else
                    {
                        from.SendMessage("You cannot errect your Tent in this area.");
                    }
                }
                else
                {
                    from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it.
                }
            }
        }
示例#2
0
        public override void OnDoubleClick(Mobile from)
        {
            if (TentCheck(from) == false)
            {
                from.SendMessage("You Already own a Tent");
            }
            else
            {
                if (IsChildOf(from.Backpack))
                {
                    if (Validate(from) == true)
                    {
                        TentWalls v = new TentWalls();
                        v.Location = from.Location;
                        v.Map      = from.Map;

                        TentRoof w = new TentRoof();
                        w.Location = from.Location;
                        w.Map      = from.Map;

                        TentFloor y = new TentFloor();
                        y.Location = from.Location;
                        y.Map      = from.Map;

                        TentTrim z = new TentTrim();
                        z.Location = from.Location;
                        z.Map      = from.Map;

                        TentVerifier tentverifier = new TentVerifier();
                        from.AddToBackpack(tentverifier);

                        SecureTent chest = new SecureTent((PlayerMobile)from);
                        chest.Location = new Point3D(from.X + 2, from.Y - 1, from.Z);
                        chest.Map      = from.Map;

                        TentDestroyer x = new TentDestroyer(v, w, y, z, (PlayerMobile)from, (SecureTent)chest, (TentVerifier)tentverifier);
                        x.Location = new Point3D(from.X + 4, from.Y - 2, from.Z);
                        x.Map      = from.Map;

                        from.SendGump(new TentGump(from));
                        this.Delete();
                    }
                    else
                    {
                        from.SendMessage("You cannot errect your Tent in this area.");
                    }
                }
                else
                {
                    from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it.
                }
            }
        }
示例#3
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);
            int version = reader.ReadInt();

            m_TentTrim     = (TentTrim)reader.ReadItem();
            m_TentFloor    = (TentFloor)reader.ReadItem();
            m_TentWalls    = (TentWalls)reader.ReadItem();
            m_TentRoof     = (TentRoof)reader.ReadItem();
            m_Player       = (PlayerMobile)reader.ReadMobile();
            m_Chest        = (SecureTent)reader.ReadItem();
            m_TentVerifier = (TentVerifier)reader.ReadItem();
        }
示例#4
0
 public TentDestroyer(TentWalls tentwalls, TentRoof tentroof, TentFloor tentfloor, TentTrim tenttrim, PlayerMobile player, SecureTent chest, TentVerifier tentverifier)
 {
     Name           = player.Name + "'s tent carrying case";
     m_Player       = player;
     m_TentRoof     = tentroof;
     m_TentWalls    = tentwalls;
     m_TentFloor    = tentfloor;
     m_TentTrim     = tenttrim;
     m_Chest        = chest;
     m_TentVerifier = tentverifier;
     this.ItemID    = 2648;
     this.Visible   = true;
     Hue            = 696;
 }
示例#5
0
 public BedRoll1(TentWalls tentwalls, TentRoof tentroof, TentFloor tentfloor, TentTrim tenttrim, PlayerMobile player, SecureTent chest, TentVerifier tentverifier)
 {
     Name           = "A Sleeping Bag";
     m_Player       = player;
     m_TentRoof     = tentroof;
     m_TentWalls    = tentwalls;
     m_TentFloor    = tentfloor;
     m_TentTrim     = tenttrim;
     m_Chest        = chest;
     m_TentVerifier = tentverifier;
     this.ItemID    = 2645;
     this.Visible   = true;
     Hue            = 1072;
 }
示例#6
0
 public TentDestroyer(TentWalls tentwalls, TentRoof tentroof, TentFloor tentfloor, TentTrim tenttrim, PlayerMobile player, SecureTent chest, TentVerifier tentverifier)
 {
     Name = player.Name +"'s tent carrying case";
     m_Player = player;
     m_TentRoof = tentroof;
     m_TentWalls = tentwalls;
     m_TentFloor = tentfloor;
     m_TentTrim = tenttrim;
     m_Chest = chest;
     m_TentVerifier = tentverifier;
     this.ItemID = 2648;
     this.Visible = true;
     Hue = 696;
 }
 public TentDestroyer(TentWalls tentwalls, TentRoof tentroof, TentFloor tentfloor, TentTrim tenttrim, PlayerMobile player, SecureTent chest, TentVerifier tentverifier)
 {
     Name        = "A tent carrying bag";
     m_Player    = player;
     m_TentRoof  = tentroof;
     m_TentWalls = tentwalls;
     m_TentFloor = tentfloor;
     m_TentTrim  = tenttrim;
     m_Chest     = chest;
     if (tentverifier != null)
     {
         m_TentVerifier = tentverifier;
     }
     this.ItemID  = 2648;   // 2645;
     this.Visible = true;
     Hue          = 277;    // 1072;
 }
示例#8
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);
            int version = reader.ReadInt();

            m_TentTrim = (TentTrim)reader.ReadItem();
            m_TentFloor = (TentFloor)reader.ReadItem();
            m_TentWalls = (TentWalls)reader.ReadItem();
            m_TentRoof = (TentRoof)reader.ReadItem();
            m_Player = (PlayerMobile)reader.ReadMobile();
            m_Chest = (SecureTent)reader.ReadItem();
            m_TentVerifier = (TentVerifier)reader.ReadItem();
        }