Exemplo n.º 1
0
        private void LoadSolarSystem_OnClick(object sender, RoutedEventArgs e)
        {
            RemoveAllBodies();

            _system = new SolarSystem.SolarSystem(SolarSystem.SolarSystem.GetSolarSystem());
            _system.Bodies.ForEach(body =>
            {
                Viewport3DX.Items.Add(body);
                Bodies.Add(body);
            });
            _system.OrbitModels.ForEach(Viewport3DX.Items.Add);
            CanStartSimulation.Value = true;
        }
Exemplo n.º 2
0
        private void GenerateSolarSystem_OnClick(object sender, RoutedEventArgs e)
        {
            RemoveAllBodies();

            _system = new SolarSystem.SolarSystem(IsDouble ? 2 : 1, Planets);
            _system.Bodies.ForEach(body =>
            {
                Viewport3DX.Items.Add(body);
                Bodies.Add(body);
            });
            _system.OrbitModels.ForEach(Viewport3DX.Items.Add);
            CanStartSimulation.Value = true;
        }