# Bug in UWorldPartition::ResolveSubobject()? 

**URL:** <https://forums.unrealengine.com/t/bug-in-uworldpartition-resolvesubobject/2667509>\
**Category:** World Creation\
**Tags:** Epic-Pro-Support, unreal-engine, question\
**Created:** [September 18, 2025, 12:38pm UTC](https://forums.unrealengine.com/t/bug-in-uworldpartition-resolvesubobject/2667509 "2025-09-18T12:38:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous-edc](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous-edc](https://forums.unrealengine.com/u/anonymous-edc)\
**Post date:** [September 18, 2025, 12:38pm UTC](https://forums.unrealengine.com/t/bug-in-uworldpartition-resolvesubobject/2667509/1 "2025-09-18T12:38:33Z")

</div>

Hi,

I’ve run into an issue where UWorldPartition::ResolveSubobject() fails to resolve a subobject path like _!StaticMeshActor\_UAID\_CC96E530724C2F6302\_1896940416.StaticMeshComponent_0. Looking at the code I believe that the call to GetActorDescInstanceByPath() is using SubObjectName where it should be using SubObjectContext because with paths like this not SubObjectName won’t match any actor descriptor since it is the name of the component. This is what the code currently looks like.

```auto
bool UWorldPartition::ResolveSubobject(const TCHAR* SubObjectPath, UObject*& OutObject, bool bLoadIfExists)
{
	// ...
#if WITH_EDITOR
		else
		{
			// Support for subobjects such as Actor.Component
			FString SubObjectName;
			FString SubObjectContext;	
			if (!FString(SubObjectPath).Split(TEXT("."), &SubObjectContext, &SubObjectName))
			{
				SubObjectName = SubObjectPath;
			}

			if (const FWorldPartitionActorDescInstance* ActorDescInstance = GetActorDescInstanceByPath(SubObjectName))
			{
				if (bLoadIfExists)
				{
					LoadedSubobjects.Emplace(this, ActorDescInstance->GetGuid());
				}

				OutObject = StaticFindObject(UObject::StaticClass(), GetWorld()->PersistentLevel, SubObjectPath);
				return true;
			}
		}
#endif
	}

	return false;
}

```

This is what I believe it should look like.

```auto
bool UWorldPartition::ResolveSubobject(const TCHAR* SubObjectPath, UObject*& OutObject, bool bLoadIfExists)
{
	// ...
#if WITH_EDITOR
		else
		{
			// Support for subobjects such as Actor.Component
			FString SubObjectName;
			FString SubObjectContext;	
			if (!FString(SubObjectPath).Split(TEXT("."), &SubObjectContext, &SubObjectName))
			{
				SubObjectContext = SubObjectPath;
			}

			if (const FWorldPartitionActorDescInstance* ActorDescInstance = GetActorDescInstanceByPath(SubObjectContext))
			{
				if (bLoadIfExists)
				{
					LoadedSubobjects.Emplace(this, ActorDescInstance->GetGuid());
				}

				OutObject = StaticFindObject(UObject::StaticClass(), GetWorld()->PersistentLevel, SubObjectPath);
				return true;
			}
		}
#endif
	}

	return false;
}

```

For my use-case, ResolveSubObject() works the way I expect it to after these changes. Is this a bug or is there something I’m missing?

Best regards

Michael Andersson

---

<div class="post-metadata">

**Author:** ![ColonelDube](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/coloneldube/32/924285_2.png) [@ColonelDube](https://forums.unrealengine.com/u/ColonelDube)\
**Post date:** [September 22, 2025, 7:00pm UTC](https://forums.unrealengine.com/t/bug-in-uworldpartition-resolvesubobject/2667509/2 "2025-09-22T19:00:30Z")

</div>

Hi Michael.

I tested it and indeed it was broken, and your fix was good. I submitted it in Main at CL#46076927 and should be reflected on GitHub shortly.

JF
