Importing a moon with 50 million polygons

Hello, I wanted to import the moon model that I created in blender (with a total weight of 1.5 gigabytes and 50 million polygons…) into Unreal Engine 5, but I can’t help but do it because I get the following error:

LoginId:291f8e4e46dfdf8c2ddb479877a32289
EpicAccountId:0ff075f05cae4f50b69443721312f3f5

Fatal error: [File:D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Serialization\MemoryWriter.h] [Line: 49] TMemoryWriter with IndexSize=4 does not support data larger than 2147483647 bytes. Archive name: None.

UnrealEditor_Engine!TMemoryWriterBase<TSizedDefaultAllocator<32> >::Serialize() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Serialization\MemoryWriter.h:49]
UnrealEditor_Chaos!Chaos::operator<<<3>() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\ChaosCore\Public\Chaos\Vector.h:1334]
UnrealEditor_Chaos!Chaos::TBox<float,3>::SerializeAsAABB() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\Box.h:481]
UnrealEditor_Chaos!Chaos::operator<<<Chaos::FAABBVectorized,TSizedDefaultAllocator<32> >() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\ChaosArchive.h:389]
UnrealEditor_Chaos!Chaos::FTrimeshBVH::Serialize() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\TriangleMeshImplicitObject.h:281]
UnrealEditor_Chaos!Chaos::FTriangleMeshImplicitObject::SerializeImp() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\TriangleMeshImplicitObject.h:659]
UnrealEditor_Engine!Chaos::FChaosArchive::SerializePtrChaos::FTriangleMeshImplicitObject() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\ChaosArchive.h:238]
UnrealEditor_Engine!Chaos::FChaosArchive::SerializePtrChaos::FTriangleMeshImplicitObject() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\ChaosArchive.h:269]
UnrealEditor_Engine!Chaos::operator<<<Chaos::FTriangleMeshImplicitObject,TSizedDefaultAllocator<32> >() [D:\build++UE5\Sync\Engine\Source\Runtime\Experimental\Chaos\Public\Chaos\ChaosArchive.h:479]
UnrealEditor_Engine!FChaosDerivedDataCooker::Build() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\PhysicsEngine\Experimental\ChaosDerivedData.cpp:119]
UnrealEditor_DerivedDataCache!UE::DerivedData::Private::FDerivedDataCache::FBuildAsyncWorker::DoWork() [D:\build++UE5\Sync\Engine\Source\Developer\DerivedDataCache\Private\DerivedDataCache.cpp:495]
UnrealEditor_DerivedDataCache!FAsyncTaskBase::DoWork() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Async\AsyncWork.h:289]
UnrealEditor_DerivedDataCache!FAsyncTaskBase::Start() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Async\AsyncWork.h:276]
UnrealEditor_DerivedDataCache!UE::DerivedData::Private::FDerivedDataCache::GetSynchronous() [D:\build++UE5\Sync\Engine\Source\Developer\DerivedDataCache\Private\DerivedDataCache.cpp:604]
UnrealEditor_Engine!GetDDCBuiltData() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\PhysicsEngine\BodySetup.cpp:1340]
UnrealEditor_Engine!UBodySetup::GetCookedData() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\PhysicsEngine\BodySetup.cpp:1416]
UnrealEditor_Engine!UBodySetup::GetCookedFormatData() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\PhysicsEngine\BodySetup.cpp:392]
UnrealEditor_Engine!UBodySetup::CreatePhysicsMeshes() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\PhysicsEngine\BodySetup.cpp:423]
UnrealEditor_Engine!UStaticMesh::ExecuteBuildInternal() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\StaticMeshBuild.cpp:496]
UnrealEditor_Engine!UStaticMesh::BatchBuild() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\StaticMeshBuild.cpp:352]
UnrealEditor_Engine!UStaticMesh::Build() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\StaticMeshBuild.cpp:133]
UnrealEditor_Engine!UStaticMesh::Build() [D:\build++UE5\Sync\Engine\Source\Runtime\Engine\Private\StaticMeshBuild.cpp:376]
UnrealEditor_UnrealEd!UnFbx::FFbxImporter::PostImportStaticMesh() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxStaticMeshImport.cpp:2381]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::RecursiveImportNode() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:2259]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::RecursiveImportNode() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:2278]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::ImportAllStaticMesh() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:2143]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::FactoryCreateBinary() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:1173]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::FactoryCreateBinary() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:910]
UnrealEditor_UnrealEd!UFbxSceneImportFactory::FactoryCreateFile() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Fbx\FbxSceneImportFactory.cpp:892]
UnrealEditor_UnrealEd!UFactory::ImportObject() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\Factories\Factory.cpp:206]
UnrealEditor_AssetTools!UAssetToolsImpl::ImportAssetsInternal() [D:\build++UE5\Sync\Engine\Source\Developer\AssetTools\Private\AssetTools.cpp:4123]
UnrealEditor_AssetTools!UAssetToolsImpl::ImportAssets() [D:\build++UE5\Sync\Engine\Source\Developer\AssetTools\Private\AssetTools.cpp:2979]
UnrealEditor_UnrealEd!FEditorFileUtils::Import() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:1594]
UnrealEditor_UnrealEd!FEditorFileUtils::Import() [D:\build++UE5\Sync\Engine\Source\Editor\UnrealEd\Private\FileHelpers.cpp:1533]
UnrealEditor_LevelEditor!TBaseStaticDelegateInstance<void __cdecl(void),FDefaultDelegateUserPolicy>::ExecuteIfSafe() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Delegates\DelegateInstancesImpl.h:777]
UnrealEditor_Slate!FUIAction::Execute() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Public\Framework\Commands\UIAction.h:139]
UnrealEditor_Slate!FUICommandList::ExecuteAction() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Commands\UICommandList.cpp:117]
UnrealEditor_Slate!SMenuEntryBlock::OnClicked() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\MultiBox\SMenuEntryBlock.cpp:1158]
UnrealEditor_Slate!SMenuEntryBlock::OnMenuItemButtonClicked() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\MultiBox\SMenuEntryBlock.cpp:1118]
UnrealEditor_Slate!V::TBaseSPMethodDelegateInstance::Execute() [D:\build++UE5\Sync\Engine\Source\Runtime\Core\Public\Delegates\DelegateInstancesImpl.h:281]
UnrealEditor_Slate!SButton::ExecuteOnClick() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Widgets\Input\SButton.cpp:465]
UnrealEditor_Slate!SButton::OnMouseButtonUp() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Widgets\Input\SButton.cpp:390]
UnrealEditor_Slate!SMenuEntryButton::OnMouseButtonUp() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\MultiBox\SMenuEntryBlock.cpp:434]
UnrealEditor_Slate!FEventRouter::Route<FReply,FEventRouter::FToLeafmostPolicy,FPointerEvent,FSlateApplication::RoutePointerUpEvent'::8’::<lambda_2> >() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:442]
UnrealEditor_Slate!FSlateApplication::RoutePointerUpEvent() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:5279]
UnrealEditor_Slate!FSlateApplication::ProcessMouseButtonUpEvent() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:5857]
UnrealEditor_Slate!FSlateApplication::OnMouseUp() [D:\build++UE5\Sync\Engine\Source\Runtime\Slate\Private\Framework\Application\SlateApplication.cpp:5813]
UnrealEditor_ApplicationCore!FWindowsApplication::ProcessDeferredMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:2243]
UnrealEditor_ApplicationCore!FWindowsApplication::DeferMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:2750]
UnrealEditor_ApplicationCore!FWindowsApplication::ProcessMessage() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:1919]
UnrealEditor_ApplicationCore!FWindowsApplication::AppWndProc() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsApplication.cpp:929]
user32
user32
UnrealEditor_ApplicationCore!FWindowsPlatformApplicationMisc::PumpMessages() [D:\build++UE5\Sync\Engine\Source\Runtime\ApplicationCore\Private\Windows\WindowsPlatformApplicationMisc.cpp:145]
UnrealEditor!FEngineLoop::Tick() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\LaunchEngineLoop.cpp:5850]
UnrealEditor!GuardedMain() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Launch.cpp:180]
UnrealEditor!GuardedMainWrapper() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:118]
UnrealEditor!LaunchWindowsStartup() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:258]
UnrealEditor!WinMain() [D:\build++UE5\Sync\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:298]
UnrealEditor!__scrt_common_main_seh() [D:\a_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288]
kernel32
ntdll

