EditInlineNew, DefaultToInstanced class gets reset on blueprint compile

Hey,
I have a UClass

UCLASS(EditInlineNew, DefaultToInstanced)
class UBattlecryFireMode : public UObject
{
    GENERATED_UCLASS_BODY()
    ...
};

and that in a TArray property

UPROPERTY(Instanced, EditDefaultsOnly, Category=Config)
TArray<UBattlecryFireMode*> FireModes;

In the blueprint (a weapon) I can instance/select any of UFireMode’s derived classes, modify them and all but whenever I compile the blueprint any elements of the array get reset. So if I have 4 elements set and modified, after compilation I have an array with 4 elements set to None.

Any ideas what could cause that?

1 Like

Just started working with a similar thing where I encounter this same problem.
The only difference is that my class does not have the flag ‘DefaultToInstanced’.

Using the engine from source, as of writing the latest version (4.6.1), release branch. Commit Hash: a56889f061d0d897f4bc3f1736afb27a0bf10358

Yeah nothing has changed it seems. It works totally fine with just a normal property, but arrays get reset…

Maybe it is an idea to move this over to Bug Reports?
You should be able to do so as the creator of the question.

This is still a problem.

Hi Schlechtwetterfront,

The issue that you described is very similar to one that we are already investigating (UE-7055). I ran some tests with the information you provided, and in version 4.6.1 I was able to see the same results that you described. However, when I ran the same test in 4.7 Preview 4, the array elements were not reset when clicking Compile. The same was true in our latest internal version of the Engine. It looks like we may have this issue fully resolved very soon.

This issue still exists in 4.7.1 realease

Hi ,

The ticket that I mentioned above is still open. I just ran through my test case for this issue again using our latest internal build and I am still seeing the same incorrect results. I have not run the test case in 4.7.1. I suspect that the results I saw in 4.7 preview 4 did not reflect an actual fix.

This issue still exist in Unreal Engine 4.10.1

Please look into it guys its a pain in the ■■■ as all array element need to be replaced whenever a compile happens which suck. =(

I checked the status of the ticket that was created for this issue. It had been replaced with a new ticket (UE-21890) which has a fairly high priority. Unfortunately we do not have an estimate for when this will be corrected yet. I updated the new ticket with your additional interest in having this issue addressed.

I have the same issue but only in UUserWidget and even without TArray: Instanced EditInLineNew settings are deleted for UUserWidgets - UI - Unreal Engine Forums

We hope this Blueprint Class “EditInlinenNew” plugin (which no longer requires any C++ to use the EditInlinenNew feature) will help you. :muscle: