Page 1 of 1

.CEL "Planetarium Mode" Statements

Posted: 21.02.2019, 03:04
by jeffmack
Hello,

Am I correct in my understanding that there are no .CEL statements equivalent to any, or all, the following three interactive functions (for the purpose of scripting a "planetarium mode"):

1) GoTo ground.

2) Set Alt-Azimuth mode.

3) Point camera to a specified azimuth (and possibly altitude).

I realize that this functionality exists in LUA, but it would be nice to have it in .CEL as well.

Thanks!

Jeff

Posted: 21.02.2019, 06:52
by Croc
Example:
This example selects the Earth and positions the camera over Seattle, Washington, USA, at a distance of 12,000 km above the surface.

Code: Select all

earth = celestia:find("Sol/Earth")
celestia:select(earth)
obs = celestia:getobserver()
obs:synchronous(earth)
earthdistance = 12000 + earth:radius()
longitude = math.rad(-122.0)
latitude = math.rad(47.0)
obs:gotolonglat(earth, longitude, latitude, earthdistance, 5.0)
celestia:print("Traveling to Seattle, Washington, USA.", 5.0, -1, -1, 2, 4)
wait(5.0)
celestia:print("Hovering over Seattle, Washington, USA.", 5.0, -1, -1, 2, 4)
wait(5.0)


Celestia/Celx Scripting/CELX Lua Methods/Celx observer
https://en.wikibooks.org/wiki/Celestia/Celx_Scrip ... hods/Celx_observer#gotolonglat

Posted: 21.02.2019, 07:09
by jeffmack
Sorry, but this is not at all what I asked about. :fie:

But thanks for replying.

Jeff

Posted: 21.02.2019, 09:09
by Croc
jeffmack,
......
1) GoTo ground.
......
The following functions are implemented in the graphical interface Lua Universal Tools:
  • planetarium mode
  • navigation mode

planetariumMode.jpg


navigationMode.jpg


Perhaps the answer to your question is in the compassBox.lua file (version of Lua Edu Tools)?

Posted: 21.02.2019, 15:58
by selden
My understanding is that Jeff is asking that certain functions which are available in the .CELX (Lua) interpreter also be made available in the .CEL interpreter, which currently does not have them.

Unfortunately, having them available in the LUA user interface or a Lua script doesn't make them available in a .CEL script.

Posted: 22.02.2019, 04:33
by jeffmack
Yes, Selden. You are correct. I specifically asked about .CEL scripting - NOT LUA scripting. Thank you!

And you answered my question - these "planetarium mode" related functions do not currently exist in Celestia. It would be nice to see them implemented in Celestia version 1.7.0. They seem so basic to me.

Anyway, thanks again, Selden. :smile: