From 96c73c5587fad53583752d5112d557248f1697d3 Mon Sep 17 00:00:00 2001 From: Rob Kelly Date: Mon, 18 Nov 2024 01:58:09 -0700 Subject: [PATCH] Power gauge & life bar HUD elements --- asset_dev/UI/gauge_patch.xcf | Bin 0 -> 8338 bytes asset_dev/UI/gauge_patch_large.xcf | Bin 0 -> 7824 bytes asset_dev/UI/lifebar_patch.xcf | Bin 0 -> 19831 bytes asset_dev/UI/power_gauge_tab.xcf | Bin 0 -> 5995 bytes assets/ui/gauge_patch.png | 3 + assets/ui/gauge_patch.png.import | 34 +++++++++ assets/ui/lifebar_fill_grey.png | 3 + assets/ui/lifebar_fill_grey.png.import | 34 +++++++++ assets/ui/lifebar_patch.png | 3 + assets/ui/lifebar_patch.png.import | 34 +++++++++ assets/ui/power_gauge_fill.png | 3 + assets/ui/power_gauge_fill.png.import | 34 +++++++++ assets/ui/power_gauge_tab.png | 3 + assets/ui/power_gauge_tab.png.import | 34 +++++++++ src/player/debug_player.tres | 1 + src/player/world_player.gd | 10 +++ src/ui/shot_hud/shot_hud.gd | 10 ++- src/ui/shot_hud/shot_hud.tscn | 97 ++++++++++++++++++++++--- 18 files changed, 291 insertions(+), 12 deletions(-) create mode 100644 asset_dev/UI/gauge_patch.xcf create mode 100644 asset_dev/UI/gauge_patch_large.xcf create mode 100644 asset_dev/UI/lifebar_patch.xcf create mode 100644 asset_dev/UI/power_gauge_tab.xcf create mode 100644 assets/ui/gauge_patch.png create mode 100644 assets/ui/gauge_patch.png.import create mode 100644 assets/ui/lifebar_fill_grey.png create mode 100644 assets/ui/lifebar_fill_grey.png.import create mode 100644 assets/ui/lifebar_patch.png create mode 100644 assets/ui/lifebar_patch.png.import create mode 100644 assets/ui/power_gauge_fill.png create mode 100644 assets/ui/power_gauge_fill.png.import create mode 100644 assets/ui/power_gauge_tab.png create mode 100644 assets/ui/power_gauge_tab.png.import diff --git a/asset_dev/UI/gauge_patch.xcf b/asset_dev/UI/gauge_patch.xcf new file mode 100644 index 0000000000000000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L-_7vQrxt;x?gOO1JwP7 ziC<*5nCGQl=D7g-4E7W37uYWB4os&SMy;$GOdE1&bRescJYgVl=YPB`1R@=#>iEc5Wy^RSymz<7G&ED6P(#ZGA?xW=? zJw0nu&@`nz*IVQO^?YmMB%kL*FS~uh=Q}~>C{pIHvep!x#>Y+%4V@-)6g>#Z+GVX4 zE~C!nvu7`pIf@>HWbLw63x9i=jLyuB)5f1lo{x_k%S3I+Vx9oFQSJL5jKk(s3xD`4 zDQ;RWhktF619Ze%a&=bX*=mWEvb78l2uATee5pKQdUMP0x7}ym=vfuKvY(? zv)Fqc_8azJ$Dy)=gdi$0cMPM|kS!5N9A2tsF(RI=msp(@d9GSy#T+lza>ZPrsN|F) zP_zQHn3Iu;K#Fka(GI}J58-S8e=b2d{58;VsO%sih)T>I!)P^RO9T>!7ppmpi0A4> z2v^|wYJnBH((QV{UwXx`At`ML%7&|EO&Cb1w&C z#?dofo#`s(xR>>s=ksJTab^KB**CLx=Q7p74&E1+=s_ZDKYef6WlM&}&8zR-7CAtD z@0<9)buMR{&gCq2N!EETcLXXsNMM(M=tFfb=bFyt9E8g`&*hFlWd{ie2ci$vxtwo0 zm-7%V?>v_~0+k&kARLJPe=gG@-D951_xxaf6prOC^GFqb!1!8fU`^NMfv2RpW)9H6 zb0%JAQSPlqS=7s;HE+}#h$>zs3KZYuK%-t6sR$$rhi`p5z}lnhvJF_*<&HyiUA9RG zq7rk*Fj@`S5`o0w(W)1Xac@0}TVI6xs}UCQ^GMAf@dqM`Ux@%kD?lTD8L0>)0*4;$ z0DS1WYy;MHx#JLBmu(V)sKnecj8;RoL?Cf^r0Pdw++UACxF8Q#gDe>4!CE*N4g{63 z5(J7?fCj@dQV~cH4n5id_|SFP2CVCH$052d+av^0iMeAKt%hugK;rOVHH^l1xE|bx H*X2I}RKYjG literal 0 HcmV?d00001 diff --git a/asset_dev/UI/gauge_patch_large.xcf b/asset_dev/UI/gauge_patch_large.xcf new file mode 100644 index 0000000000000000000000000000000000000000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_patch.xcf b/asset_dev/UI/lifebar_patch.xcf new file mode 100644 index 0000000000000000000000000000000000000000..205fca5d86d00ff2af75a67d93ffee43e78bc2db GIT binary patch literal 19831 zcmeHPdvH|Oc|Ug_TCId0U;%o7S3HF<*kB$8BzaS3uqTQ0_%9DnQ!o~?92t9nCUH8o z^pD2V#I4%c>0~-doS7;!ai-mg12KzJV;qAK592DbF|nKgErB{FF<4@?(n@>#`+et} zd#{9qQ%^}7#>;$rzw@0>=kdMHIp5wxOY4IV*M4=&*4i(xSh-T+vk9<*2tNM^m=16p zeBA&j{3u8Sd@2ADzyiQ5gOhJ2U;t3kf~J>mdFa6ho44&mS+R1)N4Ga`-r0O#?N?fN z-d}sy$3FQP)|3lt>w}wHnwPh1Z@rH+a{tSc9XlUsYp&h#P+RML^+ijzwrqK*?V;_p zOXRV9d&|9>Ygfp>mG!8;carLrwepYEU)}NW<}Iz;T54C_iqa#tv~n#+1J3^JCkBLlv;9Q|$3rb7?&5nvrL_KM@NT;hb|Akcj?{VUwG%g&j02=|Ks$pf7SoXH(r0O_ur2n zJ6wc6Emf!7{Ag~(@cr(>J8zTk6!=cQ@p|7cG+)>)Bj4EQNY=LZTj4`{Z~pS+iPwJd z>hYt8T)8a)iVuWWg!ngDYU&ROu zrNt0i3^Klbjzc_!uHQJ($Eh4Cloo~28zZ|WF?L)3bXNP{t%v!`du25QkAYqdm7dscsX zghq(QaKs?Ora^zsl%kpQuiv6YXyJsV#aKX!7h#HGI%jBNG(~AKBrO)&Ia4^a2-=uG zMhYh+Eymqb+8_pC+vwS-1wESvkI+L)RowkGEoT^t7Dlf@kMXdw4bo^uIu|KL8m;jb zV`9=^v3pva1q1YFV%01&k>-k_6SkJ23s5K8U^zbc3audm%@yhCg3Z{1orbucxM%(aROtNIAQEUD`!HS5D9@#>*k#CE$f6u zGIz!a`j$*8phJpWTZN7jA#Jx*jb}Yp*RS=`2X&Yr-zXf$`YMIw@j;eHuZR-f0R4c6 zKn9_YixSZFzyN1#o!VN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 z6HMZ115X=x+Q8EWo;L8bfu{{Tpj;bx+Q1XgcpG?PG|>hgP<)-_(2o3&Kk`j6GHu{N zJhKfvZQyYOJU;OFz~cjt4?I5b_`u@>4=CpYj}JTnjr+h8qX{2)K=E~wLp$V4Q z$oRm6c%~0LKJa)7&wsx*JNv9Pnq~if>(Zr*ZuQjB$qf6~h7cR~?|yW-{_Q8y_`kfl z@#)p-QTl$}+`N6^_;8A)#g>2h)M%0oi>-TCPNs%fM)W_s^vxkQBKmiK{A_}aivEq4 z6FTwx7iV>r6@wcu66^ctp5nweFF(gwP7L1ru4Es-EZLnUVw<0qaqPhFEJ;4NU6i{w zPD*z5dFkPv`?TaA+X+sAx|g4q0dJSbbprC)#iI!Vw(;(%At3EZP893(I~vP(^i_;4 z-qBXYodd0Yb5)J2a=v=7HE8aGA=w)H6M%r-QtWq%eW2KyV!u-Cmx{fq*c+1NUPorI z&y@rI5@nifjg)zlGRLe*l}NU-vM!Tr+AY+jtFK{f^RBigZXIa%-8D6?$@$vB_Q2f- zL$W>gX8-~FM6us1_Mu|$EB0%}-cjsr#eObX?mRMseXbVpIm$HI9;tDcGRMrNN+jD^ zS(nLm?I!Bd)7LTjyr->;n+N>9x30!@IbT2M54?RaB>l0!0tnb&6#JuMHx>I(vG)~w zSFv{#dt0*H&yX4HbLRqnnlerLBj>nBnPcWrC6azt)diny2k_}~5T7ki;3Frb^ZLDr LM7yMwhxY#fZ5r(Z literal 0 HcmV?d00001 diff --git a/assets/ui/gauge_patch.png b/assets/ui/gauge_patch.png new file mode 100644 index 0000000..123d714 --- /dev/null +++ b/assets/ui/gauge_patch.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d7b36366a7e401222e6cddd81e07f9da3f09ddbc2e3a67a9381938e8f9568003 +size 917 diff --git a/assets/ui/gauge_patch.png.import b/assets/ui/gauge_patch.png.import new file mode 100644 index 0000000..eb12da2 --- /dev/null +++ b/assets/ui/gauge_patch.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b5812y3pmmgg5" +path="res://.godot/imported/gauge_patch.png-b06ef6737fda05dbce8a7a52b995acf4.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/ui/gauge_patch.png" +dest_files=["res://.godot/imported/gauge_patch.png-b06ef6737fda05dbce8a7a52b995acf4.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/ui/lifebar_fill_grey.png b/assets/ui/lifebar_fill_grey.png new file mode 100644 index 0000000..87b1986 --- /dev/null +++ b/assets/ui/lifebar_fill_grey.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5799039d5ae50304dc4fe7608ea5454b2676d36170d736240fbef71254e589f3 +size 2196 diff --git a/assets/ui/lifebar_fill_grey.png.import b/assets/ui/lifebar_fill_grey.png.import new file mode 100644 index 0000000..b2d910f --- /dev/null +++ b/assets/ui/lifebar_fill_grey.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dtdqninlnu10o" +path="res://.godot/imported/lifebar_fill_grey.png-c028996d6e86e26137270a39216a5fd3.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/ui/lifebar_fill_grey.png" +dest_files=["res://.godot/imported/lifebar_fill_grey.png-c028996d6e86e26137270a39216a5fd3.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/ui/lifebar_patch.png b/assets/ui/lifebar_patch.png new file mode 100644 index 0000000..c571e90 --- /dev/null +++ b/assets/ui/lifebar_patch.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8eaaf2f5c8b2ca563e98b6b0fdf1be835e65b6279be2f690138da5753ddc6c0e +size 1121 diff --git a/assets/ui/lifebar_patch.png.import b/assets/ui/lifebar_patch.png.import new file mode 100644 index 0000000..adcb043 --- /dev/null +++ b/assets/ui/lifebar_patch.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bvwh0yunmvirp" +path="res://.godot/imported/lifebar_patch.png-768842f340e38f78b7b90bbcd2d8dff9.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/ui/lifebar_patch.png" +dest_files=["res://.godot/imported/lifebar_patch.png-768842f340e38f78b7b90bbcd2d8dff9.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/ui/power_gauge_fill.png b/assets/ui/power_gauge_fill.png new file mode 100644 index 0000000..a106a45 --- /dev/null +++ b/assets/ui/power_gauge_fill.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d3b1fe74605c1da390924fce16d663092d6f2c910966a32fb3ba429d4d46d53d +size 665 diff --git a/assets/ui/power_gauge_fill.png.import b/assets/ui/power_gauge_fill.png.import new file mode 100644 index 0000000..558a5b3 --- /dev/null +++ b/assets/ui/power_gauge_fill.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://76fjx2ukavqe" +path="res://.godot/imported/power_gauge_fill.png-b7c279ae4fc601ab214f21b9b72d50c3.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/ui/power_gauge_fill.png" +dest_files=["res://.godot/imported/power_gauge_fill.png-b7c279ae4fc601ab214f21b9b72d50c3.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/ui/power_gauge_tab.png b/assets/ui/power_gauge_tab.png new file mode 100644 index 0000000..ecc6fc9 --- /dev/null +++ b/assets/ui/power_gauge_tab.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc2a5b9ed04b1cb7235d495f8d70bdd21744b901b7bedd5ff74d68d751bffcac +size 1152 diff --git a/assets/ui/power_gauge_tab.png.import b/assets/ui/power_gauge_tab.png.import new file mode 100644 index 0000000..c020de1 --- /dev/null +++ b/assets/ui/power_gauge_tab.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://4a8tvjgwegv3" +path="res://.godot/imported/power_gauge_tab.png-7979d59b50c40895525fdf1648e50b30.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/ui/power_gauge_tab.png" +dest_files=["res://.godot/imported/power_gauge_tab.png-7979d59b50c40895525fdf1648e50b30.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/src/player/debug_player.tres b/src/player/debug_player.tres index 7a431d3..8eaef6f 100644 --- a/src/player/debug_player.tres +++ b/src/player/debug_player.tres @@ -9,6 +9,7 @@ [resource] script = ExtResource("4_8ybyj") name = "DEBUG Gfolfer" +life = 100.0 driver = ExtResource("1_sn8fd") iron = ExtResource("2_piku2") wedge = ExtResource("5_wm4ae") diff --git a/src/player/world_player.gd b/src/player/world_player.gd index 3754757..ace2d5d 100644 --- a/src/player/world_player.gd +++ b/src/player/world_player.gd @@ -1,8 +1,18 @@ class_name WorldPlayer extends Resource ## Container for the state of the player within the world. +signal on_life_changed(new_value: float) + +@export_range(0, 100) var life: float = 100.0: + set(value): + if value != life: + life = value + on_life_changed.emit(value) + +@export_category("Profile") # TODO character select @export var name: String = "Gfolfer" +@export var color: Color = Color("ff7070") @export_category("Equipment") @export var driver: Club diff --git a/src/ui/shot_hud/shot_hud.gd b/src/ui/shot_hud/shot_hud.gd index 6bc1810..1e0e9d9 100644 --- a/src/ui/shot_hud/shot_hud.gd +++ b/src/ui/shot_hud/shot_hud.gd @@ -1,8 +1,9 @@ class_name ShotHUD extends Control ## HUD for main gameplay loop -@onready var power_bar: ProgressBar = %PowerBar +@onready var power_bar: TextureProgressBar = %PowerBar @onready var curve_bar: ProgressBar = %CurveBar +@onready var life_bar: TextureProgressBar = %LifeBar @onready var club_selector: ClubSelector = %ClubSelector @@ -14,6 +15,8 @@ class_name ShotHUD extends Control @onready var _nice_animation: AnimationPlayer = %NiceAnimation @onready var _wasted_animation: AnimationPlayer = %WastedAnimation +@onready var _player_name: Label = %PlayerName + @onready var _state: AnimationNodeStateMachinePlayback = hud_state_machine["parameters/playback"] @@ -21,7 +24,10 @@ class_name ShotHUD extends Control func set_state_for_player(player: WorldPlayer) -> void: print_debug("Setting HUD for player ", player.name) club_selector.set_state_for_player(player) - # TODO life + _player_name.text = player.name + # TODO animate on life loss? + life_bar.value = player.life + life_bar.tint_progress = player.color # TODO special equipment # TODO abilities diff --git a/src/ui/shot_hud/shot_hud.tscn b/src/ui/shot_hud/shot_hud.tscn index 0abc3b0..af8c3e3 100644 --- a/src/ui/shot_hud/shot_hud.tscn +++ b/src/ui/shot_hud/shot_hud.tscn @@ -1,9 +1,15 @@ -[gd_scene load_steps=28 format=3 uid="uid://c4ifdiohng830"] +[gd_scene load_steps=34 format=3 uid="uid://c4ifdiohng830"] [ext_resource type="Script" path="res://src/ui/shot_hud/shot_hud.gd" id="1_x5b4c"] [ext_resource type="Shader" path="res://src/shaders/canvas_retro.gdshader" id="1_ybxxp"] [ext_resource type="PackedScene" uid="uid://445qd7m4qe2j" path="res://src/ui/shot_hud/club_selector/club_selector.tscn" id="2_1hdub"] [ext_resource type="Script" path="res://src/ui/decorations/rumbler.gd" id="3_6groq"] +[ext_resource type="Texture2D" uid="uid://b5812y3pmmgg5" path="res://assets/ui/gauge_patch.png" id="4_5kcpe"] +[ext_resource type="Texture2D" uid="uid://76fjx2ukavqe" path="res://assets/ui/power_gauge_fill.png" id="5_3i1yq"] +[ext_resource type="Texture2D" uid="uid://4a8tvjgwegv3" path="res://assets/ui/power_gauge_tab.png" id="6_sw48q"] +[ext_resource type="FontFile" uid="uid://dsa0oh7c0h4pu" path="res://assets/fonts/Racing_Sans_One/RacingSansOne-Regular.ttf" id="8_bejx4"] +[ext_resource type="Texture2D" uid="uid://bvwh0yunmvirp" path="res://assets/ui/lifebar_patch.png" id="9_4f1d7"] +[ext_resource type="Texture2D" uid="uid://dtdqninlnu10o" path="res://assets/ui/lifebar_fill_grey.png" id="10_130v7"] [sub_resource type="Animation" id="Animation_3xds6"] resource_name = "RESET" @@ -281,7 +287,7 @@ length = 0.001 tracks/0/type = "bezier" tracks/0/imported = false tracks/0/enabled = true -tracks/0/path = NodePath(".:value") +tracks/0/path = NodePath("../Rumbler/PowerBar:value") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { @@ -292,7 +298,7 @@ tracks/0/keys = { tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true -tracks/1/path = NodePath("%PowerBar/..:intensity") +tracks/1/path = NodePath("../Rumbler:intensity") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { @@ -308,18 +314,18 @@ length = 1.618 tracks/0/type = "bezier" tracks/0/imported = false tracks/0/enabled = true -tracks/0/path = NodePath(".:value") +tracks/0/path = NodePath("../Rumbler/PowerBar:value") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "handle_modes": PackedInt32Array(0, 0), -"points": PackedFloat32Array(0, -0.25, 0, 0.233333, 0.0884774, 1, -0.267469, -0.483539, 0.25, 0), +"points": PackedFloat32Array(0, -0.25, 0, 0.233333, 0.598765, 1, -0.351333, -0.246032, 0.25, 0), "times": PackedFloat32Array(0, 1.618) } tracks/1/type = "value" tracks/1/imported = false tracks/1/enabled = true -tracks/1/path = NodePath("%PowerBar/..:intensity") +tracks/1/path = NodePath("../Rumbler:intensity") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/keys = { @@ -561,22 +567,43 @@ grow_horizontal = 2 grow_vertical = 2 script = ExtResource("3_6groq") -[node name="PowerBar" type="ProgressBar" parent="ShotGauges/PowerGauge/Rumbler"] +[node name="PowerBar" type="TextureProgressBar" parent="ShotGauges/PowerGauge/Rumbler"] unique_name_in_owner = true -custom_minimum_size = Vector2(30, 0) +visible = false +texture_filter = 5 +custom_minimum_size = Vector2(64, 0) layout_mode = 1 anchors_preset = 15 anchor_right = 1.0 anchor_bottom = 1.0 grow_horizontal = 2 grow_vertical = 2 -mouse_filter = 1 max_value = 1.0 +step = 0.01 fill_mode = 2 +nine_patch_stretch = true +stretch_margin_left = 16 +stretch_margin_top = 16 +stretch_margin_right = 16 +stretch_margin_bottom = 16 +texture_under = ExtResource("4_5kcpe") +texture_progress = ExtResource("5_3i1yq") + +[node name="TitleTab" type="TextureRect" parent="ShotGauges/PowerGauge/Rumbler/PowerBar"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -8.0 +offset_right = 19.0 +offset_bottom = 48.0 +grow_horizontal = 0 +texture = ExtResource("6_sw48q") +stretch_mode = 2 [node name="PowerAnimation" type="AnimationPlayer" parent="ShotGauges/PowerGauge"] unique_name_in_owner = true -root_node = NodePath("../Rumbler/PowerBar") +root_node = NodePath(".") libraries = { "": SubResource("AnimationLibrary_coah5") } @@ -634,3 +661,53 @@ unique_name_in_owner = true root_node = NodePath("%HUDStateMachine/..") tree_root = SubResource("AnimationNodeStateMachine_osrbp") anim_player = NodePath("../HUDAnimation") + +[node name="SouthWest" type="MarginContainer" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 0.333 +anchor_bottom = 1.0 +offset_top = -40.0 +offset_right = 40.0 +grow_vertical = 0 +theme_override_constants/margin_left = 16 +theme_override_constants/margin_bottom = 16 + +[node name="VBoxContainer" type="VBoxContainer" parent="SouthWest"] +layout_mode = 2 +theme_override_constants/separation = -8 + +[node name="HBoxContainer" type="HBoxContainer" parent="SouthWest/VBoxContainer"] +layout_mode = 2 + +[node name="Spacer" type="Control" parent="SouthWest/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(24, 0) +layout_mode = 2 + +[node name="PlayerName" type="Label" parent="SouthWest/VBoxContainer/HBoxContainer"] +unique_name_in_owner = true +layout_mode = 2 +theme_override_colors/font_shadow_color = Color(0, 0, 0, 1) +theme_override_colors/font_outline_color = Color(0, 0, 0, 1) +theme_override_constants/shadow_offset_x = 3 +theme_override_constants/shadow_offset_y = 0 +theme_override_constants/outline_size = 2 +theme_override_constants/shadow_outline_size = 2 +theme_override_fonts/font = ExtResource("8_bejx4") +theme_override_font_sizes/font_size = 32 +text = "PLAYER NAME" + +[node name="LifeBar" type="TextureProgressBar" parent="SouthWest/VBoxContainer"] +unique_name_in_owner = true +custom_minimum_size = Vector2(0, 48) +layout_mode = 2 +min_value = -4.0 +step = 0.01 +nine_patch_stretch = true +stretch_margin_left = 32 +stretch_margin_top = 16 +stretch_margin_right = 32 +stretch_margin_bottom = 16 +texture_under = ExtResource("9_4f1d7") +texture_progress = ExtResource("10_130v7")