Restless Souls/Wishlist: Difference between revisions

m
→‎HUD: Color mapping done. Next stop: health animation for hypos ?
m (health bar: color remapping needed)
m (→‎HUD: Color mapping done. Next stop: health animation for hypos ?)
Line 479: Line 479:




'''Color remapping'''
'''Color mapping'''


UE4's progress bar has a fixed range of 0 to 1. In order to realize overpower values (float 1.0 to 2.0) we have to scale everything down to fit into a 0 to 100 percentage range. For now I will try these values:
[[Image:DynamicHealthBarMaterial.png|300px|right|thumb|health bar material where color, shape and progress merge]]
[[Image:HealthBarColorZoneControl.png|300px|right|thumb|integrating a color zone on the health bar]]


            Oni 1     Oni 2
UE4's progress bar has a fixed range of 0 to 1. In order to realize overpower values (float 1.0 to 2.0) we have to scale everything down to fit into a 0 to 100 percentage range.
    %        %
red        0   ->  0
yellow      66  ->  33
green      98  ->  49
green2      100 ->  50 (100% normal health)
new color  200  ->  100 (overpower)


* red (255 0 0)
If we think of the different colors as milestone on a road whereby each milestone is named red, yellow and so on then each every two stones span their own area of interpolated color value. So for UE4's "Lerp (LineraColor)" would will need several alpha ranges, always float values from 0 to 1.
* yellow (255 255 0)
* green (19 161 43)
* green (0 225 0)
* new color (blue / violet ?)




8,018

edits