Visible Planets in Space

by Nauviax

Render the local planet behind platforms when in orbit. Now with parallax, rotation, and mod support!

Tweaks
5 days ago
2.0
17.8K
Environment

i Smoother animation and parallax

a month ago

you can add parallax for planets like in the background of space, creating the appearance of distance from the planet and slow down the animation when leaving or entering orbit by 5-8 times for a smoother experience of playing with the mod

a month ago

You're actually the third person to ask for parallax, and it's already listed as WIP on the mod page.

I've experimented with a few options, but nothing has worked properly yet. For example, simply moving the planet when the camera moves would work, but might be bad for performance and would instantly break in multiplayer.

If you just want to slow down the leaving/entering animation though, you can do this in the mod's settings.

a month ago

An initial version of parallax is out now! It's as performant as I can make it, and it mostly kind of works in multiplayer.

a month ago

You are a god Nauviax.

Keep up the development, keep tweaking, keep improving, and this mod is sure to hit into the tens of thousands of downloads.
Something Wube should have done from the get go.

a month ago
(updated a month ago)

Hijacking this thread to point out that its not the speed at which planet moves but rather the lack of easing that makes it feel not as smooth. Having it tied to the ship's position and speed might be even more appropriate but I understand its technical challenges. Also I'd recommend rotating the planet so the dark side is on the bottom right, which is how all the space platform sprites are shaded.

Other than that, wonderful mod! This is of the same significance as disco science in 1.0 and I'm glad that you're able to make it exist.

a month ago
(updated a month ago)

you can add parallax for planets like in the background of space, creating the appearance of distance from the planet and slow down the animation when leaving or entering orbit by 5-8 times for a smoother experience of playing with the mod

Do you not understand the concept of perspective and scale? At that distance, there should be no parallax and no movement of the planet when moving the camera around the ship on the scale of a few hundred of meters. To produce a discernible apparent movement of the planet on screen you would need to travel for thousand or tens of thousand of kilometers only to see the planet shift slightly to a side or another.

a month ago
(updated a month ago)

You are getting it backwards, from how the space background was coded the planet probably moved along with the ship as you pan the camera, and the latest update made it at least move slower.
As opposed to the dev intentionally coding the planet to stay still with relation to the camera panning at first and somehow changed that for the worse.

a month ago
(updated a month ago)

You are getting it backwards, it's when both objects are far away that parallax won't be significant.
In this case it's more like holding your phone close to your face up to a door in the background. Move your head left and right, and the door will move drastically in relation to the phone.

As a clarification since the way I expressed myself was bad. I meant the planet should move with the camera (aka stay fixed in the same position on the screen and only the ship should move in relation to the screen.

Edit: I have fire up the game and after updating the mod, it seems to be having close to the intended behaviour. It's still not perfect. (the planet should stay absolutely still when moving the camera along with the stars. Now it seems like the planet is moving along the star field. ) Although it seems like the perspective only updates after you actually stop panning when using mouse1 to drag the camera around. Is that a limitation in what the game can engine can do?

a month ago
(updated a month ago)

Edit #438:

Probably the best explanation for the uncanny parallax, is that the planet needs to stay practically, but not completely still with regards to the star layer.

  • The player's top down viewport is probably at most 0.1km-1km away from the platform
  • However both the viewport and the platform are hundreds to thousands of km away from the planet, let alone the stars.

The planet should therefore be a nearly fixed sized in a nearly fixed position when orbiting.
When zooming/panning the planet should barely perceptibly change its scale/positions respectively, but not by much, if at all.

Finally, the final 5,000km approach or departure should be primarily responsible for the actual movement/zoom of the planet.

  • Currently the 14,999 -> 15,000km change results in a comical "blorp!" of the planet suddenly appearing like a balloon.
  • Ideally a gradient of white is layered over the planet PNG, the transparency of said gradient reduces from 5% to 90%, to give the impression of distance/fog/space dust/debris in the way, like motes of dust in a flashlight beam.
  • Very slow expansion of planet scale from a small dot to the final orbit size.
  • Paired with a postional pan from the top/bottom (when arriving/departing) of the map, trying to match the background of stars.
a month ago

I've commented on the parallax in other threads, so I'll just say it's customizable in game to do what you want. Do check out the current available mod settings.

Camera dragging with the mouse is a known limitation noted on the mod page; It's affected other kinds of mods too and I believe there is an API request to allow updating character positions during dragging.

I experimented with fade in quite a bit before settling on having the planet scale up instead. There wasn't a nice way to slowly fade in the planet without creating a very large sprite sheet, at least as far as I was able to see. I'm not sure I fully understand how your gradient idea would work, as surely a white gradient on top of the planet would look pretty bad?

And lastly, as it's not currently possible to read the distance to a platform's destination, I can't start the planet animation until the platform actually arrives at the destination planet. I'd love to render the planet larger as the platform gets closer, but it's not possible in the current API. Again, there's an API request exists for this functionality so I'll be able to mess with this if it gets added in the future.

This thread has been locked.