Move Blueprint actor components to C++ w/o losing reference

I’m using UE4.26.2.

Originally, I had a base Blueprint class that a few different actors derived from. This BP has 3 actor components (a static mesh, widget, and sphere). I’ve now decided to create a base C++ class that this blueprint will inherit from. I’m planning to move all logic from the BP class into this new C++ class. I also want to move these BP actor components into the C++ base class, but I’m running into an issue.

If I remove the components from the BP and add them in C++ (ensuring that the components have the same name), then every child actor that had a custom static mesh set now defaults to null. In C++, I’ve set the property specifiers for these components to be EditAnywhere and BlueprintReadWrite.

For instance, this is what I see when I view one of these actors that had already been placed in a level before my changes:
image
And this is what I see if I place a new actor into the level:
image

I don’t see a way around this issue. It looks like my two choices are:

  • Manually copy each child’s static mesh reference to the new C++ component.

  • Keep the blueprint actor components and work around this in C++.

Is there a solution I’m missing?

Even if you give components the same name, for the engine they’re not the same components, so if you truly want to move them to c++, you’ll have to manually setup them in children and instances again.
As a workaround, you can get references to the components in c++ by component tags or otherwise, and then work with them in code.

I personally would love to see something similar to "meta = (BindWidget)" but for blueprints.