I read every post on the Internet but nothing helped (and there were about 100 of them), I want to make a solar system, but I can’t split the moon because I need 2 objects so that it doesn’t lag))) I have 64 Gigabytes of RAM, and rtx 2080super with 40 gigabytes, but this didn’t help me very much:\ I wait a little over an hour, then I see the message that the import is 80% complete and the application crashes,

I would ask you please hurry up because I need to create about 4 billion planets)

There is no universe in which you should need a 50 million triangle moon. Even with Nanite compression, that’s going to take up way more system memory than it could possibly justify.

Decimate it to 10% of that. Bake out a displacement map and use Nanite tesselation and displacement if you really want that level of detail.

Really, you just use a smooth sphere and Nanite tesselation and height maps for all your planets (though 4 billion unique height maps is still going to be an impossibly large data set.)

From some of your other posts it seems like you’re trying to make something like Elite: Dangerous meets Kerbal Space Program. Both of which use heavily procedural systems to generate their planets. You’ve got a lot of work ahead of you.

1 Like

Don’t do it like that. Split it, and load it in partitions as the player progresses on the moon.

thank you, I know) This model of the moon perfectly depicts every crater and this is the very minimum number of polygons, yesterday I had 75 million in total, now I’ve reduced it, but I’m very sorry to reduce it further (… maybe you can divide it into the same parts and then unite? but I don’t know how to remove the double vertices and connect all the parts so that the material fits correctly

I tried, but firstly I don’t have a normal texture, and secondly there will be distortion due to projection onto 2D, because there is no way to make a projection of a sphere onto 2D, I’m thinking of doing it in combination, dividing the moon into approximately 50 sections, but still parts of the ball, and load them, and in the distance there is a moon with approximately 1 million polygons

And plus I’m going to do it all online :smiley:

You would need to make something along the lines of this tutorial

OFC you would need to translate it into Unreal’s procedural mesh.

There is no way you can keep whole star systems in memory. You have to generate then at runtime to keep the memory footprint low.

Terrain textures would also be best with a combination of perlin noise filters layered and baked with filters.

and can I do it automatically with a script?:thinking: I have approximate coordinates of a third of all stars in the milky way, all that remains is to make them orbits around the milky way automatically, each system is a separate level, and generate the rest of the systems automatically. Is it theoretically possible?

Before you build a game of this type you need to build the technology to generate a solar system. There is no silver bullet in this case. You need to build it yourself.

You will also run into problems like floating point errors the further away you are from point 0,0,0 of the world.

Look into any procedural generation math

It’s not an easy task. To be honest it’s almost at the level of coding an MMO with the amount of custom tech.

The more you know about coding the humbler you will become about your goals. Not to discourage you but you might be biting off more than you can chew.

1 Like

and generate them automatically only when the player flies there, and save the parameters by proximity if the player has not landed on this planet, and so this information can be stored on servers, theoretically:

  • Exoplanet: 4 gigabytes
  • Normal planet: 2 gigabytes
  • Pluto-type object: 900 megabytes (0.9 gigabytes)
  • Moon: 1.5 gigabytes
  • Sun: 900 megabytes (0.9 gigabytes)
  • Orbit: 100 megabytes (0.1 gigabytes)
  1. Data on the number of objects:
  • Total stars: 200 billion (200 * 10^9)

  • Exoplanets: 40 billion (40 * 10^9)

  • Normal planets: 1.5 planets per star. Total: (200 * 10^9 * 1.5 = 300 * 10^9 ) planets

  • Pluto-like objects: Let’s say one per star. Total: 200 billion (200 * 10^9)

  • Moons: Let’s say one moon per planet and exoplanet. Total: (40 * 10^9 + 300 * 10^9 = 340 * 10^9 ) moons

  • Sun: One sun per star. Total: 200 billion (200 * 10^9)

  • Orbits: One per star, planet, exoplanet, moon, and Pluto-like object.

  • Exoplanet data: ( 40 * 10^9 ) * 4 GB

  • Normal planet data: ( 300 * 10^9 ) * 2 GB

  • Pluto-type data: ( 200 * 10^9 ) * 0.9 GB

  • Moon data: ( 340 * 10^9 ) * 1.5 GB

  • Sun data: ( 200 * 10^9 ) * 0.9 GB

  • Orbit data: ( (200 * 10^9 + 300 * 10^9 + 40 * 10^9 + 340 * 10^9 + 200 * 10^9) * 0.1 GB )

  • Exoplanets: ( 40 * 10^9 * 4 = 160 * 10^9 ) GB

  • Normal planets: ( 300 * 10^9 * 2 = 600 * 10^9 ) GB

  • Pluto-type objects: ( 200 * 10^9 * 0.9 = 180 * 10^9 ) GB

  • Moons: ( 340 * 10^9 * 1.5 = 510 * 10^9 ) GB

  • Suns: ( 200 * 10^9 * 0.9 = 180 * 10^9 ) GB

  • Orbits: ( 1080 * 10^9 * 0.1 = 108 * 10^9 ) GB

Summing up the data
( 160 * 10^9 + 600 * 10^9 + 180 * 10^9 + 510 * 10^9 + 180 * 10^9 + 108 * 10^9 = 1738 * 10^9 ) GB

So the total data size will be 1738 petabytes (1 petabyte = 10^6 gigabytes).

So roughly if players explore the entire galaxy on servers it will take approximately 1738 petabytes.

I’m far from alone in doing all this)

