diff --git "a/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\234\272\346\231\257.py" "b/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\234\272\346\231\257.py" index ef42e84f7956de87fc6ee95910cd5aecaf38e46c..7243d0f1a168a6d382a42ec2d0ba55b2f09d28d4 100644 --- "a/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\234\272\346\231\257.py" +++ "b/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\234\272\346\231\257.py" @@ -88,7 +88,7 @@ class 模拟场景(UniverseSimScenes): # 运行前触发 self.sky = create_sphere_sky(texture="bg_pan2.jpg", scale=500000, rotation_x=20, rotation_y=160, rotation_z=20) - # UrsinaConfig.trail_type = "line" + UrsinaConfig.trail_type = "line" # UrsinaConfig.trail_length = 91 # UrsinaConfig.trail_type = "line" UrsinaConfig.trail_length = 420 @@ -139,8 +139,14 @@ class 太阳系模拟场景(模拟场景): start_time=start_time, days=orbital_days, segments=100) + + if self.配置项.中心天体 is None: + center_pos = center_body.position + else: + center_pos = np.array([0.0, 0.0, 0.0]) + # print(points) - orbit_line = create_orbit_by_points(center_body.position, points, line_color=body.trail_color, + orbit_line = create_orbit_by_points(center_pos, points, line_color=body.trail_color, alpha=alpha) return orbit_line diff --git "a/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\256\236\351\252\214\345\256\244/\345\244\252\351\230\263\347\263\273/\345\244\252\351\230\263\347\263\273.py" "b/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\256\236\351\252\214\345\256\244/\345\244\252\351\230\263\347\263\273/\345\244\252\351\230\263\347\263\273.py" index a9539d0952bb271298f28ba8ad3f2b4d948f3d97..17b62a165a519f96931330441be1984cdb0d6c80 100644 --- "a/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\256\236\351\252\214\345\256\244/\345\244\252\351\230\263\347\263\273/\345\244\252\351\230\263\347\263\273.py" +++ "b/\345\274\225\345\212\233\344\270\226\347\225\214/\346\250\241\346\213\237\345\256\236\351\252\214\345\256\244/\345\244\252\351\230\263\347\263\273/\345\244\252\351\230\263\347\263\273.py" @@ -13,7 +13,7 @@ class 太阳系模拟(太阳系模拟场景): def 配置(self, 配置项: 模拟配置): 配置项.显示轨道 = 打开 配置项.地月距离倍数 = 20 - 配置项.中心天体 = self.太阳 + # 配置项.中心天体 = self.太阳 def 造物(self): self.太阳 = 造物主.造物(名称='太阳', 缩放倍数=1e1)