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"

Is there a way to change a variable on a 3D Widget in a BP on construct?

We have a system we are building that uses 3d widget in a blueprint. We want to be able to change text in the widget on construct through a variable on the parent blueprint but we cant seem to figure it out. Any ideas? There will be multiple versions of this in a single level too, so I don't think I can just get all actors of class on the widget.

Product Version: UE 4.19
Tags:
more ▼

asked Apr 16 '18 at 10:30 PM in Blueprint Scripting

avatar image

PDubulous
113 7 14 22

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

2 answers: sort voted first

One pattern I've used lately is that I have a User Widget variable on the child widget's class, which I immediately set to the parent widget's reference after constructing the child. Then within the child widget, I can cast to the parent's class and access its variables.

A better pattern is to use Interfaces, so that you don't have to cast, and multiple parent classes can work equally well from the child as long as they all implement the Interface.

But if you don't anticipate more than one or two types of parent widgets being involved with the child's widget class, you can just cast within the child, or vice versa.

more ▼

answered Apr 17 '18 at 04:16 PM

avatar image

mightyenigma
3.8k 18 20 20

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

We were trying to change the variables of a 3D widget on on construct within a BP. After researching several other suggestions, it doesn't look like it can be done anymore. We tried functions and all sorts of different work arounds. We were trying to change the text in a 3d widget so that it would be visible in the editor. We couldnt make it work in BPs.

more ▼

answered Apr 17 '18 at 09:01 PM

avatar image

PDubulous
113 7 14 22

(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