Example #1
0
        void GEInvalidate()
        {
            while (GraphicsDrawing.Running)
            {
                //Refreshes graphics
                Canvas.Invalidate();
                PanelMenu.Invalidate();

                //Loop Delay
                Thread.Sleep(GraphicsDrawing.GraphicsFrameDelay);
            }
        }
Example #2
0
        private void FrmanageItems_Load(object sender, EventArgs e)
        {
            _ = new PanelMenu(panel2, btnhide, 34, panel2.Width);
            FrmItemView view = new FrmItemView(client.ps.Live.Items, splitContainer2.Panel2);
            FormHandle  form = new FormHandle();

            form.OpenForm(splitContainer1.Panel1, view, FormBorderStyle.None, DockStyle.Fill);
            Settings.LoadCtrlSettings(this);

            this.panel1.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
            this.panel2.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
        }
Example #3
0
 void mostrarmenu()
 {
     if (botonO == 0)
     {
         PanelMenu.Hide();
         btnMenu2.Show();
         botonO = 1;
     }
     else
     {
         PanelMenu.Show();
         botonO = 0;
         btnMenu2.Hide();
     }
 }
Example #4
0
    private void Start()
    {
        // PanelFade
        Fader.FadeOut();

        // ButtonMenu
        Transform _ObjButton = Canvas.transform.Find(NAME_BUTTON_MENU);

        if (_ObjButton == null)
        {
            Debug.Log("require " + NAME_BUTTON_MENU + " gameobject");
            return;
        }

        m_ButtonMenu = _ObjButton.GetComponent <MyButton>();
        if (m_ButtonMenu == null)
        {
            Debug.Log("require MyButton component");
            return;
        }

        // PanelMenu
        Transform _Menu = Canvas.transform.Find(NAME_PANEL_MENU);

        if (_Menu == null)
        {
            Debug.Log("require " + NAME_PANEL_MENU + " gameobject");
            return;
        }

        m_PanelMenu = _Menu.GetComponent <PanelMenu>();
        if (m_PanelMenu == null)
        {
            Debug.Log("require PanelMenu component");
            return;
        }

        m_ButtonMenu.RxOnClick.Subscribe(_ => {
            m_ButtonMenu.Inactive();
            m_PanelMenu.Active();
        }).AddTo(this);

        m_PanelMenu.RxClose.Subscribe(_ => {
            InactiveMenu();
        }).AddTo(this);

        InactiveMenu();
    }
Example #5
0
    public void GameOver(int finalScore, bool died)
    {
        playerDied = died;
        StartCoroutine(WaitFor(1, () =>
        {
            // Setup and show success / fail menu
            PanelMenu pm = MenuManager._instance.ShowScreen(retryScreenPrefab);
            pm.Panel.gameObject.GetComponent <WinMenu>().SetupMenu(finalScore, 3, died);

            // Animate stars after the menu has been shown
            StartCoroutine(WaitFor(0.5f, () =>
            {
                pm.Panel.gameObject.GetComponent <WinMenu>().GrantStars(finalScore);
            }));
        }));
    }
        private void FrmQuickSale_Load(object sender, EventArgs e)
        {
            Settings.LoadCtrlSettings(this);
            PanelMenu panelMenu = new PanelMenu(panel1, btnhide, 34, panel1.Width);

            this.panel1.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
            this.panel3.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;

            #region ContextMenu
            cm.Items.Add("Edit", Properties.Resources.edit_24px, new EventHandler(Edit_Click));
            cm.Items.Add("Remove", Properties.Resources.delete_sign_24px, new EventHandler(Remove_Click));
            cm.BackColor = Color.LightGray;
            #endregion

            labelTotal.Font = new Font(labelTotal.Font.Name.ToString(), labelTotal.Font.Size + 5);
            labelInNO.Font  = new Font(labelInNO.Font.Name.ToString(), labelInNO.Font.Size + 2);
            RepeatedFunctions.CheckBarcodeReader();
        }
