void generate_new_system() { int random_main = rnd.Next(1, 340); circle_1_main = new Circle(W / 2, H / 2, 200, 0, 220); system = new Circle_System(circle_1_main); int random = 0; float random_rad = 0; //for (int i = 1; i <= 360; i += 1) //{ // random = rnd.Next(1, 3); // random_rad = rnd.Next(20, 9000); // system.add_circle(random_rad, i, random, random+1); //} system.add_circle(50, 1, 0, 100); system.add_circle(50, 30, -20, 80); system.add_circle(50, 60, -30, 70); system.add_circle(50, 91, -40, 60); system.add_circle(50, 130, -80, 90); system.add_circle(50, 181, 90, 170); system.add_circle(50, 271, 0, 330); system.add_circle(50, 240, -330, 0); pictureBox.Image = myBitmap; }
void generate_new_random_system() { int random_main = rnd.Next(1, 340); int random_main_rad = rnd.Next(1, W / 2); circle_1_main = new Circle(W / 2, H / 2, random_main, random_main, rnd.Next(random_main + 20, 360)); system = new Circle_System(circle_1_main); int random = 0; float random_rad = 0; for (int i = 1; i <= 360; i += 20) { random = rnd.Next(1, 340); random_rad = rnd.Next(10, 100); system.add_circle(random_rad, random, random, rnd.Next(random + 20, 360)); } pictureBox.Image = myBitmap; }