Thumbnail rendering crash

Hi,

We’re experiencing a lot of crashes when opening/saving some of our blueprints, related to the update of the thumbnail.
It seems to occurs when the blueprint contains a ChildActorComponent.

To fix this I changed this function from

bool UPrimitiveComponent::ShouldRenderSelected() const
{
	if (bSelectable)
	{
		if (const AActor* Owner = GetOwner())
		{
			if (Owner->IsSelected())
			{
				return true;
			}
			else if (UChildActorComponent* ParentComponent = Owner->GetParentComponent())
			{
				return ParentComponent->GetOwner()->IsSelected();
			}
		}
	}
	return false;
}

To

bool UPrimitiveComponent::ShouldRenderSelected() const
{
	if (bSelectable)
	{
		if (const AActor* Owner = GetOwner())
		{
			if (Owner->IsSelected())
			{
				return true;
			}
			else if (UChildActorComponent* ParentComponent = Owner->GetParentComponent())
			{
				if(ParentComponent->GetOwner()) 
				{
					return ParentComponent->GetOwner()->IsSelected();
				}
			}
		}
	}
	return false;
}

Thanks.

Hi ,

Would you be able to provide some more information about the crash that you are experiencing? I made a new Blueprint project (using 4.11.1), added a Blueprint, and made several adjustments to the Blueprint with a ChildActorComponent added to update the thumbnail, and was unable to see a crash.

Could you please provide some more information about how your Blueprint is setup and what you are changing when you see the crash occur? Is your Blueprint based on a custom code class? Could you please provide the callstack when the crash occurs? Does the same crash occur in a brand new project?

Ordinarily when someone has found their own fix for an issue, we refer them to GitHub to create a pull request for us to review for inclusion in the Engine. You are free to do so if you wish, but I have so far not been able to reproduce the crash that you have described.

Hi,

Yes, this blueprint is inherited from a custom class, derived from the Vehicle demo.
The attached actor is a character (the pilot). If I sets referenced child actor blueprint to null(sorry, I don’t know what’s are the exact terms in blueprint-wise…maybe “empty” ?) or to the tutorial character, the thumbnail rendering works fine.

The callstack

Thanks.

Hi ,

I have still not been able to reproduce the crash you described. I created a new project using the Vehicle template, then created a new class derived from the vehicle class. I added a ChildActorComponent to the new code class, built the project in Visual Studio, then created a Blueprint of the new code class in the Editor. I made several changes to the ChildActorComponent in the Blueprint, and did not experience a crash. Is there anything in my process that would indicate I am missing something you are doing?

Well I think there is something wrong with our child actor’s blueprint. I’ll make some further tests starting from a basic blueprint, because as I said it doesn’t crash with the tutorial character.
For the moment I’ll attach the actor dynamically at runtime.

I’ll keep you in touch as soon as I have some more information, and many thanks for your time and help.

Hi ,

I just wanted to check in and see if you had found any additional information regarding this issue. Were you able to track down whether the issue was a result of the child actor Blueprint that you were using?

I will go ahead and mark this issue as resolved for now, but if you have any additional information about the issue, it may help future users who run into the same issue.

Hi ,

I’m afraid we didn’t had much time trying to find a simple repro for this.Though the small fix I gave is still relevant amha.

Thanks for your support and time.