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"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

How can i make health system like this

https://www.youtube.com/watch?v=gWhU7OnRvIM&t=140s Need help with this and might start from scratch so any help would be cool

Product Version: UE 4.18
Tags:
more ▼

asked Mar 06 '18 at 03:39 AM in Blueprint Scripting

avatar image

Jakupiii
30 12 12 17

avatar image Nebula Games Inc Mar 06 '18 at 03:49 AM

What part of that exactly are you trying to create? I could see multiple features in there.

  1. Basic health meter, decreases as player takes damage

  2. Recharge level, health regained during rest

  3. Some link between combo punches that decreases total health but still allows a portion to be regained.

Do you need a health meter exactly like that or do you just want to make a generic "health bar" and need help starting?

avatar image Jakupiii Mar 06 '18 at 04:11 AM

The part i dont get is there is 2 bars the bar on top goes down, then if you stop taking dmg it regens hp but if u take dmg while regening it clamps the progress bar to the bar on top. i already have the basic functions working like taking dmg and regening etc but this part idk

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

1 answer: sort voted first

Honestly, never made one like that before. I started messing around with it though and I think you can probably do it by using the "overlay" option in the widget/UMG editor. I put 2 progress bars in the overlay. One is the player's current health, similar to the green bar in the video, the other in the background (red bar) is the player's "max" health. Set the first bar to have a background image alpha of 0, this way the red bar shows through when the green bar decreases. Set the red bar (the one behind the green bar) to have a black background. So when you decrease it there is a black "image" behind it. I got a very quick prototype working with some super basic logic but I got 2 bars on top of each other. It is late so I haven't had a chance to give you logic that will work for how to manipulate both bars independently in the exact way you want but I think that is easy enough to do you can probably figure it out. Hope this helps!

more ▼

answered Mar 06 '18 at 05:35 AM

avatar image

Nebula Games Inc
5.3k 27 9 14

(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