Example #7
0
        private void FrmanageData_Load(object sender, EventArgs e)
        {
            Settings.LoadCtrlSettings(this);
            PanelMenu panelMenu = new PanelMenu(panel2, btnhide, 34, panel2.Width);

            this.panel1.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
            this.panel2.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
            var handler = TabChanged;

            handler?.Invoke(Current);

            Cm.Items.Add("Refresh", Properties.Resources.recurring_appointment_24px, new EventHandler(BtnRef_Click));
            Cm.Items.Add("Edit Details", Properties.Resources.edit_24px, new EventHandler(Edit_details_Click));
            Cm.Items.Add("Remove", Properties.Resources.edit_24px, new EventHandler(Remove_Click));
            Cm.BackColor = Color.LightGray;
            //Forms.addItems = new AddItems();
            //RepeatedFunctions.OpenForm(tabPage1, Forms.addItems, FormBorderStyle.FixedDialog, DockStyle.None);
            //Forms.frmanageItems = new FrmanageItems();
            //RepeatedFunctions.OpenForm(tabPage1, Forms.frmanageItems, FormBorderStyle.Fixed3D, DockStyle.Fill);
        }
        private void HasilPemilihan_Load(object sender, EventArgs e)
        {
            // TODO: This line of code loads data into the 'pilketosDataSet1.kandidat' table. You can move, or remove it, as needed.
            this.kandidatTableAdapter.Fill(this.pilketosDataSet1.kandidat);
            kandidat kand = new kandidat();

            PanelMenu.Visible = false;
            PanelMenu.BringToFront();
            for (int i = 0; i < dataGridView1.RowCount; i++)
            {
                if (dataGridView1.Rows[i].Cells[6].Value.ToString() == "10")
                {
                    this.chart1.Series["Suara"].Points.AddXY(dataGridView1.Rows[i].Cells[1].Value.ToString(), Convert.ToInt32(dataGridView1.Rows[i].Cells[5].Value));
                }
                else if (dataGridView1.Rows[i].Cells[6].Value.ToString() == "11")
                {
                    this.chart2.Series["Suara"].Points.AddXY(dataGridView1.Rows[i].Cells[1].Value.ToString(), Convert.ToInt32(dataGridView1.Rows[i].Cells[5].Value));
                }
            }
        }
Example #9
0
 private void Dashboard_Load(object sender, EventArgs e)
 {
     _           = new PanelMenu(panel2, btnhide, 34, panel2.Width);
     formContext = new FormContextMenu(btnhide, CF);
     if (RemoteDBs.Settings.commonSettings.Get.Interface == MenuInterfaceType.Classic)
     {
         menuClassic.labelTotal.Font = new Font(menuClassic.labelTotal.Font.Name.ToString(), menuClassic.labelTotal.Font.Size + 8);
         menuClassic.labelInNO.Font  = new Font(menuClassic.labelInNO.Font.Name.ToString(), menuClassic.labelInNO.Font.Size + 2);
         menuClassic.xuiClock1.Font  = new Font(menuClassic.xuiClock1.Font.Name.ToString(), menuClassic.xuiClock1.Font.Size + 10);
         menuClassic.btnIssue.Font   = new Font(menuClassic.btnIssue.Font.Name.ToString(), menuClassic.btnIssue.Font.Size + 8);
     }
     else
     {
         foreach (Control s in menuModern.flPanel.Controls)
         {
             s.Size = new Size(196, 296);
         }
         menuModern.uiBasicSale1.labelTotal.Font = new Font(menuModern.uiBasicSale1.labelTotal.Font.Name.ToString(), menuModern.uiBasicSale1.labelTotal.Font.Size + 5);
         menuModern.uiBasicSale1.labelInNO.Font  = new Font(menuModern.uiBasicSale1.labelInNO.Font.Name.ToString(), menuModern.uiBasicSale1.labelInNO.Font.Size + 2);
         menuModern.uiBasicSale1.btnIssue.Font   = new Font(menuModern.uiBasicSale1.btnIssue.Font.Name.ToString(), menuModern.uiBasicSale1.btnIssue.Font.Size + 5);
     }
 }
Example #10
0
    // Hides and deletes the screen on top of the stack and sets as active the next
    // if there is one
    public void BackScreen(UnityAction listener = null)
    {
        if (loadedMenus.Count > 0)
        {
            PanelMenu topScreen = loadedMenus.Pop();

            if (listener != null)
            {
                topScreen.OnMenuHidden.AddListener(listener);
            }
            topScreen.OnMenuHidden.AddListener(
                () =>
            {
                if (loadedMenus.Count > 0)
                {
                    loadedMenus.Peek().Show();
                }
                Destroy(topScreen.gameObject);
            }
                );
            topScreen.Hide(true);
        }
    }
Example #11
0
 void Awake()
 {
     Me = this;
     PanelMinigame.SetActive(false);
     PanelMenu.SetActive(true);
 }
Example #12
0
 private void btnMostrar_Click(object sender, EventArgs e)
 {
     PanelMenu.Show();
     btnMostrar.Hide();
 }
 private void PictureBox1_Click(object sender, EventArgs e)
 {
     PanelMenu.Visible = true;
     PanelMenu.BringToFront();
 }
 private void WellcomeAdmin_Load(object sender, EventArgs e)
 {
     PanelMenu.Visible = false;
     PanelMenu.BringToFront();
 }
