Celestia

Форк
0
/
mark-lg.celx 
40 строк · 1.2 Кб
1
-- Title: Mark Local Group Galaxies
2

3
function mark_LG_galaxies()
4
--
5
-- tables with the member galaxies of the Local Group
6
--
7
	local LG_big_galaxies = {"Milky Way", "M 31", "M 33"}
8

9
	local LG_members = {"LMC","SMC","IC 10","NGC 6822","M 32","M 110","NGC 3109","NGC 185","IC 1613","NGC 147","Sextans A","Sextans B","WLM","Sagittarius dSph","Fornax dSph","Pegasus DIG","And VII","Leo I","Leo A","And II","And I","And VI","Sagittarius DIG","Aquarius Dwarf","Antlia Dwarf","Sculptor dSph","And III","Leo II","Cetus Dwarf","Sextans dSph","Phoenix Dwarf","LGS 3","Tucana Dwarf","Carina Dwarf","And V","UrsaMinor Dwarf","Draco Dwarf"}
10
	
11
	for dso in celestia:dsos() do
12
		for i,v in ipairs(LG_big_galaxies) do
13
     		if dso:name() == v then
14
        		dso:mark( "green", "disk",10, 1 )
15
			end
16
		end
17
		for j,w in ipairs(LG_members) do			
18
	  		if dso:name() == w then
19
         		dso:mark( "red", "disk",5, 0.7 )
20
	  		end
21
		end
22
	end
23
end
24

25
----------
26
-- main -- 
27
----------
28
celestia:unmarkall()
29
celestia:setrenderflags { markers = true }
30
km2Mpc = 1/3.08568025e19
31
MW = celestia:find("Milky Way")
32
celestia:select(MW)
33

34
--
35
-- move observer to a distance of 5 Mpc from Milky Way
36
--
37
observer = celestia:getobserver()
38
observer:gotodistance(MW, 5/km2Mpc,5)
39
mark_LG_galaxies()
40
wait(0)

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.