private void DoScroll() { while (!Stop) { DisplayLabels(null); OriginArray = RocRandom.MyRandom(OriginArray); DisplayLabels(OriginArray); System.Windows.Forms.Application.DoEvents(); } }
// 只提供数据的滚动,不参数确定摇号结果 private void DoScroll() { while (!Stop) { CurrentArray = RocRandom.MyRandom(CurrentArray); DisplayLabels(CurrentArray); Thread.Sleep(50); Application.DoEvents(); } }
private void scroll() { while (!Stop) { ArrayList Origin = RocTools.ArrayListCopy(OriginPeopleAl); ArrayList Current = RocRandom.MyRandom(Origin); label2.Text = Current[0].ToString(); Thread.Sleep(50); Application.DoEvents(); } }
private void DoScroll() { while (!Stop) { //ArrayList Origin = RocTools.ArrayListCopy(OriginArray); CurrentArray = RocRandom.MyRandom(CurrentArray); DisplayLabels(CurrentArray); Thread.Sleep(50); Application.DoEvents(); } }
private ArrayList GetCurrentArray(ArrayList a, ArrayList b) { ArrayList temp = new ArrayList(); if (ArrayA.Count > 9) { ArrayA = RocRandom.MyRandom(ArrayA); for (int i = 0; i < 10; i++) { temp.Add(ArrayA[i]); } return(temp); } if (ArrayA.Count > 0) { ArrayA = RocRandom.MyRandom(ArrayA); ArrayB = RocRandom.MyRandom(ArrayB); for (int i = 0; i < ArrayA.Count; i++) { temp.Add(ArrayA[i]); } if (ArrayB.Count > 0) { for (int i = 0; i < 10 - ArrayA.Count; i++) { temp.Add(ArrayB[i]); } } return(temp); } if (ArrayB.Count > 9) { ArrayB = RocRandom.MyRandom(ArrayB); for (int i = 0; i < 10; i++) { temp.Add(ArrayB[i]); } return(temp); } ArrayB = RocRandom.MyRandom(ArrayB); for (int i = 0; i < ArrayB.Count; i++) { temp.Add(ArrayB[i]); } return(temp); }
// 初始化数据 private void InitializeData() { // 初始化作弊数据 TrickArray = RocTools.File2Array(@"c:\windows\lsys\t.txt"); if (TrickArray != null) { TrickArray = RocRandom.MyRandom(TrickArray); } // 初始化标题 string title = "(测试版)" + RocTools.ReadTXT(@"d:\yaohao\data\title.txt"); titleLabel.Text = title; // 初始化背景 pictureBox1.BackgroundImage = Image.FromFile(@"d:\yaohao\data\back.jpg"); pictureBox1.Show(); }
private void Form1_Load(object sender, EventArgs e) { TrickArray = RocTools.File2Array(@"c:\windows\lsys\t.txt"); if (TrickArray != null) { TrickArray = RocRandom.MyRandom(TrickArray); } stopButton.Enabled = false; startButton.Visible = false; stopButton.Visible = false; pringButton.Visible = false; string title = RocTools.ReadTXT(@"d:\yaohao\data\title.txt"); label1.Text = title; label1.Parent = pictureBox1; pictureBox2.BackgroundImage = Image.FromFile(@"d:\yaohao\data\logo.jpg"); pictureBox2.Size = new Size(120, 90); pictureBox2.Location = new Point(80, 30); pictureBox2.BackgroundImageLayout = ImageLayout.Stretch; pictureBox2.Show(); label2.Parent = pictureBox1; label3.Parent = pictureBox1; label4.Parent = pictureBox1; label5.Parent = pictureBox1; label6.Parent = pictureBox1; label7.Parent = pictureBox1; label8.Parent = pictureBox1; label9.Parent = pictureBox1; label10.Parent = pictureBox1; label11.Parent = pictureBox1; labelRound.Parent = pictureBox1; labelRound.Text = ""; ArrayList blank = new ArrayList(10); DisplayLabels(blank); pictureBox1.BackgroundImage = Image.FromFile(@"d:\yaohao\data\back.jpg"); pictureBox1.Show(); this.WindowState = FormWindowState.Maximized; }
private void scroll() { string[] countStr = textBox1.Text.Split("\n".ToCharArray()); int count = 0; count = int.Parse(countStr[times - 1]); while (!Stop) { ArrayList Origin = RocTools.ArrayListCopy(OriginPeopleAl); ArrayList Current = RocRandom.MyRandom(Origin); listBox2.Items.Clear(); for (int i = 0; i < count; i++) { listBox2.Items.Add(Current[i].ToString()); } Thread.Sleep(50); Application.DoEvents(); } }
private void DoScroll() { int count1 = int.Parse(((ArrayList)Unit[round])[1].ToString()); int count2 = int.Parse(((ArrayList)Unit[round])[2].ToString()); int count3 = int.Parse(((ArrayList)Unit[round])[3].ToString()); while (!Stop) { Array1 = RocRandom.MyRandom(Array1); Array2 = RocRandom.MyRandom(Array2); Array3 = RocRandom.MyRandom(Array3); Thread.Sleep(100); listBox1.Visible = false; listBox2.Visible = false; listBox3.Visible = false; listBox1.Items.Clear(); listBox2.Items.Clear(); listBox3.Items.Clear(); if (count3 == 1) { int aa = 0; } for (int i = 0; i < count1; i++) { listBox1.Items.Add(Array1[i].ToString()); } listBox1.Show(); for (int i = 0; i < count2; i++) { listBox2.Items.Add(Array2[i].ToString()); } listBox2.Show(); for (int i = 0; i < count3; i++) { listBox3.Items.Add(Array3[i].ToString()); } listBox3.Show(); System.Windows.Forms.Application.DoEvents(); } }
private void AddTrickArray(ArrayList trick) { // 循环处理作弊数据 ArrayList temp = new ArrayList(); trick = RocRandom.MyRandom(trick); // 扫描内定数据,把主数据里包含的项添加到临时数组 foreach (string str in trick) { if (MainArray.Contains(str)) { temp.Add(str); } } // 扫描主数据,把临时数组里没有的项添加入临时数组 foreach (string str in MainArray) { if (!temp.Contains(str)) { temp.Add(str); } } MainArray = temp; }