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"

Asset reference variables in details

 class ------_API UTalent : public UObject  
 class ------_API UTalentActive : public UTalent


 UCLASS(Blueprintable, ClassGroup = (Custom), meta = (BlueprintSpawnableComponent))
 class ------_API USheetTalents : public UActorComponent
 UPROPERTY(EditAnywhere, BlueprintReadOnly)
     TArray<class UTalentActive*> ActiveTalents;

alt text

RedFlower is a blueprint deriving from UTalentActive, which derives from UTalent. I am trying to add it to the array ActiveTalents in the SheetTalents component of an actor, through the editor (the same way you could add a ParticleSystem asset to a ParticleSystemComponent as the template). For some reason, I can't; I get a red dotted box around the variable when I try drag-in-dropping it in, and can't select it in the drop-down menu. Is there something I'm missing? I have tried a non-array variable and making a non-const TalentActive.

EDIT: Realized that RedFlower is a class, not an instance; which means the variable needs to be TSubClassOf, not UTalentActive*. I cannot seem to find a way of making an instance of it or TalentActive. Is there a way?

Product Version: UE 4.9
bp.png (5.6 kB)
more ▼

asked Sep 17 '15 at 03:57 PM in C++ Programming

avatar image

110 8 10 14

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

1 answer: sort voted first

Yes, NewObject(UClassName::StaticClass());

more ▼

answered Sep 17 '15 at 06:59 PM

avatar image

37.8k 937 172 1123

avatar image NullBlack Sep 17 '15 at 07:01 PM

I meant as an asset.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
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