grunk/src/props/wall_switch/wall_switch.tscn

276 lines
15 KiB
Plaintext
Raw Normal View History

[gd_scene load_steps=26 format=3 uid="uid://b6eg8t04rkh0c"]
2025-03-05 14:46:13 -07:00
2025-03-06 16:06:17 -07:00
[ext_resource type="Script" uid="uid://bkmn5m47mt1gh" path="res://src/props/wall_switch/wall_switch.gd" id="2_kfvqd"]
2025-03-05 14:46:13 -07:00
[ext_resource type="Texture2D" uid="uid://1wjcyqynwlb6" path="res://assets/props/wall_switch/wall_switch_C.png" id="2_vufqs"]
[ext_resource type="PackedScene" uid="uid://d0yq007888oq5" path="res://assets/props/wall_switch/wall_switch.gltf" id="2_whafo"]
[ext_resource type="Texture2D" uid="uid://bur4dtt4irwgd" path="res://assets/props/wall_switch/wall_switch_M.png" id="3_3fhmv"]
[ext_resource type="Texture2D" uid="uid://ddve6jcfcuthx" path="res://assets/props/wall_switch/wall_switch_N.png" id="4_pg3hp"]
[ext_resource type="Texture2D" uid="uid://rq5e0a3sco88" path="res://assets/props/wall_switch/wall_switch_R.png" id="5_555wb"]
[ext_resource type="PackedScene" uid="uid://c2omlx4ptrc01" path="res://src/world/gunk_body/gunk_body.tscn" id="7_3ib1l"]
[ext_resource type="Material" uid="uid://c1vy4bkwb1g5m" path="res://assets/materials/gunk_lowrez.material" id="8_2qpft"]
2025-03-06 16:06:17 -07:00
[ext_resource type="Script" uid="uid://deg5xd87cy8rg" path="res://src/props/interactive.gd" id="10_qw6jt"]
2025-03-29 19:32:24 -06:00
[ext_resource type="AudioStream" uid="uid://bgayfws34lg7q" path="res://assets/sfx/click_electronic_04.wav" id="11_7shuc"]
2025-04-02 21:03:36 -06:00
[ext_resource type="AudioStream" uid="uid://cnje66wrijwxw" path="res://assets/sfx/wall_switch.wav" id="12_2qpft"]
[ext_resource type="Script" uid="uid://c5o1d2shq2qig" path="res://src/world/game_sound/game_sound_emitter.gd" id="13_eim2y"]
2025-03-05 14:46:13 -07:00
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_jtkkw"]
2025-03-05 14:46:13 -07:00
albedo_texture = ExtResource("2_vufqs")
metallic = 1.0
metallic_texture = ExtResource("3_3fhmv")
roughness_texture = ExtResource("5_555wb")
normal_enabled = true
normal_texture = ExtResource("4_pg3hp")
texture_filter = 2
[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_1xqlp"]
data = PackedVector3Array(-0.24, -0.32, 0.1, -0.3, 0.4, -0.1, -0.24, 0.32, 0.1, -0.24, -0.32, 0.1, -0.3, -0.4, -0.1, -0.3, 0.4, -0.1, -0.3, -0.4, -0.1, 0.3, 0.4, -0.1, -0.3, 0.4, -0.1, -0.3, -0.4, -0.1, 0.3, -0.4, -0.1, 0.3, 0.4, -0.1, 0.3, -0.4, -0.1, 0.24, 0.32, 0.1, 0.3, 0.4, -0.1, 0.3, -0.4, -0.1, 0.24, -0.32, 0.1, 0.24, 0.32, 0.1, -0.24, -0.32, 0.1, 0.3, -0.4, -0.1, -0.3, -0.4, -0.1, 0.3, -0.4, -0.1, 0.1, -0.32, 0.1, 0.24, -0.32, 0.1, 0.3, -0.4, -0.1, -0.24, -0.32, 0.1, 0.1, -0.32, 0.1, 0.24, 0.32, 0.1, -0.3, 0.4, -0.1, 0.3, 0.4, -0.1, -0.3, 0.4, -0.1, 0.1, 0.32, 0.1, -0.24, 0.32, 0.1, -0.3, 0.4, -0.1, 0.24, 0.32, 0.1, 0.1, 0.32, 0.1, 0.24, -0.32, 0.1, 0.1, 0.32, 0.1, 0.24, 0.32, 0.1, 0.24, -0.32, 0.1, 0.1, -0.32, 0.1, 0.1, 0.32, 0.1, -0.19, 0.27, 0.1, -0.19, -0.27, 0.05, -0.19, -0.27, 0.1, -0.19, 0.27, 0.1, -0.19, 0.27, 0.05, -0.19, -0.27, 0.05, -0.19, 0.27, 0.1, 0.1, 0.32, 0.1, 0.05, 0.27, 0.1, -0.19, 0.27, 0.1, -0.24, 0.32, 0.1, 0.1, 0.32, 0.1, -0.19, -0.27, 0.1, -0.24, 0.32, 0.1, -0.19, 0.27, 0.1, -0.19, -0.27, 0.1, -0.24, -0.32, 0.1, -0.24, 0.32, 0.1, 0.05, -0.27, 0.1, -0.24, -0.32, 0.1, -0.19, -0.27, 0.1, 0.05, -0.27, 0.1, 0.1, -0.32, 0.1, -0.24, -0.32, 0.1, 0.05, 0.27, 0.1, 0.1, -0.32, 0.1, 0.05, -0.27, 0.1, 0.05, 0.27, 0.1, 0.1, 0.32, 0.1, 0.1, -0.32, 0.1, 0.05, -0.27, 0.05, -0.19, 0.27, 0.05, 0.05, 0.27, 0.05, 0.05, -0.27, 0.05, -0.19, -0.27, 0.05, -0.19, 0.27, 0.05, -0.19, -0.27, 0.1, 0.05, -0.27, 0.05, 0.05, -0.27, 0.1, -0.19, -0.27, 0.1, -0.19, -0.27, 0.05, 0.05, -0.27, 0.05, 0.05, 0.27, 0.1, -0.19, 0.27, 0.05, -0.19, 0.27, 0.1, 0.05, 0.27, 0.1, 0.05, 0.27, 0.05, -0.19, 0.27, 0.05, 0.05, -0.27, 0.1, 0.05, 0.27, 0.05, 0.05, 0.27, 0.1, 0.05, -0.27, 0.1, 0.05, -0.27, 0.05, 0.05, 0.27, 0.05, -0.175, 0.195, 0.075, -0.175, 0.245, 0.025, -0.175, 0.245, 0.075, -0.175, 0.195, 0.075, -0.175, 0.195, 0.025, -0.175, 0.245, 0.025, 0.0175, 0.195, 0.025, 0.035, 0.245, 0.025, 0.0175, 0.245, 0.025, 0.0175, 0.195, 0.025, 0.035, 0.195, 0.025, 0.035, 0.245, 0.025, 0.035, 0.195, 0.025, 0.035, 0.245, 0.075, 0.035, 0.245, 0.025, 0.035, 0.195, 0.025, 0.035, 0.195, 0.075, 0.035, 0.245, 0.075, -0.1575, 0.195, 0.075, -0.175, 0.245, 0.075, -0.1575, 0.245, 0.075, -0.1575, 0.195, 0.075, -0.175, 0.195, 0.075, -0.175, 0.245, 0.075, 0.0175, -0.225, 0.075, 0.0175, -0.25, 0.05, 0.0175, -0.225, 0.025, -0.1575, 0.245, 0.025, -0.175, 0.245, 0.075, -0.175, 0.245, 0.025, -0.1575, 0.245, 0.025, -0.1575, 0.245, 0.075, -0.175, 0.245, 0.075, 0.035, 0.245, 0.025, 0.0175, 0.245, 0.075, 0.0175, 0.245, 0.025, 0.035, 0.245, 0.025, 0.035, 0.245, 0.075, 0.0175, 0.245, 0.075, 0.0175, 0.245, 0.025, -0.1575, 0.245, 0.075, -0.1575, 0.245, 0.025, 0.0175, 0.245, 0.025, 0.0175, 0.245, 0.075, -0.1575, 0.245, 0.075, -0.175, 0.195, 0.075, -0.175, -0.225, 0.025, -0.175, 0.195, 0.025, -0.175, 0.195, 0.075, -0.175, -0.225, 0.075, -0.175, -0.225, 0.025, -0.1575, 0.195, 0.025, 0.0175, 0.195, 0.075, 0.0175, 0.195, 0.025, -0.1575, 0.195, 0.025, -0.1575, 0.195, 0.075, 0.0175, 0.195, 0.075, 0.035, 0.195, 0.075, 0.0175, 0.245, 0.075, 0.035, 0.245, 0.075, 0.035, 0.195, 0.075, 0.0175, 0.195, 0.075, 0.0175, 0.245, 0.075, 0.0175, 0.195, 0.075, -0.1575, 0.245, 0.075, 0.0175, 0.245, 0.075, 0.0175, 0.195, 0.075, -0.1575, 0.195, 0.075, -0.1575, 0.245, 0.075, -0.175, 0.195, 0.025, -0.1575, 0.245, 0.025, -0.175, 0.245, 0.025, -0.175, 0.195, 0.025, -0.1575, 0.195, 0.025, -0.1575, 0.245, 0.025, -0.1575, 0.195, 0.025, 0.0175, 0.245, 0.025, -0.1575, 0.245, 0.025, -0.1575, 0.195, 0.025, 0.0175, 0.195, 0.025, 0.0175, 0.245, 0.025, 0.035, 0.195, 0.075, 0.0175, -0.225, 0.075, 0.0175, 0.195, 0.075, 0.035, 0.195, 0.075, 0.035, -0.225, 0.075, 0.0175, -0.225, 0.075, -0.175, 0.195, 0.025, -0.1575, -0.225, 0.025, -0.1575, 0.195, 0.025, -0.175, 0.195, 0.025, -0.175, -0.225, 0.025, -0.1575, -0.225, 0.025, 0.0175, 0.195, 0.025, 0.035, -0.225, 0.025, 0.035, 0.195, 0.025, 0.0175, 0.195, 0.025, 0.0175, -0.225, 0.025, 0.035, -0.225, 0.025, -0.1575, 0.195, 0.075, -0.175, -0.225, 0.075, -0.175, 0.195, 0.075, -0.1575, 0.195, 0.075, -0.1575, -0.225, 0.075, -0.175, -0.225, 0.075, 0.035, -0.225, 0.025, 0.035,
2025-03-05 15:35:49 -07:00
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_21svm"]
2025-03-13 12:25:04 -06:00
resource_local_to_scene = true
2025-03-05 15:35:49 -07:00
albedo_color = Color(0, 0, 0, 1)
emission_enabled = true
emission = Color(0.866667, 0.109804, 0.101961, 1)
emission_energy_multiplier = 0.0
[sub_resource type="BoxMesh" id="BoxMesh_g24yf"]
2025-03-13 12:25:04 -06:00
resource_local_to_scene = true
2025-03-05 15:35:49 -07:00
material = SubResource("StandardMaterial3D_21svm")
size = Vector3(0.08, 0.05, 0.025)
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_0cc87"]
2025-03-13 12:25:04 -06:00
resource_local_to_scene = true
2025-03-05 15:35:49 -07:00
albedo_color = Color(0, 0, 0, 1)
emission_enabled = true
emission = Color(0.137255, 0.984314, 0.34902, 1)
emission_energy_multiplier = 0.0
[sub_resource type="BoxMesh" id="BoxMesh_a6hjm"]
2025-03-13 12:25:04 -06:00
resource_local_to_scene = true
2025-03-05 15:35:49 -07:00
material = SubResource("StandardMaterial3D_0cc87")
size = Vector3(0.08, 0.05, 0.025)
2025-03-05 17:57:55 -07:00
[sub_resource type="Animation" id="Animation_ugm6b"]
length = 0.001
2025-03-05 14:46:13 -07:00
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
2025-03-05 15:35:49 -07:00
tracks/0/path = NodePath("Lights/DangerLight:mesh:material:emission_energy_multiplier")
2025-03-05 17:57:55 -07:00
tracks/0/interp = 1
2025-03-05 14:46:13 -07:00
tracks/0/loop_wrap = true
tracks/0/keys = {
2025-03-05 17:57:55 -07:00
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
2025-03-05 14:46:13 -07:00
"update": 0,
2025-03-05 17:57:55 -07:00
"values": [0.0]
2025-03-05 14:46:13 -07:00
}
2025-03-05 15:35:49 -07:00
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("Lights/SuccessLight:mesh:material:emission_energy_multiplier")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [0.0]
}
2025-03-29 19:32:24 -06:00
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Lights/SuccessLight/SuccessSFX:playing")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [false]
}
2025-03-05 14:46:13 -07:00
2025-03-13 12:25:04 -06:00
[sub_resource type="Animation" id="Animation_6aabu"]
resource_name = "disable"
length = 2.0
step = 0.05
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Lights/SuccessLight:mesh:material:emission_energy_multiplier")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 2),
2025-03-20 17:46:01 -06:00
"transitions": PackedFloat32Array(0.269, 1),
2025-03-13 12:25:04 -06:00
"update": 0,
2025-03-20 17:46:01 -06:00
"values": [8.0, 0.0]
2025-03-13 12:25:04 -06:00
}
2025-03-05 17:57:55 -07:00
[sub_resource type="Animation" id="Animation_pea1n"]
resource_name = "error_blink"
length = 4.0
loop_mode = 1
2025-03-05 14:46:13 -07:00
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
2025-03-05 15:35:49 -07:00
tracks/0/path = NodePath("Lights/DangerLight:mesh:material:emission_energy_multiplier")
2025-03-05 17:57:55 -07:00
tracks/0/interp = 2
2025-03-05 14:46:13 -07:00
tracks/0/loop_wrap = true
tracks/0/keys = {
2025-03-05 17:57:55 -07:00
"times": PackedFloat32Array(0, 1, 3, 4),
"transitions": PackedFloat32Array(0.618, 1, 1.618, 1),
2025-03-05 14:46:13 -07:00
"update": 0,
2025-03-05 17:57:55 -07:00
"values": [0.0, 4.0, 4.0, 0.0]
2025-03-05 14:46:13 -07:00
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
2025-03-05 15:35:49 -07:00
tracks/1/path = NodePath("Lights/SuccessLight:mesh:material:emission_energy_multiplier")
2025-03-05 14:46:13 -07:00
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [0.0]
}
[sub_resource type="Animation" id="Animation_njbf4"]
resource_name = "success"
length = 0.5
step = 0.05
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
2025-03-05 15:35:49 -07:00
tracks/0/path = NodePath("Lights/SuccessLight:mesh:material:emission_energy_multiplier")
2025-03-05 14:46:13 -07:00
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45),
"transitions": PackedFloat32Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
"update": 1,
2025-03-20 17:46:01 -06:00
"values": [0.0, 8.0, 0.0, 8.0, 0.0, 8.0, 0.0, 8.0, 0.0, 8.0]
2025-03-05 15:35:49 -07:00
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("Lights/DangerLight:mesh:material:emission_energy_multiplier")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [0.0]
2025-03-05 14:46:13 -07:00
}
2025-03-29 19:32:24 -06:00
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Lights/SuccessLight/SuccessSFX:playing")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [true]
}
2025-03-05 14:46:13 -07:00
[sub_resource type="AnimationLibrary" id="AnimationLibrary_6ueib"]
_data = {
2025-03-06 16:06:17 -07:00
&"RESET": SubResource("Animation_ugm6b"),
2025-03-10 17:00:30 -06:00
&"disable": SubResource("Animation_6aabu"),
2025-03-06 16:06:17 -07:00
&"error_blink": SubResource("Animation_pea1n"),
&"success": SubResource("Animation_njbf4")
2025-03-05 14:46:13 -07:00
}
[sub_resource type="BoxShape3D" id="BoxShape3D_6maql"]
size = Vector3(0.475, 0.65, 0.2)
[sub_resource type="SphereShape3D" id="SphereShape3D_mxsyy"]
radius = 3.0
2025-04-22 12:08:09 -06:00
[node name="WallSwitch" groups=["Persistent"] instance=ExtResource("2_whafo")]
2025-03-05 14:46:13 -07:00
script = ExtResource("2_kfvqd")
2025-03-20 17:46:01 -06:00
enabled = true
2025-04-19 09:49:07 -06:00
label = "INTERACTIVE_SWITCH_LABEL"
2025-03-05 14:46:13 -07:00
[node name="WallSwitch_2" parent="Armature/Skeleton3D" index="0"]
surface_material_override/0 = SubResource("StandardMaterial3D_jtkkw")
2025-03-05 14:46:13 -07:00
2025-03-05 15:35:49 -07:00
[node name="AnimationPlayer" parent="." index="1"]
unique_name_in_owner = true
2025-03-05 14:46:13 -07:00
[node name="GunkBody" parent="." index="2" node_paths=PackedStringArray("mesh_instance") instance=ExtResource("7_3ib1l")]
2025-03-05 15:35:49 -07:00
unique_name_in_owner = true
2025-03-09 16:40:19 -06:00
mask_dim = 48
2025-03-05 14:46:13 -07:00
mesh_instance = NodePath("../Armature/Skeleton3D/WallSwitch_2")
source_gunk_material = ExtResource("8_2qpft")
2025-03-05 14:46:13 -07:00
[node name="CollisionShape3D" type="CollisionShape3D" parent="GunkBody" index="1"]
shape = SubResource("ConcavePolygonShape3D_1xqlp")
2025-03-05 15:35:49 -07:00
[node name="Lights" type="Node3D" parent="." index="3"]
2025-03-05 14:46:13 -07:00
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.17, 0.24, 0.1)
2025-03-05 15:35:49 -07:00
[node name="DangerLight" type="MeshInstance3D" parent="Lights" index="0"]
2025-04-19 20:04:54 -06:00
gi_mode = 2
2025-03-05 14:46:13 -07:00
mesh = SubResource("BoxMesh_g24yf")
2025-03-05 15:35:49 -07:00
[node name="SuccessLight" type="MeshInstance3D" parent="Lights" index="1"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.06, 0)
2025-04-19 20:04:54 -06:00
gi_mode = 2
2025-03-05 14:46:13 -07:00
mesh = SubResource("BoxMesh_a6hjm")
2025-03-29 19:32:24 -06:00
[node name="SuccessSFX" type="AudioStreamPlayer3D" parent="Lights/SuccessLight" index="0"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.17, -0.18, -0.1)
stream = ExtResource("11_7shuc")
volume_db = -16.0
unit_size = 4.0
bus = &"SFX"
2025-03-05 15:35:49 -07:00
[node name="LightAnimation" type="AnimationPlayer" parent="Lights" index="2"]
unique_name_in_owner = true
root_node = NodePath("../..")
libraries = {
2025-03-06 16:06:17 -07:00
&"": SubResource("AnimationLibrary_6ueib")
2025-03-05 15:35:49 -07:00
}
autoplay = "error_blink"
2025-03-05 14:46:13 -07:00
[node name="Interactive" type="StaticBody3D" parent="." index="4"]
2025-03-05 15:35:49 -07:00
unique_name_in_owner = true
2025-03-05 14:46:13 -07:00
collision_layer = 2
collision_mask = 0
script = ExtResource("10_qw6jt")
2025-04-19 09:49:07 -06:00
label = "INTERACTIVE_SWITCH_LABEL"
verb = "INTERACTIVE_SWITCH_VERB"
2025-03-05 14:46:13 -07:00
[node name="CollisionShape3D" type="CollisionShape3D" parent="Interactive" index="0"]
shape = SubResource("BoxShape3D_6maql")
2025-03-05 15:35:49 -07:00
2025-04-02 21:03:36 -06:00
[node name="ActionSFX" type="AudioStreamPlayer3D" parent="." index="5"]
unique_name_in_owner = true
stream = ExtResource("12_2qpft")
volume_db = -12.0
unit_size = 3.0
bus = &"SFX"
[node name="ActionDelay" type="Timer" parent="." index="6"]
unique_name_in_owner = true
wait_time = 2.8
one_shot = true
[node name="WallSwitchGameSoundEmitter" type="Area3D" parent="." index="7"]
collision_layer = 0
collision_mask = 16
script = ExtResource("13_eim2y")
metadata/_custom_type_script = "uid://c5o1d2shq2qig"
[node name="CollisionShape3D" type="CollisionShape3D" parent="WallSwitchGameSoundEmitter" index="0"]
shape = SubResource("SphereShape3D_mxsyy")
2025-03-05 15:35:49 -07:00
[connection signal="animation_finished" from="AnimationPlayer" to="." method="_animation_finished"]
[connection signal="clear_total_updated" from="GunkBody" to="." method="_on_gunk_body_clear_total_updated"]
2025-03-05 15:35:49 -07:00
[connection signal="activated" from="Interactive" to="." method="_activate"]
2025-04-02 21:03:36 -06:00
[connection signal="timeout" from="ActionDelay" to="." method="_on_action_delay_timeout"]
[connection signal="timeout" from="ActionDelay" to="WallSwitchGameSoundEmitter" method="emit_sound_here"]