Ultimate space simulation software

 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

23 Feb 2020 08:49

I've been pulling my hair out since this was suggested a few months ago trying to do this, and I've created something that works. I'm (mostly) happy with the result, and it's super easy to use. Here is the completed file converter: 
US2 to SE Converter 1.1.zip
(506.99 KiB) Downloaded 98 times

2/27/20 - fixed runtime problem, also rotation period is now supported. Axial tilt is planned but I don't know the equations yet. 

There are instructions in the readme file when you download it, but a video format can be found here: 
https://youtu.be/0Z4PdGNjLMI

DISCLAIMER:
Remember that a file from US2 is just an instance of the system at the time of export, so the values converted will NEVER be 100% accurate. Especially if you have a system that is broken at the time of export (like one planet crashing into another), this converter will give you extremely weird results. 

DISCLAIMER #2
Binary orbits DO NOT work. At least, not completely. The program will generally calculate the semi-major axis (mostly) correctly, but all other values are useless. If you have binary orbits in US2, SE will render them after conversion, but they will look wrong. You will have to open the .sc file and manually edit those values if you want them to look correct. I wish there was something I could do about it, but I don't know if the problem is with the formulas or if binary orbits are too complex to calculate with just an instance of information. And I'm not a physics major, by any stretch of the word, so if anyone has suggestions please feel free to let me know. 

As always, if something goes wrong, or if you have problems other than weird binary orbits, please tell me about it and we will fix the problem together. I'm sure you will have issues, but for the general case system, hopefully, there will not be any problems. 

And if you would like to make fun of my code, you can find it on GitHub:
https://github.com/SethFusion/US2-to-SE-Converter

Old files:
► Show Spoiler
Last edited by SFGameZ64 on 27 Feb 2020 11:05, edited 1 time in total.
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
Theloic971
Space Tourist
Space Tourist
Posts: 37
Joined: 05 Sep 2017
Contact:

Universe Sandbox 2 to SE File Converter NEW

23 Feb 2020 10:12

This is awesome ! Great job !
Do you want to archive your discoveries in Space Engine ? Use my new website : https://se-archive-project.net/
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

24 Feb 2020 14:13

This is amazing! How'd you pull it off?
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

24 Feb 2020 16:28

Theloic971 wrote:
This is awesome ! Great job !

longname wrote:
This is amazing! How'd you pull it off?

Thank you. Basically I just got restless and learned the math behind it. It still isn't perfect but I didn't want to wait for SE to update, so I did what I could. 
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
Salvo
Pioneer
Pioneer
Posts: 374
Joined: 03 Nov 2016
Location: Veneto, Italy
Contact:

Universe Sandbox 2 to SE File Converter NEW

26 Feb 2020 05:39

Good job mate!
You have my respect.
The universe is not required to be in perfect harmony with human ambition.

CPU: Intel Core i7 4770 GPU: Sapphire Radeon RX 570 RAM: 8 GBs
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

26 Feb 2020 12:49

I like how you actually put the file you want converting into a folder and press a button and it comes out of the other end. Very skeuomorphic, lol. A bit of advice, binary orbits break because the orbit is calculated relative to the star and not the barycenter. The orbits wobble to make the planets go up and down so they go around each other, but the orbits freeze in SE as they are.
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

26 Feb 2020 13:01

Tried running it and it's missing vcruntime140d.dll, msvcp140d.dll, vcruntime140_1d.dll and ucrtbased.dll. Why am I getting these problems?
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

26 Feb 2020 16:02

longname wrote:
Tried running it and it's missing vcruntime140d.dll, msvcp140d.dll, vcruntime140_1d.dll and ucrtbased.dll. Why am I getting these problems?

I'm not sure. It doesn't use any fancy headers that I haven't used before, so I'll have to look into it. I hope not everyone is having that problem. What kind of computer do you have? Windows 10, or something else?"

Also, for the binary orbits, as far as I know technically yes you are correct. But that is only for simulations. Theoretically, the barycenter holds the velocity that takes the system around the star, but the planets relative to each other must calculate their orbit relative to the barycenter. For instance, open up SE and look at the velocity of Earth, the Moon, and the Earth-Moon barycenter. The barycenter is moving quite fast, while the Earth only has a velocity ~12m/s around the Moon. Technically it is moving much faster than that, around the star, but because its own system center is the barycenter, we don't have to worry about that. 

Unless I'm wrong about that, then please let me know. Again, sorry you are having issues, I'll try to fix it soon. 
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

27 Feb 2020 11:09

longname wrote:
Tried running it and it's missing vcruntime140d.dll, msvcp140d.dll, vcruntime140_1d.dll and ucrtbased.dll. Why am I getting these problems?

An update from Visual Studio must have changed some settings and the .exe wasn't compiled with the proper .dll files included. I recompiled and hopefully have fixed the problem. The file size is 10x larger, but still under 1 megabyte. Please download the new file above and tell me if it works for you. If it does not, there may still be problems I need to address. 
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

27 Feb 2020 12:55

