diff --git a/sim_scenes/solar_system/sun_earth_moon.py b/sim_scenes/solar_system/sun_earth_moon.py index 3395ccd62e54668977227f0a4c640e7b362199c1..b26c69df9ec70ebb4310e81f26506828f95bdb7b 100644 --- a/sim_scenes/solar_system/sun_earth_moon.py +++ b/sim_scenes/solar_system/sun_earth_moon.py @@ -24,11 +24,11 @@ if __name__ == '__main__': # 观看月相变化的过程:分别是 新月、蛾眉月、上弦月、盈凸、满月、亏凸、下弦月、残月 # 参考:images/moon/月相变化过程.jpeg # TODO: 月球在摄像机的前方(从 “新月” 开始) - # moon_pos, moon_vel = [0, 0, 384400], [-(EARTH_INIT_VELOCITY + 1.023), 0, 0] + moon_pos, moon_vel = [0, 0, 384400], [-(EARTH_INIT_VELOCITY + 1.023), 0, 0] # TODO: 月球在摄像机的右方(从 “下弦月” 开始),将会从右方出现 # moon_pos, moon_vel = [384400, 0, 0], [-EARTH_INIT_VELOCITY, 0, 1.023] # TODO: 月球在摄像机的左方(从 “上弦月” 开始) - moon_pos, moon_vel = [-384400, 0, 0], [EARTH_INIT_VELOCITY, 0, -1.023] + # moon_pos, moon_vel = [-384400, 0, 0], [EARTH_INIT_VELOCITY, 0, -1.023] bodies = [ sun, diff --git a/simulators/ursina/entities/body_trail.py b/simulators/ursina/entities/body_trail.py index 3f4cb06c1a42c26fd7034f35ca68c23dc2ce8608..7b43d9ed7ddaf04a0bf5cd3ba32d15599f130f08 100644 --- a/simulators/ursina/entities/body_trail.py +++ b/simulators/ursina/entities/body_trail.py @@ -51,3 +51,21 @@ class BodyTrail(Entity): a_text.parent = self a_arrow.enabled = False a_line.enabled = False + + +# class BodyTrail(Entity): +# def __init__(self, **kwargs): +# from_pos = (0, 0, 0) +# to_pos = (1, 1, 1) +# super().__init__( +# # model='line', +# model=Mesh(vertices=(from_pos, to_pos), mode='line', thickness=3), +# ignore_paused=True, +# **kwargs +# ) +# +# def update(self): +# self.look_at(self.parent) +# # line = Entity(parent=parent, +# # model=Mesh(vertices=(from_pos * len_scale, to_pos * len_scale), mode='line', thickness=thickness), +# # color=color, alpha=alpha)