Details panel in Blueprint suddenly blank for components added via C++ (was working, now empty)

I’ve added some components to a blueprint via C++, and it was working great. I added a particle system, and a box collider. The problem however is after I closed and re-opened the Unreal editor, the details panel for both of these components is now entirely blank:

I’ve tried re-compiling from Visual Studio, doing a quick compile in Unreal, closing Unreal and deleting the Binary/Intermediated/Saved folders and having Unreal rebuild the project files - but nothing has worked. I’m pretty stumped now on how to get the detail panels back for code that was working.

In the .h, the components are defined as such:

	UPROPERTY(EditAnywhere)
	USceneComponent* SceneRoot;

	UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "UFO")
	class UNiagaraComponent* BeamParticles;

	UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "UFO")
	class UBoxComponent* CollisionBox;

And in the constructor of the .cpp they are setup like this:

	SceneRoot = CreateDefaultSubobject<USceneComponent>("SceneRoot");
	SceneRoot->SetupAttachment(this->GetRootComponent());

	BeamParticles = CreateDefaultSubobject<UNiagaraComponent>("BeamParticles");
	BeamParticles->SetupAttachment(SceneRoot);

	CollisionBox = CreateDefaultSubobject<UBoxComponent>("TractorBeamCollider");
	CollisionBox->SetCollisionProfileName(TEXT("Trigger"));
	CollisionBox->SetupAttachment(SceneRoot);
	CollisionBox->OnComponentBeginOverlap.AddDynamic(this, &ATractorBeam::OnOverlapBegin);
	CollisionBox->OnComponentEndOverlap.AddDynamic(this, &ATractorBeam::OnOverlapEnd);

Thanks in advance for any help anyone can give!

2 Likes

I ended up deleting and re-making the Blueprint derived from this C++ class, and that fixed it. I just had to then re-populate all the detail panel data I had applied previously. I guess it just got corrupted somehow?

1 Like

In my experience, if you make big changes in C++, it is sometime needed to reboot the engine for the classes to compile without error or remake blueprint. This blank details panel is another effect from the same cause.

I had the same problem with blank components and couldn’t find a solution, finally I deleted the blueprint and created a new one, it’s a shame that there is no other way to fix this :frowning:

I really can’t accept this as an answer to this problem, there has to be another way around this. I have been working (without C++) on characters that all inherit from an abstract class, and occasionally after engine crash, the details panel displays exactly as shown in your screenshot.

This doesn’t have anything to do with modifying C++ files on my end, thankfully I have an SVN set up, but surely there has to be information on this somewhere.

I got a workaround by creating another blueprint of the same type and then use the merge tool in the blueprint editor to copy the default value from the new one to the one broken one.

1 Like

I’ve hit this issue myself numerous times, and it’s a real killer. Recreating Blueprints from scratch isn’t feasible if you’ve got lots of Blueprint changes and code, and can set you back weeks.

The only thing worth offering here is some advice. Keep on top of your Version Control as much as possible, and don’t leave it took long before committing your Blueprint changes. Accept that any changes that haven’t been committed could be lost without warning.

If you do run into this scenario, revert back to a recent commit where you don’t have this problem. Copy the BP that is getting corrupted to another folder, and then check out to your latest commit again. Now overlay the backup copy you just made. You will have lost your recent and uncommitted modifications to that single BP, but if you’re keeping on top of your version control, hopefully it won’t take too long to reinstate :frowning:

Any time you run a c++ project not from the IDE you risk losing c++ components. This can also cause a break in any parent class based on c++ code. Most of the time re-parenting can fix this though it does risk breaking references.

You can also try reverting files from the auto backup if you are lucky.

I found an easy way to fix this: simply rename the component class name and the component details panel will come up again.

This happened to me after adding a new USceneComponent and renaming one of them. It seemed to be fixed after restoring the original name and deleting the new USceneComponent, but after a lot of changes trying to get it working, I ended up creating a new Blueprint from the modified C++ class.

Luckily they were pretty simple blueprints, but this is very annoying. There has to be a cleaner solution rather than revert everything to an older changeset. I think it’s very common to add new components via C++, and if this keeps happening from time to time…

Any updates on this? It’s really annoying.