From 14d1124e5a63cca1c681fd2f5bb3b684d6dc5655 Mon Sep 17 00:00:00 2001 From: march3 Date: Tue, 2 Apr 2024 21:25:53 +0800 Subject: [PATCH] =?UTF-8?q?Python=E8=B6=85=E4=BA=BA-=E5=AE=87=E5=AE=99?= =?UTF-8?q?=E6=A8=A1=E6=8B=9F=E5=99=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../center_point_moving_sun_to_earth.py | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/sim_scenes/featured/center_point_moving_sun_to_earth.py b/sim_scenes/featured/center_point_moving_sun_to_earth.py index ceb1db6..287a822 100644 --- a/sim_scenes/featured/center_point_moving_sun_to_earth.py +++ b/sim_scenes/featured/center_point_moving_sun_to_earth.py @@ -37,7 +37,7 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase): earth_cn_size_factor=1.01, earth_clouds_size_factor=1.015) self.start_time = '2023-12-20 00:00:00' - self.sun.size_scale = 4e1 + self.sun.size_scale = 5.5e1 self.earth.size_scale = 2e3 self.earth_clouds.size_scale = self.earth.size_scale self.earth_cn.size_scale = self.earth.size_scale @@ -48,10 +48,10 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase): self.mercury = Mercury(size_scale=2e3) self.venus = Venus(name="金星", size_scale=2e3) self.mars = Mars(size_scale=2e3) - self.jupiter = Jupiter(size_scale=0.2e3) - self.saturn = Saturn(size_scale=0.2e3) - self.uranus = Uranus(size_scale=2e3) - self.neptune = Neptune(size_scale=2e3) + self.jupiter = Jupiter(size_scale=0.6e3) + self.saturn = Saturn(size_scale=0.6e3) + self.uranus = Uranus(size_scale=1.5e3) + self.neptune = Neptune(size_scale=1.5e3) self.bodies += [self.moon, self.mercury, self.venus, self.mars, self.jupiter, self.saturn, self.uranus, self.neptune @@ -228,8 +228,8 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase): _dt = (time_data.dt / 28788) - print("total_days:", time_data.total_days) - if time_data.total_days > 2300: + # print("total_days:", time_data.total_days) + if time_data.total_days > 2800: exit() ec = UrsinaSimulator.EditorCamera @@ -247,16 +247,16 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase): ec.world_position -= ec.back * 1.4* _dt * UrsinaConfig.run_speed_factor # 下(快一点) ec.world_position += ec.right * 0.8 * _dt* UrsinaConfig.run_speed_factor # 左 d_sun = self.get_distance_sun() - print("d_sun:", d_sun) + # print("d_sun:", d_sun) if d_sun > 45: self.phase_num = 5 - elif self.phase_num == 5: - ec.world_position -= ec.back * 1.4* _dt * UrsinaConfig.run_speed_factor # 下 - ec.world_position += ec.right * 0.7* _dt * UrsinaConfig.run_speed_factor # 左 - pos = camera.world_position - if pos[2] > 2000: - self.phase_num = 6 - print("pos:", pos) + # elif self.phase_num == 5: + # ec.world_position -= ec.back * 1.4* _dt * UrsinaConfig.run_speed_factor # 下 + # ec.world_position += ec.right * 0.7* _dt * UrsinaConfig.run_speed_factor # 左 + # pos = camera.world_position + # if pos[2] > 2000: + # self.phase_num = 6 + # print("pos:", pos) # if d_sun > 4500: @@ -327,7 +327,7 @@ if __name__ == '__main__': """ sim = CenterPointMovingSimLive() sim.run( - dt=SECONDS_PER_DAY * 5, + dt=SECONDS_PER_DAY * 10, # dt=SECONDS_PER_DAY * 3, init_position=[0, -60 * AU, 30 * AU], show_exit_button=False, -- GitLab