提交 62ca2e93 编写于 作者: 三月三net's avatar 三月三net

Python超人-宇宙模拟器

上级 b7f625ae
......@@ -35,7 +35,8 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
delay_run=False,
look_at_earth=False,
earth_cn_size_factor=1.01,
earth_clouds_size_factor=1.015)
earth_clouds_size_factor=1.015,
show_name=False)
self.start_time = '2023-12-20 00:00:00'
self.sun.size_scale = 5.5e1
self.earth.size_scale = 2e3
......@@ -60,8 +61,9 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
self.last_year = None
for body in self.bodies:
body.show_name = False
if isinstance(body, Earth):
body.show_name = False
body.rotate_angle -= 22
body.rotation_speed *= 2.5
body.set_resolution(50)
......@@ -92,7 +94,7 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
segments=100)
# print(points)
orbit_line = create_orbit_by_points(center_body.position, points, line_color=body.trail_color,
alpha=alpha, thickness=4)
alpha=alpha, thickness=2)
return orbit_line
def create_orbit_lines(self):
......@@ -109,7 +111,7 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
else:
alpha = 0.2
start_time = conv_to_astropy_time(self.start_time)
orbit_line = self.create_orbit_line(self.sun, body, start_time, alpha=0.8)
orbit_line = self.create_orbit_line(self.sun, body, start_time, alpha=0.4)
if orbit_line is not None:
self.orbit_lines.append(orbit_line)
return self.orbit_lines
......@@ -182,14 +184,14 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
UrsinaConfig.trail_type = "curve_line"
UrsinaConfig.trail_length = 180
# UrsinaConfig.trail_length = 1000
UrsinaConfig.trail_thickness_factor = 4
UrsinaConfig.trail_thickness_factor = 3
UrsinaConfig.trail_alpha = 0.8
UrsinaConfig.trail_factor = 4
for body in self.bodies:
body.planet.trail_scale = 0.5
body.planet.trail_scale = 0.3
self.moon.planet.trail_scale = 0.5
self.moon.planet.trail_scale = 0.3
# WorldGrid().draw_axises(100)
......@@ -199,7 +201,7 @@ class CenterPointMovingSimLive(EarthSeasonsSimBase):
destroy(self.earth_clouds.planet)
destroy(self.earth_cn.planet)
self.earth.planet.name_text.enabled = False
# self.earth.planet.name_text.enabled = False
self.moon.planet.rotation_y = 180
......@@ -331,6 +333,7 @@ if __name__ == '__main__':
摄像机以太阳的视角看地球(四季和24节气)
"""
sim = CenterPointMovingSimLive()
UniverseSimScenes.set_window_size((1920, 1079), False)
sim.run(
dt=SECONDS_PER_DAY * 15,
# dt=SECONDS_PER_DAY * 3,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册