SebLague / Solar-System

Simple solar system experiment

Home Page:https://www.youtube.com/watch?v=7axImc1sxa0

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How do I work the orbit lines

Pureya opened this issue · comments

I've tried to make the solar system but idk how if I can't see the orbits in the Editor

if it's in unity you could add a particle system to the planet, give it tail/make it a ribbon.. will make a trailing line behind it... for actual orbit lines you need to calculate the trajectory just like the physics do in unity, since this is physics based it's not an easy task, you could just make orbit spheres using billboards and transparent textures with a big circle but you'll get artifacts where they overlap a tad, and over time the physics won't follow that path as the planets get closer to the sun.

Only accurate way is to calculate the trajectory somehow and once you have it you can start and end your line at the planet, then you'll bend it by PI to meet itself like an Ouroboros and also symbolize eternity thusly at least until, again, the physics drive your planets one by one into the almighty Sol.

Can't stand orbit lines myself, they only make sense in elite dangerous because you can't physically see most distant objects, with realistic sightline far objects are always small no matter how big at a distance, that is when they are required and honestly if you're planning on making a space game without automatic targeting/pilot than I hate you.

Just read the title and rethought your question. If all you want to do is make an object orbit another object the best way to do this is with rotatearound in unity script. Physics is kind of stupid for anything but simulations... games are almost never simulations, and when they are they cheat a little. That's why guns aren't in flight simulator, and actual solar systems don't exist in games.. except for astroneer and outter wilds.. and they're tiny, and they suck. But you don't really know what you're doing at all do you? Completely out of your scope. You don't even know unity apparently because if you go and make an object with physics and give it a motion like this very example is meant to show you, you'll have lines, like this example already gives you.

You've completely missed the purpose, I don't mean to be rude I'm just telling you what I see, so when you've spent 10 years on game design and you come back and comment things that make more sense than just "will you code this for me?" we would all be glad to answer those questions for you.

Just read the title and rethought your question, in a third fashion. because I remember when I first looked at this example I couldn't see the orbit lines at first either. I think the solution to that was to run it once, or there was another view or you had to have the object selected. try those in reverse and tell us which one works. ALSO make sure you have correct version of unity.

also star citizen is free to try for another 2 days so download that and see their method, it's not bad