ChildActorComponent-duplicates when saving new Level

Hi,

I used to have problems with my ChildActorComponents being duplicated in older UE4-versions, which luckily were resolved. I noticed with 4.13 though, that whenever I save my level under a new name (or overwrite another level than the one I would save to when using ctrl + s) all my ChildActorComponents get duplicated. I didn’t do very thorough tests, but here’s my example: I have torchholders in my game, each with a torch that is a ChildActorComponent. As you can see in the scene-outliner in screenshot 1, everything is fine: The actor has exactly one torch.

http://puu.sh/r2V5P/11b6ebabd6.jpg

Between screenshot 1 and screenshot 2 I saved the level under a new name (ctrl + s doesn’t cause those problems.) As you can see, now the actor has two such components. Every time I save like this, one component is added and unfortunately I don’t really know how to get rid of them. I can’t select the component in question in the outliner, except if I remove the parent-actor completely beforehand.

http://puu.sh/r2V6S/e102224e25.jpg

Since I did a backup of my level a few versions back and didn’t encounter the issue (Just checked: No duplicates in my old backup), I would assume it’s a relatively new bug. I hope you have enough info. I wasn’t sure what else to add. Thanks for reading :slight_smile:

Hello HammelGammel,

I was unable to reproduce this issue on our end. I have a few questions for you that will help narrow down what issue it is that you are experiencing.

Quick questions:

  1. Can you reproduce this issue in a clean project?
  2. If so, could you provide a detailed list of steps to reproduce this issue in a clean project?
  3. Could you provide screen shots of any blueprints that may be involved with this issue?

Hey Rudy,

I can reproduce it, here’s how I do it:

1: I create a fresh project using the first person C++ template.

2: I create a new blueprint and pull the character-blueprint (The one that comes with the template) in the components-tab of the newly created blueprint to create a new ChildActorComponent (Works with other actorclasses too)

3: I place the new blueprint in the level and save. Now I create a copy of the level by saving under a new name

4: If I move the new blueprint now, there’s one more instance of the character-blueprint in the level.

Interestingly with the fresh project the duplicates of the ChildActorComponent aren’t attached to their initial parent anymore and I can move them around freely. Maybe that’s why you couldn’t reproduce it? For me it’s not listed as a child this time around. Here you can see the problem in action:

http://puu.sh/r31PA/14793aba0e.jpg

The white sphere is the normal static-mesh-component of the blueprint, the root of the actual blueprint-instance I placed. The other two characters floating around are the duplicates of the ChildActorComponent. 2 of them since I saved twice.

Now this was the easiest way for me to reproduce it. In my actual project I wrote the class with the ChildActorComponent in C++.

This is the declaration:

UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = Mesh)
	class UChildActorComponent* TorchComponent;

And in the constructor:

TorchComponent = CreateDefaultSubobject<UChildActorComponent>(TEXT("Torch"));
	FAttachmentTransformRules AttachmentRules = FAttachmentTransformRules(EAttachmentRule::SnapToTarget, true);
	TorchComponent->AttachToComponent(RootComponent, AttachmentRules, NAME_None);

I hope that helps.

Hello HammelGammel,

After further testing I was able to reproduce this issue on our end. I have written up a report and I have submitted it to the developers for further consideration. I have also provided a link to the public tracker. Please feel free to use the provided link for future updates.

Link: Unreal Engine Issues and Bug Tracker (UE-35680)

Make it a great day