Blobby/src/Contraptions/Triggers/ElevatorButton.tscn

155 lines
4.4 KiB
Plaintext

[gd_scene load_steps=11 format=2]
[ext_resource path="res://src/Contraptions/Triggers/ElevatorButton.gd" type="Script" id=1]
[ext_resource path="res://assets/contraption/button.png" type="Texture" id=2]
[ext_resource path="res://assets/contraption/buttonStateIndicator.png" type="Texture" id=3]
[ext_resource path="res://assets/ui/sci-fi-godot-theme/sci-fi-pixel.tres" type="DynamicFont" id=4]
[sub_resource type="Gradient" id=23]
interpolation_mode = 2
colors = PoolColorArray( 1, 1, 1, 0.752941, 0, 0, 0, 0 )
[sub_resource type="GradientTexture2D" id=22]
gradient = SubResource( 23 )
width = 50
height = 30
use_hdr = true
fill = 1
fill_from = Vector2( 0.5, 0.5 )
fill_to = Vector2( 0.155994, 0.791965 )
[sub_resource type="Animation" id=2]
resource_name = "pushing"
length = 0.5
tracks/0/type = "value"
tracks/0/path = NodePath(".:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = false
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.2, 0.4 ),
"transitions": PoolRealArray( 1, 1, 1 ),
"update": 1,
"values": [ 0.0, 1.0, 2.0 ]
}
[sub_resource type="Animation" id=20]
length = 0.1
tracks/0/type = "value"
tracks/0/path = NodePath(".:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = false
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0 ),
"transitions": PoolRealArray( 1 ),
"update": 1,
"values": [ 0.0 ]
}
[sub_resource type="Animation" id=13]
resource_name = "onning"
length = 0.6
tracks/0/type = "value"
tracks/0/path = NodePath(".:frame")
tracks/0/interp = 1
tracks/0/loop_wrap = false
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/keys = {
"times": PoolRealArray( 0, 0.2, 0.3, 0.5 ),
"transitions": PoolRealArray( 1, 1, 1, 1 ),
"update": 1,
"values": [ 7.0, 8.0, 6.0, 4.0 ]
}
[sub_resource type="CircleShape2D" id=18]
radius = 18.0
[node name="ElevatorButton" type="Node2D"]
scale = Vector2( 2, 2 )
z_index = 2
script = ExtResource( 1 )
elevator_time = 3
[node name="Highlight" type="TextureRect" parent="."]
visible = false
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
margin_left = -24.5
margin_top = -18.5
margin_right = 25.5
margin_bottom = 31.5
texture = SubResource( 22 )
[node name="Label" type="Label" parent="."]
visible = false
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
margin_left = -17.0
margin_top = -23.0
margin_right = 60.0
margin_bottom = -9.0
rect_scale = Vector2( 0.590909, 0.627907 )
custom_fonts/font = ExtResource( 4 )
text = "Time: 999sec"
align = 1
valign = 1
[node name="Button" type="Sprite" parent="."]
position = Vector2( 0, -6 )
texture = ExtResource( 2 )
hframes = 2
vframes = 2
__meta__ = {
"_editor_description_": "YXNlcHJpdGVfd2l6YXJkX2NvbmZpZwpwbGF5ZXJ8PVNwcml0ZS9BbmltYXRpb25QbGF5ZXIKc291cmNlfD1yZXM6Ly9hc3NldHMvbmV1dHJhbCBvYmplY3QvYnV0dG9uLmFzZXByaXRlCmxheWVyfD0Kb3BfZXhwfD1GYWxzZQpvX2ZvbGRlcnw9Cm9fbmFtZXw9Cm9ubHlfdmlzaWJsZXw9RmFsc2UKb19leF9wfD0K"
}
[node name="ButtonPlayer" type="AnimationPlayer" parent="Button"]
unique_name_in_owner = true
anims/pushing = SubResource( 2 )
[node name="Indicator" type="Sprite" parent="."]
position = Vector2( 0, -1 )
z_index = 1
texture = ExtResource( 3 )
hframes = 3
vframes = 3
__meta__ = {
"_editor_description_": "YXNlcHJpdGVfd2l6YXJkX2NvbmZpZwpwbGF5ZXJ8PUluZGljYXRvcjIvQW5pbWF0aW9uUGxheWVyCnNvdXJjZXw9cmVzOi8vYXNzZXRzL25ldXRyYWwgb2JqZWN0L2J1dHRvblN0YXRlSW5kaWNhdG9yLmFzZXByaXRlCmxheWVyfD0Kb3BfZXhwfD1GYWxzZQpvX2ZvbGRlcnw9Cm9fbmFtZXw9Cm9ubHlfdmlzaWJsZXw9RmFsc2UKb19leF9wfD0K"
}
[node name="IndicatorPlayer" type="AnimationPlayer" parent="Indicator"]
unique_name_in_owner = true
anims/offing = SubResource( 20 )
anims/onning = SubResource( 13 )
[node name="ActivatorArea" type="Area2D" parent="."]
unique_name_in_owner = true
position = Vector2( 0, -6 )
scale = Vector2( 0.5, 0.5 )
collision_layer = 24
monitorable = false
[node name="ActivatorAreaShape" type="CollisionShape2D" parent="ActivatorArea"]
unique_name_in_owner = true
position = Vector2( 0, 3 )
shape = SubResource( 18 )
[node name="Timer" type="Timer" parent="."]
wait_time = 0.333
one_shot = true
[node name="GetBackTimer" type="Timer" parent="."]
[connection signal="area_entered" from="ActivatorArea" to="." method="_on_ActivatorArea_area_entered"]
[connection signal="area_exited" from="ActivatorArea" to="." method="_on_ActivatorArea_area_exited"]
[connection signal="timeout" from="Timer" to="." method="_on_Timer_timeout"]
[connection signal="timeout" from="GetBackTimer" to="." method="_on_GetBackTimer_timeout"]