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"

change button image at runtime (blueprint)

Hi,

I have a widget blueprint that I want to use in my HUD. It is basically a 'Button' that has a child of type 'Image'. When I click the button (there are several in my HUD), I want it to have a 'button selected' look by changing the image into something else. The button will remain 'selected' until another one is clicked.

I feel like a complete idiot, but I just cannot get this to work ... Hopefully one of you can help me ... I have already tried many tutorials, but it seems like I'm always missing something important. I think I'm supposed to use a material instance with a parameter, or maybe a dynamic material, ... ???

Product Version: Not Selected
Tags:
more ▼

asked May 09 '15 at 12:44 PM in Blueprint Scripting

avatar image

siska
43 4 6 10

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

2 answers: sort voted first

Hi,

go into your Widget, open the Event Graph and do this:

alt text

Capture is the "Get Image". Change the values of the open inputs. If you want to change the image then just use Set Brush from texture.

Cheers

brushexample.jpg (69.0 kB)
more ▼

answered May 09 '15 at 04:43 PM

avatar image

Raidfire.Net
672 62 57 118

avatar image siska May 10 '15 at 09:05 AM

How can it be this simple ??? I can't believe I wasted a week trying to figure this out ... Thank you very much !

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

Some super advanced way to change button image that is now possible with the power of Unreal Engine:

alt text

more ▼

answered Jun 15 '16 at 10:15 PM

avatar image

spaceharry
402 22 30 139

avatar image mertyildiran Aug 09 '17 at 04:02 PM

This answer is certainly better!

avatar image Augbrite Jan 31 '19 at 01:54 PM

Thank you, that was a great solution!

(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