Are there any default actors in a newly created level?

I’m trying to cling to an actor in a streaming level to use as owner for my spawned saved actors, that we’re not part of that level initially.

Basic loading functionality that should already be in the engine, but yeah…

I don’t want to have to add a “spawner” actor to each new level I create.

Thanks.

Hey there @AllGamesSuck! Just so I understand the question and use case, is your question is related to transferring the ownership of actors spawned in different streaming levels? You mentioned a spawner as an anchor. Do you want the actor to become owned by the streamed in level it currently occupies and not the original it came from?

To answer the question of the title, I believe the level blueprint (while hidden) is always attached to even blank levels.

By default, ownership doesn’t matter as much as which level it is tagged as when FActorSpawnParameters is read upon spawning.

1 Like

I use blueprints. I want to avoid C++. The SpawnActorFromClass node doesn’t have an option for which level to spawn in. So the actors will spawn in Persistent.

Then I want to immediately change their owner to a specific streaming level that’s already loaded. But since they can only accept an actor as owner, I need an actor from that specific streaming level as owner, so that when that level is unloaded, these actors get unloaded with it. That’s it.

Please, let me know if it doesn’t make sense.

You mean the level blueprint is actually an actor in the level? That I can get using GetActorFromClass?

I found LevelScriptActor. I’ll use that. Thanks.

2 Likes