/** * This randomises all selected skins * in the given range from txtRandomFirst.text > txtRandomLast.txt */ private void btnRandomiseRange_Click(object sender, EventArgs e) { int rangeFirst, rangeLast; //Check for valid converstion if (!(int.TryParse(txtRandomFirst.Text, out rangeFirst)) || (!int.TryParse(txtRandomLast.Text, out rangeLast))) { MessageBox.Show("Error: Invalid range selected. Please enter a number into both boxes"); return; } if (rangeFirst > rangeLast) { MessageBox.Show("Error: First must be lower than Last"); return; } if (rangeLast > lookup.getOffsetSize()) { MessageBox.Show("Error: end is higher than list count"); return; } if (rangeFirst < 1) { return; } randomiseRange(rangeFirst, rangeLast, 1, NUMOFSKINS); }
private void btnRestoreDefault_Click(object sender, EventArgs e) { int i; string str; if (0 >= lookup.getOffsetSize()) { lookup = new LookupLBABody(true); //ToDo Fix this shit Console.WriteLine("Size: " + lookup.getOffsetSize()); MessageBox.Show("Fix this!"); } for (i = 0; i < NUMOFSKINS; i++) { str = lookup.getOffset(i); Console.WriteLine(str); updateLVI(lvItemList, i, lookup.getOffset(i)); } }