Example #15
0
 public void IrAr()
 {
     PanelAR.SetActive(true);
     PanelLogin.SetActive(false);
     PanelMenu.SetActive(false);
 }
Example #16
0
 public void actMenu()
 {
     PanelMenu.SetActive(true);
 }
Example #17
0
 public void btnMostrar_Click(object sender, EventArgs e)
 {
     PanelMenu.Show();
     picce2.Hide();
     btnMostrar.Hide();
 }
Example #18
0
 void ItenClicked(int itenIndex)
 {
     Debug.Log("Item: " + itenIndex);
     PanelMenu.SetActive(false);
     BtnVolver.SetActive(true);
 }
Example #19
0
 private void FromDataUser_Load(object sender, EventArgs e)
 {
     PanelMenu.BringToFront();
     loadAll();
 }
Example #20
0
 private void FrmCharts_Load(object sender, EventArgs e)
 {
     _ = new PanelMenu(panel2, btnhide, 34, panel2.Width);
     Settings.LoadCtrlSettings(this);
     this.panel2.BackColor = RemoteDBs.Settings.commonSettings.Get.MenuColor;
 }
Example #21
0
    IEnumerator StartingGame()
    {
        yield return(new WaitForSeconds(0.1f));

        Shield shield = new Shield(5f, 3f, 2f, 0.15f);

        Spells.Add(new Spell("Fireball", 5, new Dictionary <FlyingParam, int>()
        {
            { FlyingParam.Speed, 80 }, { FlyingParam.Damage, 10 }, { FlyingParam.Size, 12 }
        }, new Dictionary <AfterHitParam, int>()
        {
            { AfterHitParam.Damage, 10 }, { AfterHitParam.Time, 2 }
        }));
        Spells.Add(new Spell("Ice", 10, new Dictionary <FlyingParam, int>()
        {
            { FlyingParam.Speed, 120 }, { FlyingParam.Damage, 10 }, { FlyingParam.Size, 10 }
        }, new Dictionary <AfterHitParam, int>()
        {
            { AfterHitParam.Damage, 20 }, { AfterHitParam.Time, 2 }, { AfterHitParam.SlowDown, 1 }
        }));

        Vial vial = new Vial("Minor Mana Potion", new Dictionary <VialParam, int>()
        {
            { VialParam.ManaAdd, 10 }
        }, SpriteManager.ManaPotion);

        Vials.Add(vial);
        Vials.Add(new Vial("Minor Health Potion", new Dictionary <VialParam, int>()
        {
            { VialParam.HealthAdd, 10 }
        }, SpriteManager.HealthPotion));

        List <Vial> rightVials = new List <Vial>();

        rightVials.Add(new Vial("Double bonus", new Dictionary <VialParam, int>()
        {
            { VialParam.ManaAdd, 100 }, { VialParam.HealthAdd, 100 }
        }, SpriteManager.HealthPotion));
        rightVials.Add(new Vial("Faster mana recovery", new Dictionary <VialParam, int>()
        {
            { VialParam.HealthAdd, 100 }
        }, SpriteManager.ManaPotion));

        Mage ivaAllesi = new Mage("Iva Alessi", MageClass.Thenacurviat, false);

        ivaAllesi.LeftHand   = Spells[0];
        ivaAllesi.RightHand  = Spells[1];
        ivaAllesi.Shield     = shield;
        ivaAllesi.LeftVials  = Vials;
        ivaAllesi.RightVials = rightVials;

        Mage kelThuzad = new Mage("Kel Thuzad", MageClass.Creator, true);

        kelThuzad.LeftHand  = Spells[1];
        kelThuzad.RightHand = Spells[0];
        kelThuzad.Shield    = shield;
        kelThuzad.LeftVials = Vials;

        Player = new Player(ivaAllesi, new List <Spell>()
        {
            Spells[0], Spells[1]
        });
        Enemy = new Player(kelThuzad, new List <Spell>()
        {
            Spells[0], Spells[1]
        });
        Enemy.SetAi(new Ai(0.9f, 5.9f, 0.9f));

        PanelMenu.SetActive(false);
        PanelMinigame.SetActive(true);

        Bonus b = new Bonus(vial, SpriteManager.HealthBonusOnMap, SpriteManager.HealthBonusOnMapShadow, true);

        MinigameParameters minigameParameters = new MinigameParameters(new BonusParameters(1, 1, 3, 5, new List <BonusConfig>()
        {
            new BonusConfig(b, 0.8f), new BonusConfig(null, 0.1f)
        }));

        PanelMinigame.GetComponent <PanelMinigame>().Prepare(Player, Enemy, minigameParameters);
    }