diff --git a/objects/hud/hud.gd b/objects/hud/hud.gd index 4382b18..3e984cb 100644 --- a/objects/hud/hud.gd +++ b/objects/hud/hud.gd @@ -13,7 +13,7 @@ onready var lives_counter = $LivesCounter onready var high_counter = $HighCounter onready var time_counter = $TimeCounter -export var song_name = "@Rumble" +export var song_name = "♫Music" export (Color) var bonus_color func _ready(): @@ -24,7 +24,13 @@ func _ready(): else: $DeathsHead.visible = true #Change text to song name - $Music.text = song_name + var music = $Music + music.text = song_name + yield(get_tree(), "idle_frame") + var tween = create_tween() + tween.tween_property(music, "rect_position:x", 254.0 - music.rect_size.x, 1.0) + tween.tween_interval(3.0) + tween.tween_property(music, "rect_position:x", 256.0, 1.0) func _physics_process(delta): #Gold Counter diff --git a/objects/hud/hud.tscn b/objects/hud/hud.tscn index bd2f17a..e55518d 100644 --- a/objects/hud/hud.tscn +++ b/objects/hud/hud.tscn @@ -8,32 +8,17 @@ [ext_resource path="res://objects/hud/hud.gd" type="Script" id=6] [ext_resource path="res://graphics/hud/key_counter.png" type="Texture" id=7] [ext_resource path="res://ui/2ndpuberty_outline.tres" type="Material" id=8] +[ext_resource path="res://ui/2ndpuberty_no_dropshadow.tres" type="Theme" id=9] [ext_resource path="res://ui/theme.tres" type="Theme" id=10] [sub_resource type="ShaderMaterial" id=1] [sub_resource type="ShaderMaterial" id=2] -[sub_resource type="Animation" id=3] -resource_name = "show song name" -length = 5.0 -tracks/0/type = "value" -tracks/0/path = NodePath("Music:rect_position") -tracks/0/interp = 1 -tracks/0/loop_wrap = true -tracks/0/imported = false -tracks/0/enabled = true -tracks/0/keys = { -"times": PoolRealArray( 0, 0.8, 4.2, 5 ), -"transitions": PoolRealArray( 1, 1, 1, 1 ), -"update": 0, -"values": [ Vector2( 150, 178 ), Vector2( 57, 178 ), Vector2( 57, 178 ), Vector2( 150, 178 ) ] -} - [node name="HUD" type="CanvasLayer"] layer = 100 script = ExtResource( 6 ) -song_name = "♫Rumble" +song_name = "♫Music" bonus_color = Color( 0.478431, 1, 0.47451, 1 ) [node name="Back" type="Sprite" parent="."] @@ -165,14 +150,12 @@ text = "0:00:00" [node name="Music" type="Label" parent="."] material = ExtResource( 8 ) -margin_left = 150.0 -margin_top = 180.0 -margin_right = 348.0 -margin_bottom = 190.0 -theme = ExtResource( 10 ) -text = "♫rumble" +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +margin_top = -10.0 +margin_right = 42.0 +theme = ExtResource( 9 ) +text = "♫Music" align = 2 - -[node name="AnimationPlayer" type="AnimationPlayer" parent="."] -autoplay = "show song name" -"anims/show song name" = SubResource( 3 )