A tale of two char sets, another Utf vs Unicode deathmatch, and no one told me I was the ref.
So after sorting all that out, I needed a break.
In light of recent discussions in the restart thread, I decided to have some fun to get my mind off of things.
The result is thus.
Here is a customized Celestia commit 5429.
I have added a command to celx, it returns the distance between two things in LY.
Code: Select all
local target1 = "Sol"
local target2 = "Wolf 359"
dist = celestia:betwixt(target1, target2)
celestia:print(target1 .. " " .. target2 .. " dist is:" .. dist, 10)
I coded it thinking of stars, but it works on all sorts of things.
For instance, set target1 & target2 to earth and mars, get a reading between them, then advance the date via script one day, and read it again.
You can watch the distance between them change over time from above the ecliptic to help you visualize the movement of the planets, with the numbers every one happily bandies about in discussions changing over "time".
I have done no real testing, so caveat tinker, it may give weird results, or even crash if given garbage strings.
All I can hope is it amuses someone.
Length or distance conversions can be found at : Celx Vector guide
EDIT: Look further for later versions. Now has three commands added as of the #8 benear posting.