SFGameZ64 wrote:
longname wrote:
Tried running it and it's missing vcruntime140d.dll, msvcp140d.dll, vcruntime140_1d.dll and ucrtbased.dll. Why am I getting these problems?

An update from Visual Studio must have changed some settings and the .exe wasn't compiled with the proper .dll files included. I recompiled and hopefully have fixed the problem. The file size is 10x larger, but still under 1 megabyte. Please download the new file above and tell me if it works for you. If it does not, there may still be problems I need to address. 

It's worked, thank you!
Quality of life suggestion, automatically create a catalogs > stars/planets folder in the output folder
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

27 Feb 2020 13:06

It keeps throwing things out of orbit. With my first test, the orbits were shuffled slightly, but in my second test, a moon that was in a stable orbit around a planet had been flung off.
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

27 Feb 2020 13:25

longname wrote:
It keeps throwing things out of orbit. With my first test, the orbits were shuffled slightly, but in my second test, a moon that was in a stable orbit around a planet had been flung off.

Is there any way you can give me the .simulation file you are converting so I can check it out?
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

28 Feb 2020 07:35

SFGameZ64 wrote:
longname wrote:
It keeps throwing things out of orbit. With my first test, the orbits were shuffled slightly, but in my second test, a moon that was in a stable orbit around a planet had been flung off.

Is there any way you can give me the .simulation file you are converting so I can check it out?

Holl around Etern was stirred up a bit, and the planet Nomad inside the Viet and Nistrader system I was OK with being messed up, but the moon Nomad around Nomai was completely flung around. It's supposed to be in a perfectly stable orbit around Nomad. Plus, Viet and Nistrader don't work properly. One of the systems can't go around the barycenter faster than the other. The moon Retror is supposed to go opposite of Prog, hence the name, and one of the habitable moons was boiled.
Attachments
simulation.rar
Etern System
(871.93 KiB) Downloaded 43 times
simulation.rar
Viet and Nistrader System
(875.43 KiB) Downloaded 44 times
Etern and Viet.pak
SE Catalog - both systems contained inside file.
(5.68 KiB) Downloaded 46 times
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]
 
User avatar
SFGameZ64
Astronaut
Astronaut
Topic Author
Posts: 44
Joined: 24 May 2017

Universe Sandbox 2 to SE File Converter NEW

28 Feb 2020 11:34

Okay, I'm going to try to address these problems one by one. I'll say, first of all, you have very... complex... systems. I'm honestly impressed at the stability of some of them  :lol:

Holl around Etern was stirred up a bit, and the planet Nomad inside the Viet and Nistrader system I was OK with being messed up,

Remember that the converter is only working with what the system looks like at the time you export the simulation file. So large orbital changes over time will be totally ignored. Even small changes over the course of hours can't be considered, so things will never look 100% perfect. 

but the moon Nomad around Nomai was completely flung around.

This was a weird one. I looked into it and it seems like a logical error on my part. In the simulation file, Nomai is considered a planet, which caused it to go through the planet section of code when it should have gone through the moon section. That shouldn't technically be a problem, but it just so happens that they were orbiting a binary system, which broke the logic of my code. I'll look into fixing that. 

One of the systems can't go around the barycenter faster than the other.

I said up above that binary orbits aren't calculated properly, including orbital period. Almost all of the orbital values for binary objects are useless, and until I find a fix, you'll have to fix that data yourself. 

The moon Retror is supposed to go opposite of Prog

After a quick look, I don't immediately know what the problem here is. Space Engine is having a hard time reading Retror as a child of the system, even though it looks fine in the file. I suspect the binary object that was created between terra Flora and Prog is to blame, but I don't know why yet. 

and one of the habitable moons was boiled.

Unfortunately, SE calculates all temperatures for planets. I can't do anything about this one.

Midterms are this upcoming week and I'll be gone this weekend, so give me some time to look into the other issues. Thank you for bringing them to my attention though; complex systems and edge cases like yours I couldn't have tested on my own. Even if it doesn't work perfectly, I hope it cuts out 95% of the process for converting these things from scratch. 
Better known as Seth Fusion
A little generator I made - http://forum.spaceengine.org/viewtopic.php?f=3&p=27881#p27881
 
User avatar
longname
Space Pilot
Space Pilot
Posts: 149
Joined: 13 Apr 2017
Location: ∞/The Multiverse/The Universe/Local Cluster/The Milky Way/Orion Arm/Sol System/Earth-Moon/Earth/UK

Universe Sandbox 2 to SE File Converter NEW

28 Feb 2020 12:21

SFGameZ64 wrote:
Source of the post Remember that the converter is only working with what the system looks like at the time you export the simulation file. So large orbital changes over time will be totally ignored. Even small changes over the course of hours can't be considered, so things will never look 100% perfect. 

But the predicted orbits and trails are very stable and don't wobble.
Thanks for replying!
[dah<500,26>dah<180,14>dah<180,21>dah<500,19>dah<180,26>dah<500,21>]

Who is online

Users browsing this forum: No registered users and 1 guest