mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-13 18:55:55 +00:00
Boss HUD
This commit is contained in:
parent
b4fdb9c9e3
commit
4be64cf7ec
12 changed files with 220 additions and 33 deletions
|
|
@ -1,4 +1,4 @@
|
|||
[gd_scene load_steps=14 format=3 uid="uid://d1rlw6ddpmrn8"]
|
||||
[gd_scene load_steps=15 format=3 uid="uid://d1rlw6ddpmrn8"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/Actors/Boss.cs" id="1_na4uq"]
|
||||
[ext_resource type="Resource" uid="uid://ks6fypeil6gk" path="res://Resources/BossPhases/TestBoss1.tres" id="2_1rhf6"]
|
||||
|
|
@ -6,6 +6,7 @@
|
|||
[ext_resource type="Script" path="res://Scripts/Components/ProximityPlayerDetection.cs" id="3_gka5j"]
|
||||
[ext_resource type="Resource" uid="uid://ccj0cqbveey8c" path="res://Resources/BossPhases/Rumia_SP1.tres" id="3_j7lbl"]
|
||||
[ext_resource type="Texture2D" uid="uid://csuprfskdo1qp" path="res://Sprites/Portraits/Rumia.png" id="4_at5iq"]
|
||||
[ext_resource type="PackedScene" uid="uid://bwlstkdibs7oc" path="res://Scenes/HUD/BossHud.tscn" id="4_ehp8q"]
|
||||
[ext_resource type="PackedScene" uid="uid://crry0rgk7a8sm" path="res://Scenes/Weapons/BaseWeapon.tscn" id="4_xc6nm"]
|
||||
[ext_resource type="PackedScene" uid="uid://cuixq5ex0j40h" path="res://Scenes/enemyBullet.tscn" id="5_g1p0m"]
|
||||
[ext_resource type="Script" path="res://Scripts/Components/BulletSpawner.cs" id="7_2obh7"]
|
||||
|
|
@ -26,7 +27,9 @@ size = Vector2(8, 12)
|
|||
collision_layer = 16
|
||||
collision_mask = 9
|
||||
script = ExtResource("1_na4uq")
|
||||
BossName = "Rumia"
|
||||
Phases = Array[Resource]([ExtResource("2_1rhf6"), ExtResource("3_j7lbl")])
|
||||
BossHudPrefab = ExtResource("4_ehp8q")
|
||||
_bossPortraitTexture = ExtResource("4_at5iq")
|
||||
Health = 1000.0
|
||||
metadata/_edit_group_ = true
|
||||
|
|
|
|||
88
Scenes/HUD/BossHud.tscn
Normal file
88
Scenes/HUD/BossHud.tscn
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
[gd_scene load_steps=5 format=3 uid="uid://bwlstkdibs7oc"]
|
||||
|
||||
[ext_resource type="LabelSettings" uid="uid://buk3e7bbwmnv1" path="res://Resources/Styles/Hud_Text_Style.tres" id="1_a0we0"]
|
||||
[ext_resource type="Script" path="res://Scripts/UI/BossHud.cs" id="1_n2ke0"]
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_u7d4e"]
|
||||
bg_color = Color(0.406489, 0.00678394, 4.81308e-08, 1)
|
||||
corner_radius_top_left = 2
|
||||
corner_radius_top_right = 2
|
||||
corner_radius_bottom_right = 2
|
||||
corner_radius_bottom_left = 2
|
||||
anti_aliasing = false
|
||||
|
||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_c8usm"]
|
||||
bg_color = Color(0.713167, 0.181152, 0.0413054, 1)
|
||||
corner_radius_top_left = 2
|
||||
corner_radius_top_right = 2
|
||||
corner_radius_bottom_right = 2
|
||||
corner_radius_bottom_left = 2
|
||||
anti_aliasing = false
|
||||
|
||||
[node name="CanvasLayer" type="CanvasLayer" node_paths=PackedStringArray("BossNameLabel", "SpellCardNameLabel", "SpellCardsCountLabel", "SpellCardTimerLabel", "BossHealthBar")]
|
||||
script = ExtResource("1_n2ke0")
|
||||
BossNameLabel = NodePath("Boss Bar/HBoxContainer/VBoxContainer/BossName")
|
||||
SpellCardNameLabel = NodePath("Boss Bar/HBoxContainer/SpellCardName")
|
||||
SpellCardsCountLabel = NodePath("Boss Bar/HBoxContainer/VBoxContainer2/PhasesCount")
|
||||
SpellCardTimerLabel = NodePath("Boss Bar/HBoxContainer/VBoxContainer2/Time")
|
||||
BossHealthBar = NodePath("Boss Bar/HBoxContainer/VBoxContainer/BossHealthBar")
|
||||
|
||||
[node name="Boss Bar" type="Control" parent="."]
|
||||
layout_mode = 3
|
||||
anchors_preset = 0
|
||||
offset_left = 87.0
|
||||
offset_top = 2.0
|
||||
offset_right = 315.0
|
||||
offset_bottom = 42.0
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="Boss Bar"]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
[node name="VBoxContainer2" type="VBoxContainer" parent="Boss Bar/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Time" type="Label" parent="Boss Bar/HBoxContainer/VBoxContainer2"]
|
||||
layout_mode = 2
|
||||
text = "30"
|
||||
label_settings = ExtResource("1_a0we0")
|
||||
|
||||
[node name="PhasesCount" type="Label" parent="Boss Bar/HBoxContainer/VBoxContainer2"]
|
||||
layout_mode = 2
|
||||
text = "x3"
|
||||
label_settings = ExtResource("1_a0we0")
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="Boss Bar/HBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="BossName" type="Label" parent="Boss Bar/HBoxContainer/VBoxContainer"]
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 0
|
||||
text = "Boss Name"
|
||||
label_settings = ExtResource("1_a0we0")
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="BossHealthBar" type="ProgressBar" parent="Boss Bar/HBoxContainer/VBoxContainer"]
|
||||
custom_minimum_size = Vector2(0, 2)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
theme_override_constants/outline_size = 0
|
||||
theme_override_styles/background = SubResource("StyleBoxFlat_u7d4e")
|
||||
theme_override_styles/fill = SubResource("StyleBoxFlat_c8usm")
|
||||
value = 50.0
|
||||
show_percentage = false
|
||||
|
||||
[node name="SpellCardName" type="Label" parent="Boss Bar/HBoxContainer"]
|
||||
custom_minimum_size = Vector2(100, 30)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 0
|
||||
text = "Attack name goes here and it should wrap "
|
||||
label_settings = ExtResource("1_a0we0")
|
||||
horizontal_alignment = 2
|
||||
autowrap_mode = 2
|
||||
|
|
@ -1,9 +1,10 @@
|
|||
[gd_scene load_steps=12 format=3 uid="uid://dkwi1hu1bixoe"]
|
||||
[gd_scene load_steps=13 format=3 uid="uid://dkwi1hu1bixoe"]
|
||||
|
||||
[ext_resource type="Script" path="res://Scripts/Hud.cs" id="1_m0hb0"]
|
||||
[ext_resource type="FontFile" uid="uid://ccm3u37q1hvux" path="res://fonts/Xolonium-Regular.ttf" id="2_0xmx2"]
|
||||
[ext_resource type="LabelSettings" uid="uid://buk3e7bbwmnv1" path="res://Resources/Styles/Hud_Text_Style.tres" id="2_x7kl7"]
|
||||
[ext_resource type="Texture2D" uid="uid://dde36pgb8fbwc" path="res://Sprites/selector_big.png" id="3_hee3i"]
|
||||
[ext_resource type="PackedScene" uid="uid://bwlstkdibs7oc" path="res://Scenes/HUD/BossHud.tscn" id="5_vmict"]
|
||||
|
||||
[sub_resource type="AtlasTexture" id="AtlasTexture_h626b"]
|
||||
atlas = ExtResource("3_hee3i")
|
||||
|
|
@ -133,3 +134,6 @@ label_settings = ExtResource("2_x7kl7")
|
|||
[node name="ItemsContainer" type="VBoxContainer" parent="VBoxContainer"]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 0
|
||||
|
||||
[node name="BossHud" parent="." instance=ExtResource("5_vmict")]
|
||||
visible = false
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue