Abstraction of UPrimitiveComponent and ghost of components

I’ve got two components in my Actor:

class SPACE_PROTOTYPE_API AShip : public AActor
{
...
	TSubobjectPtr<UPrimitiveComponent> m_RootPrimitive;
	TSubobjectPtr<UShipMovementComponent> m_MoveComponent;
...

In constructor, I’m initializing them:

AShip::AShip(const class FPostConstructInitializeProperties& PCIP) : Super(PCIP)
{
m_RootPrimitive = PCIP.CreateDefaultSubobject<UPrimitiveComponent>(this, TEXT("PrimitiveBase"));
m_MoveComponent = PCIP.CreateDefaultSubobject<UShipMovementComponent>(this, TEXT("ShipMoveComponent"));

RootComponent = m_RootPrimitive;

m_MoveComponent->UpdatedComponent = m_RootPrimitive;

Material = NULL;
PrimaryActorTick.bCanEverTick = true;
}

Now creating blueprint basing on actor AShip. Adding it to level. Choosing it and in details I see transformation node. Saving level, closing UE4 Editor. Opening it, choosing created object in level and there is no transformation node in details anymore. I must destroy this object and create new one to make it appear.
But, If I create a derivied from UPrimitiveComponent class and will use it in AShip - then it’s fine.

What’s the catch ? Because of abstraction of UPrimitiveComponent? Can’t see any abstract function in it actually.

Any sugesstions ?

Hi Alanir,

I tried to reproduce this issue, but was not able to do so. What version of the Engine are you using, and are you using the Engine installed by the Launcher, or did you build the Engine from source code? Does this only happen in your project, or are you able to reproduce it with a new project?

Hi, .
Thanks for the answer.

I can reproduce the problem in another project. Some correction: after your first compiling of project (if object of your class already exists in scene), you should recompile shader, save it and restart the UE4. Right after that the problem will appear

UE4 binary, not from the sources. 4.4.2-2289767
x64

This problem reproduces on another work station in company.

Is this the transformation node that is not visible to you?

,
Yes exactly.

Hi.

Have you reproduced problem?

Hi Alanir,

I am very sorry, I lost track of this post. I have not been able to reproduce this issue (I currently have the binary version 4.4.3). The only difference I can see between my code and the code that you provided was the ShipMovementComponent class. I am guessing that is a custom class that you created, since I do not have that class. I used the MovementComponent class instead. If you use MovementComponent instead of ShipMovementComponent, do you see the same results?

I did notice some unusual behavior where the Blueprint that I had placed in the level would sometimes have its position reset to the world origin (0, 0, 0) when I reopened the project. I always had the Transform section visible, though.

Hi, .

class SPACE_PROTOTYPE_API UShipMovementComponent : public UMovementComponent

I’ll try just MovementShip

Hi Alanir,

I just realized that this post has been sitting for a while. Is this issue still being problematic for you?

Hi Alanir,

We have not heard from you for a little while. I have still not been able to reproduce the issue you described. Is it still causing problems for you? If you can reproduce the issue in a new project and upload the project, I would be happy to take a look at that to see if I can determine what is happening. I will mark this as resolved for now, but please feel free to re-open this issue at any time if you need any additional help.