So I have a subscene added to my scene. It contains some gameobjects that have Authoring components that are baked. But they show up in all worlds. But they don’t seem to be detected by the queries… I’m still working on it, but I’d like the entities to be created in a Certain World.
How do I make them bake on a certain world? Is there something in the baker that needs to be added?
Subscenes are baked / serialized into boxes that are only identified by the source subscene GUID with no other context. Worlds are entirely an in-the-moment construct, so I think what you’re asking for is more accurately making the runtime subscene loading selective about the destination worlds. On that front, the SubScene MonoBehaviour used for authoring and activation at runtime specifically loads the subscene into all worlds, so you will need to disable the AutoLoadScene property and control loading manually. The relevant APIs are in the SceneSystem type and the SceneGUID property of the SubScene MB.
Other info about scene loading
1 Like
Adds the scene to all worlds, indeed. The entities show up in all worlds… Then the query with the component all of them have doesn’t return anything… I’ll have to study this much better. Thanks a lot