x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Blueprint variables are reset when recompiling c++ code

I have a c++ blueprint with some variables defined like this.

 UPROPERTY(EditAnywhere, BlueprintReadWrite, Meta = (MakeEditWidget = true))
 TArray<FTransform> fooTransforms;

I have been creating a couple of blueprint assets out of this class, and have been editing the default values. But if I recompile the class all the values get reset back to 0. If I were to add a boolean variable for example, the array would become empty. How do I avoid this?

Link to a project demonstrating this

Before uncommenting the bool and recompiling

After uncommenting the bool and recompiling

This happens at least in versions 4.18.0 and 4.18.1.

Similar threads mention double checking that the constructor does not default the values, but as you can see in the demo project, the constructor has only the default bCanEverTick variable set to true.

Product Version: UE 4.18
Tags:
more ▼

asked Nov 19 '17 at 02:51 PM in Using UE4

avatar image

tagoth
1 2

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question