Example #1
0
        public static void BgRefresh(DTModule module, QueueStats.BGDataStruct queue)
        {
            int    estimatedWait = queue.estimatedWait / 1000;
            int    queuedTime    = (System.Environment.TickCount - queue.timeWaited) / 1000;
            string bname         = queue.battlefieldName;

            //try
            //{
            //    bname = Forms.ProcessSelector.BattlefieldIDs[queue.battlefieldID];
            //}
            //catch (Exception ex)
            //{
            //    bname = "Couldn't Get Dungeon Name";
            //}
            module.lbl_Status.Text = String.Format("{0} (queued)", bname);

            if (estimatedWait != 0)
            {
                module.lbl_Wait.Text = Helper.getFormatedTimeString(estimatedWait);
            }
            else
            {
                module.lbl_Wait.Text = "n/a";
            }

            module.lbl_QueueTime.Text = Helper.getFormatedTimeString(queuedTime);
        }
Example #2
0
        private void timerMemoryRead_Tick(object sender, EventArgs e)
        {
            try
            {
                if (settings.PauseFocus)
                {
                    if (GetForegroundWindow() == hWnd_wow)
                    {
                        paused = true;
                        this.panel_inner.Enabled = false;
                    }
                    else
                    {
                        paused = false;
                        this.panel_inner.Enabled = true;
                    }
                }

                if (!paused)
                {
                    NumActiveQueues = getkNumActiveQueues();

                    PveQueueReadyStatus = QueueStats.getLfgProposal();

                    lfdQueue = QueueStats.getLfgQueueStats(1);
                    lfrQueue = QueueStats.getLfgQueueStats(3);
                    bg1Queue = QueueStats.getBgQeueStats(1);
                    bg2Queue = QueueStats.getBgQeueStats(2);

                    LfdQueueStatus = lfdQueue.LfgDungeonsId;
                    LfrQueueStatus = lfrQueue.LfgDungeonsId;
                    Pvp1QueueStatus = bg1Queue.status;
                    Pvp2QueueStatus = bg2Queue.status;
                }
            }
            catch (Exception ep)
            {
                memoryScanner.Stop();
                MessageBox.Show(String.Format("Unexpected Error: {0}", ep.Message), "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                Application.Exit();
            }
        }