Example #1
0
 public NavWindow(GameObject.MapEntities.Actors.Player Player, Microsoft.Xna.Framework.Graphics.Texture2D tex)
 {
     this.WM          = Gameplay.WindowManager;
     this.Player      = Player;
     this.Width       = 276;
     this.Height      = 300;
     this.AnchorRight = true;
     Placename        = new GUI.Controls.RichTextDisplay("World", 256, 20, WM)
     {
         Y = 0,
         X = 4
     };
     GUI.Controls.TextureContainer texcont = new GUI.Controls.TextureContainer(tex, WM)
     {
         Y = 20,
         X = 4
     };
     Coords = new GUI.Controls.RichTextDisplay("loading...", 256, 20, WM)
     {
         Y = 280,
         X = 4
     };
     this.AddControl(texcont);
     this.AddControl(Placename);
     this.AddControl(Coords);
 }
Example #2
0
        public EquipWindow(GUI.WindowManager WM, GameObject.MapEntities.Actors.Player Player)
        {
            this.Width  = 400 + 6 + 6;
            this.Height = 400 + 6 + 16;
            this.Title  = "Equipment";
            this.X      = 400;
            this.Y      = 400;

            GUI.Controls.TextureContainer tx = new GUI.Controls.TextureContainer(Gameplay.Textures["equipdoll"], WM);
            this.AddControl(tx);

            int y = 0;
            int x = 0;

            Point[] slots = new Point[]
            {
                new Point(314, 83),
                new Point(50, 83),
                new Point(175, 129),
                new Point(175, 244),
                new Point(104, 105),
                new Point(180, 346),
                new Point(89, 35),
                new Point(180, 10),
                new Point(270, 35),
                new Point(180, 74),
                new Point(314, 126),
                new Point(135, 74),
                new Point(230, 74),
                new Point(72, 190),
                new Point(288, 190),
            };
            ItemSlot s;

            for (int i = 0; i < GameObject.Items.ItemEquip.EquipSlot.Max; i++)
            {
                s   = makeslot(i, Player);
                s.X = slots[i].X;
                s.Y = slots[i].Y;
                tx.AddControl(s);
            }
        }