Basic ending
This commit is contained in:
@@ -25,4 +25,9 @@ public partial class BossOrbs : RigidBody3D
|
||||
QueueFree();
|
||||
}
|
||||
}
|
||||
|
||||
public void DestroySelf()
|
||||
{
|
||||
QueueFree();
|
||||
}
|
||||
}
|
||||
|
||||
15
Levels/Scenes/GameEnding.cs
Normal file
15
Levels/Scenes/GameEnding.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using Godot;
|
||||
|
||||
public partial class GameEnding : Node3D
|
||||
{
|
||||
public void OnGameEnding()
|
||||
{
|
||||
var bgmPlayer = GetTree().Root.GetNode<BGMPlayer>("BgmPlayer");
|
||||
bgmPlayer.ProcessMode = ProcessModeEnum.Always;
|
||||
bgmPlayer.SetBGMFromFilepath("Audio/BGM/GameEnding.ogg");
|
||||
bgmPlayer.PlayBGM();
|
||||
|
||||
var animationPlayer = GetNode<AnimationPlayer>("AnimationPlayer");
|
||||
animationPlayer.Play("GameEnding");
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=21 format=3 uid="uid://0hdnmilwrsq6"]
|
||||
[gd_scene load_steps=27 format=3 uid="uid://0hdnmilwrsq6"]
|
||||
|
||||
[ext_resource type="Script" path="res://Levels/Scripts/FinalLevel.cs" id="1_sy7dk"]
|
||||
[ext_resource type="Script" path="res://Enemies/HealthbarProgress.cs" id="2_53ar2"]
|
||||
@@ -11,6 +11,9 @@
|
||||
[ext_resource type="Script" path="res://Levels/Scenes/BossOrbs.cs" id="8_7itwt"]
|
||||
[ext_resource type="Texture2D" uid="uid://uatt2w2jsoan" path="res://Textures/Projectiles/LB HEDRON.png" id="9_rv0g1"]
|
||||
[ext_resource type="Texture2D" uid="uid://cqbortt0hksns" path="res://Textures/Projectiles/LB PYRAMID.png" id="10_dusre"]
|
||||
[ext_resource type="Script" path="res://Levels/Scenes/GameEnding.cs" id="12_kefc8"]
|
||||
[ext_resource type="Animation" uid="uid://bcprf755m753" path="res://Animations/GameEnding.res" id="13_plu01"]
|
||||
[ext_resource type="FontFile" uid="uid://bu2j6b01rdsf6" path="res://Animations/Alegreya-Regular.ttf" id="14_fcfkf"]
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_43mih"]
|
||||
size = Vector3(5, 20, 27.822)
|
||||
@@ -57,6 +60,18 @@ tracks/0/keys = {
|
||||
"update": 0,
|
||||
"values": [0.0]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("../GameEnding/ColorRect:modulate")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 0)]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_nvs18"]
|
||||
_data = {
|
||||
@@ -64,9 +79,46 @@ _data = {
|
||||
"RESET": SubResource("Animation_wy7s8")
|
||||
}
|
||||
|
||||
[sub_resource type="CylinderShape3D" id="CylinderShape3D_3l1g5"]
|
||||
[sub_resource type="Animation" id="Animation_iincs"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("ColorRect:modulate")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 0)]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Label:modulate")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [Color(1, 1, 1, 0)]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_l1ojm"]
|
||||
_data = {
|
||||
"GameEnding": ExtResource("13_plu01"),
|
||||
"RESET": SubResource("Animation_iincs")
|
||||
}
|
||||
|
||||
[sub_resource type="LabelSettings" id="LabelSettings_gphy5"]
|
||||
font = ExtResource("14_fcfkf")
|
||||
font_size = 125
|
||||
|
||||
[sub_resource type="CylinderShape3D" id="CylinderShape3D_los3u"]
|
||||
height = 3.85738
|
||||
radius = 0.511049
|
||||
radius = 0.412024
|
||||
|
||||
[node name="Level10" type="Node3D" groups=["Level"]]
|
||||
process_mode = 3
|
||||
@@ -142,15 +194,51 @@ libraries = {
|
||||
|
||||
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="Boss GUI"]
|
||||
stream = ExtResource("7_gnuti")
|
||||
autoplay = true
|
||||
|
||||
[node name="GameEnding" type="Node3D" parent="."]
|
||||
script = ExtResource("12_kefc8")
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="GameEnding"]
|
||||
libraries = {
|
||||
"": SubResource("AnimationLibrary_l1ojm")
|
||||
}
|
||||
|
||||
[node name="ColorRect" type="ColorRect" parent="GameEnding"]
|
||||
modulate = Color(1, 1, 1, 0)
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_right = -1.0
|
||||
offset_bottom = 2.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
color = Color(0, 0, 0, 1)
|
||||
|
||||
[node name="Label" type="Label" parent="GameEnding"]
|
||||
modulate = Color(1, 1, 1, 0)
|
||||
anchors_preset = 8
|
||||
anchor_left = 0.5
|
||||
anchor_top = 0.5
|
||||
anchor_right = 0.5
|
||||
anchor_bottom = 0.5
|
||||
offset_left = -959.0
|
||||
offset_top = -538.5
|
||||
offset_right = 959.0
|
||||
offset_bottom = 538.5
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
text = "The End"
|
||||
label_settings = SubResource("LabelSettings_gphy5")
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="Pivot" type="Node3D" parent="."]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.260435, 0, -1.52945)
|
||||
|
||||
[node name="Pyramid" type="RigidBody3D" parent="Pivot" node_paths=PackedStringArray("_hp")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.064761, 0.75105, -3.23007)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.064761, 0.75105, -2.67492)
|
||||
collision_layer = 0
|
||||
collision_mask = 69
|
||||
collision_mask = 68
|
||||
gravity_scale = 0.0
|
||||
continuous_cd = true
|
||||
max_contacts_reported = 10
|
||||
@@ -162,21 +250,21 @@ _rotationSpeed = 0.1
|
||||
_hp = NodePath("HP Component")
|
||||
|
||||
[node name="PyramidSprite" type="Sprite3D" parent="Pivot/Pyramid"]
|
||||
transform = Transform3D(0.12, 0, 0, 0, 0.12, 0, 0, 0, 0.12, 0, 0, 0)
|
||||
transform = Transform3D(0.08, 0, 0, 0, 0.08, 0, 0, 0, 0.08, 0, 0, 0)
|
||||
axis = 1
|
||||
texture = ExtResource("10_dusre")
|
||||
|
||||
[node name="CollisionShape3D2" type="CollisionShape3D" parent="Pivot/Pyramid"]
|
||||
transform = Transform3D(1, 0, -2.98023e-08, 0, 1, 0, 2.98023e-08, 0, 1, 0.0513983, 0, 0)
|
||||
shape = SubResource("CylinderShape3D_3l1g5")
|
||||
shape = SubResource("CylinderShape3D_los3u")
|
||||
|
||||
[node name="HP Component" parent="Pivot/Pyramid" instance=ExtResource("7_nvq88")]
|
||||
MaximumHP = 1
|
||||
|
||||
[node name="Orb" type="RigidBody3D" parent="Pivot" node_paths=PackedStringArray("_hp")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 3.69215, 0.241416, 1.28096)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 2.75045, 0.241416, 1.28096)
|
||||
collision_layer = 0
|
||||
collision_mask = 69
|
||||
collision_mask = 68
|
||||
gravity_scale = 0.0
|
||||
continuous_cd = true
|
||||
max_contacts_reported = 10
|
||||
@@ -188,11 +276,11 @@ _rotationSpeed = 0.1
|
||||
_hp = NodePath("HP Component")
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="Pivot/Orb"]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.459897, 0, 0.538185)
|
||||
shape = SubResource("CylinderShape3D_3l1g5")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.473554, 0, 0.565499)
|
||||
shape = SubResource("CylinderShape3D_los3u")
|
||||
|
||||
[node name="OrbSprite" type="Sprite3D" parent="Pivot/Orb"]
|
||||
transform = Transform3D(0.12, 0, 0, 0, 0.12, 0, 0, 0, 0.12, -0.47522, 0, 0.577053)
|
||||
transform = Transform3D(0.08, 0, 0, 0, 0.08, 0, 0, 0, 0.08, -0.47522, 0, 0.577053)
|
||||
axis = 1
|
||||
texture = ExtResource("8_2yfol")
|
||||
|
||||
@@ -200,9 +288,9 @@ texture = ExtResource("8_2yfol")
|
||||
MaximumHP = 1
|
||||
|
||||
[node name="Hedron" type="RigidBody3D" parent="Pivot" node_paths=PackedStringArray("_hp")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -4.29263, 0.704458, 1.45723)
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -2.88775, 0.704458, 1.45723)
|
||||
collision_layer = 0
|
||||
collision_mask = 69
|
||||
collision_mask = 68
|
||||
gravity_scale = 0.0
|
||||
continuous_cd = true
|
||||
max_contacts_reported = 10
|
||||
@@ -214,17 +302,22 @@ _rotationSpeed = 0.1
|
||||
_hp = NodePath("HP Component")
|
||||
|
||||
[node name="HedronSprite" type="Sprite3D" parent="Pivot/Hedron"]
|
||||
transform = Transform3D(0.15, 0, 0, 0, 0.15, 0, 0, 0, 0.15, 0, 0, 0)
|
||||
transform = Transform3D(0.1, 0, 0, 0, 0.1, 0, 0, 0, 0.1, 0, 0, 0)
|
||||
axis = 1
|
||||
texture = ExtResource("9_rv0g1")
|
||||
|
||||
[node name="CollisionShape3D2" type="CollisionShape3D" parent="Pivot/Hedron"]
|
||||
shape = SubResource("CylinderShape3D_3l1g5")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0136576, 0, 0)
|
||||
shape = SubResource("CylinderShape3D_los3u")
|
||||
|
||||
[node name="HP Component" parent="Pivot/Hedron" instance=ExtResource("7_nvq88")]
|
||||
MaximumHP = 1
|
||||
|
||||
[connection signal="DestroyRemainingOrbs" from="God Circuit" to="Pivot/Pyramid" method="DestroySelf"]
|
||||
[connection signal="DestroyRemainingOrbs" from="God Circuit" to="Pivot/Orb" method="DestroySelf"]
|
||||
[connection signal="DestroyRemainingOrbs" from="God Circuit" to="Pivot/Hedron" method="DestroySelf"]
|
||||
[connection signal="OnEnemyBossHit" from="God Circuit" to="Boss GUI/TextureProgressBar" method="UpdateBar"]
|
||||
[connection signal="OnGameEnding" from="God Circuit" to="GameEnding" method="OnGameEnding"]
|
||||
[connection signal="OnBossOrbExploded" from="Pivot/Pyramid" to="God Circuit" method="OnBossOrbDestroyed"]
|
||||
[connection signal="body_entered" from="Pivot/Pyramid" to="Pivot/Pyramid" method="OnOrbHit"]
|
||||
[connection signal="OnBossOrbExploded" from="Pivot/Orb" to="God Circuit" method="OnBossOrbDestroyed"]
|
||||
|
||||
Reference in New Issue
Block a user