Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Python_超人
宇宙模拟器
提交
62ca2e93
宇宙模拟器
项目概览
Python_超人
/
宇宙模拟器
通知
19
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
宇宙模拟器
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
62ca2e93
编写于
6月 30, 2024
作者:
三月三net
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Python超人-宇宙模拟器
上级
b7f625ae
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
11 addition
and
8 deletion
+11
-8
sim_scenes/featured/center_point_moving_sun_to_earth.py
sim_scenes/featured/center_point_moving_sun_to_earth.py
+11
-8
未找到文件。
sim_scenes/featured/center_point_moving_sun_to_earth.py
浏览文件 @
62ca2e93
...
...
@@ -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.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录