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"

How to add dynamically an image in the HUD ?

Hello I currently develop a minigame, a very simple one to learn UE4.

The goal of this game is to pick up some banana or apple and each time I picked up a banana, I want to add an image banana.png on the right of the previous in the HUD and each time I picked up an apple, I want to add an image apple.png on the right of the previous in the HUD.

So my question is how to add a png image in the hud with the Blueprint Scripting.

Thanks in advance :D

Product Version: UE 4.8
Tags:
more ▼

asked Oct 22 '15 at 11:53 AM in Blueprint Scripting

avatar image

Riuy
3 2 2 4

(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

Several of the UMG UI Widgets have the ability to render an image. The most obivous one is the Image Widget. To add multiple bananas into a row, you could use Wrap Box (or any other Widget with slots). Just create (Create widget "item") one of these, set the image and add the widget to your slotted panel.

The wildwest shootout example content project has a HUD which shows all the connected players. it's actually the exact same principle, so I suggest you look at this.

more ▼

answered Oct 22 '15 at 12:43 PM

avatar image

Enlo
859 23 9 40

avatar image Enlo Oct 22 '15 at 12:47 PM

PS: Search for "RefreshListMacro" on the wildwest documentation page, there you can see the whole blueprint for adding items to a list in UMG!

alt text

avatar image Riuy Oct 25 '15 at 03:45 PM

Thanks I will check it :)

(comments are locked)
10|2000 characters needed characters left
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