Example #1
0
        public Hud(GameObject parent)
            : base(parent)
        {
            crossHair = new GuiElement(this);
            crossHair.setSizePix(new Vector2(100, 100));
            crossHair.setMaterial("crosshair.xmf");

            fpsCounter = new HudNumber(this);
            fpsCounter.Position = new Vector2(0, -0.8f);
            fpsCounter.setSizePix(new Vector2(80, 160));
            fpsCounter.digits = 3;
        }
Example #2
0
        public Hud(GameObject parent)
            : base(parent)
        {
            crossHair = new GuiElement(this);
            crossHair.setSizeRel(new Vector2(100, 100));
            crossHair.setMaterial("crosshair.xmf");

            if (Settings.Instance.game.debugMode)
            {
                fpsCounter = new HudNumber(this);
                fpsCounter.Position = new Vector2(0, -0.8f);
                fpsCounter.setSizeRel(new Vector2(80, 160));
                fpsCounter.digits = 3;
            }
        }
Example #3
0
        public Hud(GameObject parent)
            : base(parent)
        {
            crossHair = new GuiElement(this);
            crossHair.setSizeRel(new Vector2(100, 100));
            crossHair.setMaterial("crosshair.xmf");

            if (Settings.Instance.game.debugMode)
            {
                fpsCounter          = new HudNumber(this);
                fpsCounter.Position = new Vector2(0, -0.8f);
                fpsCounter.setSizeRel(new Vector2(80, 160));
                fpsCounter.digits = 3;
            }
        }