Then I would suggest having a meeting with your team. Look into the technology required. Davide up the work into smaller tasks and get things done.

The thing is you can’t have a star system with petabytes of data.
The transfer alone of data over the net alone would kill any project through server costs.

You need to only save the seed of a planet needed to regenerate it on the local machine.
But this require an editor of planets that can generate a planet based on parameters that in the end spits out a long string that encodes all of the parameters unique to that planet.

You have to take into account
a) your server capacity / possible calculations
b) your clients target machine

Bandwidth costs money so keep the information at a minimum especially if you go with AWS

I’d read up on all of the devlogs you can get your hands on regarding space sims.

look through the GDC vault
https://gdcvault.com/
or gamedeveloper (formally Gamasutra)

There are lots of technical articles, there is bound to be at least one or two regarding planet tech.

I certainly doubt the advisability of a meeting of 7 friends living a kilometer from each other at one in the morning) but you are still right, I think for each planet you need to generate some kind of key that will be sent to you on it, and the planet will be generated the same as other people’s, I know I explained it poorly but still something like seed in Minecraft, but different

in extreme cases, with a weak computer of the players, you can make an automatic command to the “autopilot” and make a landing like in Starfield, but without the restrictions of invisible walls

thereby hiding the planet’s load, theoretically, this can reduce the data to a minimum of 50 petobytes, but what is a lot anyway, plus you need to save the players’ buildings and spaceships, I have a small idea, but again, I need to check on a small scale, I have also already checked the approximate creation of one star system in approximately 5 seconds, if you do not count the freeze for half an hour, then this seems to be possible, but still, even in the best case scenario, I will finish in a couple of decades, well, or I will give it to my grandchildren to finish, maybe in the future the Internet will be better)

These tutorials to through mesh generation
You would still need to deform them into a sphere.

I tried to make the moon like this but I still couldn’t make a smooth sphere, it turned out to be more of a square oval, and plus such a system ate up a lot of FPS, so it was easier for me to create it through blender, I have no idea how to adequately bend it into something at least resembling a sphere, but still thanks for the information and help

I think this video would be better suited for creating planets, although I’m probably wrong https://youtu.be/KbVpX60-A1g?si=V4z_vGGslN2asG0z

Seems to have most of the tech you need for the planets themselves. Though custom tech would be more extensive.

WorldScape Plugin - Making real planets and Endless worlds

I know about this plugin, but I still don’t have an extra 11 thousand hryvnia or $350, and I still don’t know what’s better, the voxel plugin or this one, and plus they are the same price, they cost half my computer, although I can theoretically ask a friend from Ukraine to give it to me😁, but still piracy is not very adequate in my opinion, I may be thinking that the free version of the voxel plugin will help me, but still there is no main line for generating a planet and I have already built a mathematical node for it, cobbled together from 5 tutorials, but I feel these 2 plugins are the only way out for me… but they are too realistic, you could say, and will take up a lot of memory