Ejemplo n.º 1
0
        internal override void InitUI()
        {
            elapsedTime = 0;

            MouseCursor.State = MouseCursorState.Pointer;

            backgroundWindow = new MenuBackgroundWindow();
            mainMenuWindow   = new MainMenuWindow();

            textWindow = new UIWindow();
            UIImage img = new UIImage(WWTexture.FromImageResource("Text 'WarCraft'"));

            textWindow.AddComponent(img);
            textWindow.Height = img.Height;
        }
Ejemplo n.º 2
0
        internal override void InitUI()
        {
            base.InitUI();

            MouseCursor.State = MouseCursorState.None;

            UIWindow wnd = new UIWindow();

            img = new UIImage(WWTexture.FromImageResource("Background 'Blizzard'"));
            wnd.AddComponent(img);

            elapsedTime = 0;

            MainGame.SoundManager.PlaySound(472);
        }
Ejemplo n.º 3
0
        protected override void InitUI()
        {
            base.InitUI();

            MouseCursor = new MouseCursor(Game1.MainGame.SceneManager,
                                          new Cursor(new AlkaronEngine.Graphics2D.Texture(Game1.MainGame.SceneManager, Game1.MainGame.Content.Load <Texture2D>("cursor"))));

            UIWindow wnd = new UIWindow(Game1.MainGame.SceneManager);

            wnd.Show();

            UILabel label = new UILabel(Game1.MainGame.SceneManager, "Hello World!", Game1.MainGame.DefaultFont);

            label.PositionAnchor  = UIPositionAnchor.TopRight;
            label.BackgroundColor = Color.Red;
            label.Width           = 200;
            label.Height          = 20;
            wnd.AddComponent(label);
        }