Closed BrianErikson closed 9 years ago
+1
we could introduce a pixels-to-AU constant somewhere and use that to scale the display. I think the ng way of doing this is to use a filter. Then printouts look something like:
{{game.data.distanceTraveled | au_distance}}
here are the distances (for v1.0) if we decide to do this:
I think we should make each leg of the trajectory a fixed distance of pixels. I know it wouldnt be 1000 but for example, its 1000 pixels from launch to the moon maneuver node, then 1000 pixels to the moon, then 1000 pixels to the mars manevuer node... etc. And then for each leg we can do like a little y=mx+b where y is the distance traveled, x is the number of pixels traveled, b is the distance of the previous location, and m is distance per pixel. These can all be pretty easily calculated.
Yeah, that's how it works. The number of pixels is just huge.
It looks like you're calculating the number of pixels based on the distance to be travelled. I'm saying calculate how much distance you've traveled based on how many pixels you've crossed. Essentially there is a different AU_2_PIX constant for each leg. Actually it'd be PIX_2_AU in my case. This way we can fix the number of pixels and not have any stupid long gaps in the trajectory of nothing-ness but still record the "real" distance travelled.
Fixed.
Accurately represent distance as a factor of AU, rather than a generic unit, in the travel module. This way we can pseudo-accurately position moons and other celestial bodies at the correct distances away from the center of the solar system.