diff --git a/Scene/EndGameWindow.tscn b/Scene/EndGameWindow.tscn index 8959ec2..17089ca 100644 --- a/Scene/EndGameWindow.tscn +++ b/Scene/EndGameWindow.tscn @@ -1,8 +1,11 @@ -[gd_scene load_steps=4 format=2] +[gd_scene load_steps=7 format=2] [ext_resource path="res://Scripts/EndGameWindow.gd" type="Script" id=1] [ext_resource path="res://Font/COMIC.tres" type="DynamicFont" id=2] [ext_resource path="res://Sounds/PaintJamEndGameTheme.wav" type="AudioStream" id=3] +[ext_resource path="res://Assets/QUIT WINNING.png" type="Texture" id=4] +[ext_resource path="res://Assets/WINNER.png" type="Texture" id=5] +[ext_resource path="res://Assets/RESTART WINNING.png" type="Texture" id=6] [node name="CanvasLayer" type="CanvasLayer"] layer = 100 @@ -29,43 +32,17 @@ __meta__ = { "_edit_use_anchors_": false } -[node name="ColorRect" type="ColorRect" parent="Window"] -anchor_left = 0.5 -anchor_top = 0.5 -anchor_right = 0.5 -anchor_bottom = 0.5 -margin_left = -267.0 -margin_top = -254.0 -margin_right = 256.0 -margin_bottom = 82.0 -color = Color( 0, 0, 0, 1 ) -__meta__ = { -"_edit_use_anchors_": false -} +[node name="WinnerPopUp" type="Sprite" parent="Window"] +position = Vector2( 951.212, 510.746 ) +texture = ExtResource( 5 ) -[node name="Title" type="Label" parent="Window/ColorRect"] +[node name="WinnerName" type="Label" parent="Window/WinnerPopUp"] anchor_left = 0.5 anchor_right = 0.5 -margin_left = -60.5 -margin_top = 28.0 -margin_right = 83.5 -margin_bottom = 80.0 -custom_fonts/font = ExtResource( 2 ) -text = "Winner:" -align = 1 -valign = 1 -autowrap = true -__meta__ = { -"_edit_use_anchors_": false -} - -[node name="WinnerName" type="Label" parent="Window/ColorRect"] -anchor_left = 0.5 -anchor_right = 0.5 -margin_left = -53.5 -margin_top = 130.0 -margin_right = 70.5 -margin_bottom = 182.0 +margin_left = -876.595 +margin_top = 59.2959 +margin_right = -673.595 +margin_bottom = 111.296 custom_fonts/font = ExtResource( 2 ) text = "AZER" align = 1 @@ -75,33 +52,28 @@ __meta__ = { "_edit_use_anchors_": false } -[node name="VBoxContainer" type="HBoxContainer" parent="Window/ColorRect"] -anchor_top = 1.0 -anchor_right = 1.0 -anchor_bottom = 1.0 -margin_top = -81.0 -margin_bottom = -6.0 -custom_constants/separation = 25 +[node name="RestartButton" type="TextureButton" parent="Window/WinnerPopUp"] +margin_left = -403.089 +margin_top = 187.089 +margin_right = 11.9109 +margin_bottom = 328.089 +texture_normal = ExtResource( 6 ) +__meta__ = { +"_edit_use_anchors_": false +} -[node name="RestartButton" type="Button" parent="Window/ColorRect/VBoxContainer"] -margin_right = 249.0 -margin_bottom = 75.0 -size_flags_horizontal = 3 -size_flags_vertical = 3 -custom_fonts/font = ExtResource( 2 ) -text = "Restart" - -[node name="QuitButton" type="Button" parent="Window/ColorRect/VBoxContainer"] -margin_left = 274.0 -margin_right = 523.0 -margin_bottom = 75.0 -size_flags_horizontal = 3 -size_flags_vertical = 3 -custom_fonts/font = ExtResource( 2 ) -text = "Quit" +[node name="QuitButton" type="TextureButton" parent="Window/WinnerPopUp"] +margin_left = 39.6559 +margin_top = 184.284 +margin_right = 432.656 +margin_bottom = 315.284 +texture_normal = ExtResource( 4 ) +__meta__ = { +"_edit_use_anchors_": false +} [node name="EndGameTheme" type="AudioStreamPlayer" parent="."] pause_mode = 2 stream = ExtResource( 3 ) -[connection signal="pressed" from="Window/ColorRect/VBoxContainer/RestartButton" to="Window" method="_on_RestartButton_pressed"] -[connection signal="pressed" from="Window/ColorRect/VBoxContainer/QuitButton" to="Window" method="_on_QuitButton_pressed"] +[connection signal="pressed" from="Window/WinnerPopUp/RestartButton" to="Window" method="_on_RestartButton_pressed"] +[connection signal="pressed" from="Window/WinnerPopUp/QuitButton" to="Window" method="_on_QuitButton_pressed"] diff --git a/Scripts/EndGameWindow.gd b/Scripts/EndGameWindow.gd index 7567e2f..65ea93b 100644 --- a/Scripts/EndGameWindow.gd +++ b/Scripts/EndGameWindow.gd @@ -5,7 +5,7 @@ func showEndGameWindow(playerName): audioPlayer.play() get_tree().paused = true self.visible = true - get_node("/root/World/CanvasLayer/Window/ColorRect/WinnerName").text = playerName + get_node("/root/World/CanvasLayer/Window/WinnerPopUp/WinnerName").text = playerName func _on_RestartButton_pressed(): diff --git a/Scripts/TitleScreen.gd b/Scripts/TitleScreen.gd index b243aef..fa5c7cf 100644 --- a/Scripts/TitleScreen.gd +++ b/Scripts/TitleScreen.gd @@ -17,7 +17,6 @@ func _process(_delta): func _on_StartButton_pressed(): get_tree().change_scene("res://Scene/GameMap.tscn") - func _on_QuitButton_pressed(): get_tree().quit()