darkfire wrote:
dolphinling wrote:
Looks nice! Think you could make it automatically align it to where it's supposed to be if the person's get_star_data includes that constellation? It should be pretty easy, the format they use is simple to understand.
Also, I'm having a bit of trouble dragging it... sometimes it works, sometimes it doesn't. You might want to look into it.
The automatic lining up is not as easy as it sounds, it requires finding the pattern to find the pattern you have to for each star search every other star to find the second then to make sure you have the right one you'll have to search every other star again for the third. While programmitcally this isn't as hard (three nested for loops should do it) processing-wise it starts eating. (Ie just looking for the first three star in the the constellation to make sure it really -is- the right one will take approx 280^3 calculations if you have 280 stars.)
Oh yes forgot to add, are you using Firefox? Cause if you are it is have some issues (and the issues vary) with firefox. I am not familiar with firefox so I'm unsure as to how to fix it, but I'm looking into it.
Nono, I don't mean automatically
finding the constellation, I just mean automatically aligning it if it's already in the star data. Take a look at the end of mine:
Code:
...:1!37,-212;77,-242#77,-242;117,-272#157,-272;197,-242#197,-242;237,-212
Before the ":" is all the original star data. After it is all the already-found constellations. Constellations are split up by "|" (not shown here, but it's in the code for the telescope). Then, in each constellation, before the "!" is the ID of the constellation: in this case 1, which is the DF. After that are the lines, split up by "#". There's a line between 37,-212 and 77,-242, another between 77,-242 and 117,-272, etc.
So pretty easy to understand.
Wow, I actually understood that. Either I'm spending waaay too much time in front of the computer, or programming is getting a lot easier