From 832334e381d6e6466327073a708d2bbdd6b187fe Mon Sep 17 00:00:00 2001 From: Page Asgardius Date: Mon, 2 Oct 2023 14:39:56 -0700 Subject: [PATCH] crash animation --- backgounds/galaxy.gd | 2 ++ backgounds/wormhole.gd | 2 ++ levels/credits.tscn | 28 ++++++++++++++-------------- levels/galaxy.tscn | 4 +++- levels/ss.gd | 13 +++++++++++++ levels/wormhole.tscn | 4 +++- 6 files changed, 37 insertions(+), 16 deletions(-) create mode 100644 levels/ss.gd diff --git a/backgounds/galaxy.gd b/backgounds/galaxy.gd index 55a950d..d41341d 100644 --- a/backgounds/galaxy.gd +++ b/backgounds/galaxy.gd @@ -41,6 +41,8 @@ func _crash(): # This is like autoloading the scene, only # it happens after already loading the main scene. Global.time = Time.get_ticks_msec() - wait + await get_tree().create_timer(1.0).timeout + queue_free() get_tree().root.remove_child(galaxy) get_tree().change_scene_to_file("res://backgounds/supernova.tscn") #get_tree().root.add_child(title) diff --git a/backgounds/wormhole.gd b/backgounds/wormhole.gd index 5b2cdd8..fab43c6 100644 --- a/backgounds/wormhole.gd +++ b/backgounds/wormhole.gd @@ -41,6 +41,8 @@ func _crash(): # This is like autoloading the scene, only # it happens after already loading the main scene. Global.time = Time.get_ticks_msec() - wait + await get_tree().create_timer(1.0).timeout + queue_free() get_tree().root.remove_child(wormhole) get_tree().change_scene_to_file("res://backgounds/supernova.tscn") #get_tree().root.add_child(title) diff --git a/levels/credits.tscn b/levels/credits.tscn index 2116686..af26837 100644 --- a/levels/credits.tscn +++ b/levels/credits.tscn @@ -112,32 +112,32 @@ Eternity 4mat Abstract -??? -??? +realize the truth +AceMan Galaxy2 -??? -??? +Broken +Saxxon Pike Lagoon -??? -??? +Maran Project +Attraction Orion -??? -??? +orion spaceforce23 +dualtrax Space -??? -??? +rose +4mat Stars -??? -??? +Oskars Skarmslackare +MrGamer Universe -??? -??? +zenon +ko0x Credit roll 1 Yes, I see diff --git a/levels/galaxy.tscn b/levels/galaxy.tscn index 326d36c..c443358 100644 --- a/levels/galaxy.tscn +++ b/levels/galaxy.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=21 format=3 uid="uid://mtl88mcwaqk0"] +[gd_scene load_steps=22 format=3 uid="uid://mtl88mcwaqk0"] [ext_resource type="Script" path="res://levels/galaxy.gd" id="1_3c4wu"] [ext_resource type="Texture2D" uid="uid://8lioamk650y7" path="res://sprites/css.png" id="2_3g4h6"] @@ -14,6 +14,7 @@ [ext_resource type="Script" path="res://levels/ast1.gd" id="12_g6l6s"] [ext_resource type="Script" path="res://levels/ast2.gd" id="13_s46s0"] [ext_resource type="Script" path="res://levels/ast3.gd" id="14_cu7w4"] +[ext_resource type="Script" path="res://levels/ss.gd" id="15_c4337"] [ext_resource type="Script" path="res://levels/wall1.gd" id="15_jbm4l"] [ext_resource type="Script" path="res://levels/wall2.gd" id="16_dnhp8"] [ext_resource type="Script" path="res://levels/wall3.gd" id="17_jrw7x"] @@ -146,6 +147,7 @@ script = ExtResource("9_diat7") position = Vector2(640, 360) scale = Vector2(0.3, 0.3) texture = ExtResource("9_favs7") +script = ExtResource("15_c4337") [node name="wall1" type="Sprite2D" parent="."] position = Vector2(357.5, 483.5) diff --git a/levels/ss.gd b/levels/ss.gd new file mode 100644 index 0000000..8fd9ee8 --- /dev/null +++ b/levels/ss.gd @@ -0,0 +1,13 @@ +extends Sprite2D + +var angular_speed = PI +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + if Global.live == 2: + rotation += angular_speed * delta * 5 + #pass diff --git a/levels/wormhole.tscn b/levels/wormhole.tscn index f87ad28..c9bb823 100644 --- a/levels/wormhole.tscn +++ b/levels/wormhole.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=21 format=3 uid="uid://b82huqhu88xt6"] +[gd_scene load_steps=22 format=3 uid="uid://b82huqhu88xt6"] [ext_resource type="Script" path="res://levels/wormhole.gd" id="1_n4a5i"] [ext_resource type="Texture2D" uid="uid://8lioamk650y7" path="res://sprites/css.png" id="2_y6cio"] @@ -14,6 +14,7 @@ [ext_resource type="Script" path="res://levels/ast1.gd" id="12_s1o5o"] [ext_resource type="Script" path="res://levels/ast2.gd" id="13_xw0he"] [ext_resource type="Script" path="res://levels/ast3.gd" id="14_xcrsk"] +[ext_resource type="Script" path="res://levels/ss.gd" id="15_qucqy"] [ext_resource type="Script" path="res://levels/wall1.gd" id="15_yx2oo"] [ext_resource type="Script" path="res://levels/wall2.gd" id="16_el0w3"] [ext_resource type="Script" path="res://levels/wall3.gd" id="17_pl58r"] @@ -146,6 +147,7 @@ script = ExtResource("9_cr36o") position = Vector2(640, 360) scale = Vector2(0.3, 0.3) texture = ExtResource("10_shrek") +script = ExtResource("15_qucqy") [node name="wall1" type="Sprite2D" parent="."] position = Vector2(338.5, 688.5)