11[gd_scene load_steps =4 format =2 ]
22
3- [ext_resource path ="res://spinpause .gd" type ="Script" id =1 ]
3+ [ext_resource path ="res://pause_button .gd" type ="Script" id =1 ]
44
55[sub_resource type ="CubeMesh" id =1 ]
66
@@ -21,7 +21,6 @@ tracks/0/keys = {
2121}
2222
2323[node name ="pause_scene" type ="Spatial" ]
24- script = ExtResource ( 1 )
2524
2625[node name ="cube" type ="MeshInstance" parent ="." ]
2726mesh = SubResource ( 1 )
@@ -40,43 +39,17 @@ anims/spin = SubResource( 2 )
4039transform = Transform ( 0.792992 , 0.251051 , -0.555101 , 0 , 0.911149 , 0.412078 , 0.609232 , -0.326775 , 0.722534 , -3.05357 , 1.80053 , 3.64099 )
4140spot_range = 6.0
4241
43- [node name ="pause" type ="Button" parent ="." ]
44- margin_left = 24.0
45- margin_top = 24.0
46- margin_right = 120.0
47- margin_bottom = 56.0
48- size_flags_horizontal = 2
49- size_flags_vertical = 2
50- text = "PAUSE!"
51-
52- [node name ="pause_popup" type ="PopupPanel" parent ="." ]
42+ [node name ="pause_button" type ="Button" parent ="." ]
5343pause_mode = 2
54- self_modulate = Color ( 1 , 1 , 1 , 0.7 )
55- margin_left = 185.0
56- margin_top = 72.0
57- margin_right = 638.0
58- margin_bottom = 433.0
59- size_flags_horizontal = 2
60- size_flags_vertical = 2
61-
62- [node name ="text" type ="Label" parent ="pause_popup" ]
63- margin_left = 4.0
64- margin_top = 4.0
65- margin_right = 449.0
66- margin_bottom = 357.0
67- size_flags_horizontal = 2
68- size_flags_vertical = 0
69- text = "The game has been paused! Nodes are not processing anymore, but this popup can still process!"
70- autowrap = true
71-
72- [node name ="unpause" type ="Button" parent ="pause_popup" ]
73- margin_left = 4.0
74- margin_top = 4.0
75- margin_right = 449.0
76- margin_bottom = 357.0
77- size_flags_horizontal = 2
78- size_flags_vertical = 2
79- text = "UN-PAUSE!"
80-
81- [connection signal ="pressed" from ="pause" to ="." method ="_on_pause_pressed" ]
82- [connection signal ="pressed" from ="pause_popup/unpause" to ="." method ="_on_unpause_pressed" ]
44+ anchor_left = 0.5
45+ anchor_top = 0.5
46+ anchor_right = 0.5
47+ anchor_bottom = 0.5
48+ margin_left = -125.0
49+ margin_top = 150.0
50+ margin_right = 125.0
51+ margin_bottom = 200.0
52+ rect_pivot_offset = Vector2 ( 123 , 25 )
53+ toggle_mode = true
54+ text = "Pause"
55+ script = ExtResource ( 1 )
0 commit comments