Stopclock function in Celestia?

Post requests, images, descriptions and reports about work in progress here.
Topic author
Evil Dr Ganymede
Posts: 1386
Joined: 06.06.2003
With us: 21 years 3 months

Stopclock function in Celestia?

Post #1by Evil Dr Ganymede » 22.11.2004, 02:55

One thing I find myself hankering for at the moment is a 'stopclock function' in Celestia. By this I mean that you press a button to start a clock from:
00 00:00:00 (days hours:minutes:seconds) which runs in Celestia time until you press another button that stops it.

This would be handy for timing things like seeing how long it takes between sunrise and sunset on any given planet at a location on its surface. (yes, I know you can just figure it out from the existing clock, but it's more awkward that way ;)).

Does anything like this exist? (can it be done as a script?) If not, can it be added at all??

Sky Pilot
Posts: 99
Joined: 01.12.2004
With us: 19 years 9 months
Location: Moved recently from the Bihem System, now in Fort Worth, Texas, USA

Post #2by Sky Pilot » 15.12.2004, 04:18

Oooh, I really like that suggestion. It would also make it easier to calculate how long it would take to get from point A to point B at different speeds. Nice idea!

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 7 months
Location: Seattle, WA USA

Re: Stopclock function in Celestia?

Post #3by hank » 15.12.2004, 09:43

Evil Dr Ganymede wrote:One thing I find myself hankering for at the moment is a 'stopclock function' in Celestia. By this I mean that you press a button to start a clock from:
00 00:00:00 (days hours:minutes:seconds) which runs in Celestia time until you press another button that stops it.

This would be handy for timing things like seeing how long it takes between sunrise and sunset on any given planet at a location on its surface. (yes, I know you can just figure it out from the existing clock, but it's more awkward that way ;)).

Does anything like this exist? (can it be done as a script?) If not, can it be added at all??

This would be easy to do with a Lua script.

- Hank

Harry
Posts: 559
Joined: 05.09.2003
With us: 21 years
Location: Germany

Re: Stopclock function in Celestia?

Post #4by Harry » 15.12.2004, 11:54

hank wrote:This would be easy to do with a Lua script.

Yes, indeed. Look at this thread at the Motherlode forum - this happened while shatters.net was down.

Harald

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 7 months
Location: Seattle, WA USA

Re: Stopclock function in Celestia?

Post #5by hank » 15.12.2004, 17:09

On that Motherlode thread I saw this:

Bob wrote:You probably already know that I simply HATE the LUA language, but this really IS a useful script.


What's not to like about Lua? It's very simple yet very powerful (as this example illustrates).

- Hank

Bob Hegwood
Posts: 1048
Joined: 19.10.2003
With us: 20 years 11 months
Location: Germantown, Ohio - USA

Re: Stopclock function in Celestia?

Post #6by Bob Hegwood » 16.12.2004, 11:09

hank wrote:What's not to like about Lua? It's very simple yet very powerful (as this example illustrates).

Sorry, but it ain't simple to me...

As you probably know, I'm the Brain-Dead user of Celestia,
so I tend NOT to understand some things which are easily
grasped by you well-educated types.

LUA just doesn't make sense to me. I need a language which
starts at point A, and which ends at point B, with logical
steps in between. Try as I might, I just don't GET the LUA
language. :oops:

Take care, Bob
Bob Hegwood
Windows XP-SP2, 256Meg 1024x768 Resolution
Intel Celeron 1400 MHz CPU
Intel 82815 Graphics Controller
OpenGL Version: 1.1.2 - Build 4.13.01.3196
Celestia 1.4.0 Pre6 FT1

maxim
Posts: 1036
Joined: 13.11.2003
With us: 20 years 10 months
Location: N?rnberg, Germany

Post #7by maxim » 16.12.2004, 15:22

Bob,

if you use some of the existing lua scripts as example, you will surely find them very procedural (programlike -> not very linear). But you should be able to build celx scripts nearly in the same way as you build cel scripts. Most cel commands have a representation in celx. So if you just write them from start to end, they should work like cel scripts. Some time later you might have some idea of doing something more complicated that doesn't work in cel - like a loop or using a variable for some repetitive value (the default wait time for example) - and that's simple to solve in celx/lua. Et voil?, after some time and a quite flat learning curve you suddenly are a lua expert and will easily write the most complicated scripts.

maxim :)

Bob Hegwood
Posts: 1048
Joined: 19.10.2003
With us: 20 years 11 months
Location: Germantown, Ohio - USA

Post #8by Bob Hegwood » 16.12.2004, 23:47

Thanks for the confidence Maxim, but I think you're over-
estimating the capabilties of my damaged brain. :wink:

LUA is an object-oriented language, yes? Have never been
able to grasp this stuff. Don't know why...

I will give it some more time though. You never know, I might
just need a brewsky before I try to understand the stuff. :lol:

Thanks, Bob
Bob Hegwood

Windows XP-SP2, 256Meg 1024x768 Resolution

Intel Celeron 1400 MHz CPU

Intel 82815 Graphics Controller

OpenGL Version: 1.1.2 - Build 4.13.01.3196

Celestia 1.4.0 Pre6 FT1


Return to “Add-on development”