[gd_scene load_steps=8 format=3 uid="uid://qknkdy6aics1"]

[ext_resource type="Script" uid="uid://d1e003a8jg3gm" path="res://src/equipment/toothbrush/toothbrush.gd" id="1_ivelq"]
[ext_resource type="Script" uid="uid://dj2x7x5qkbym1" path="res://src/ui/canvas_projector.gd" id="2_awr0g"]
[ext_resource type="Texture2D" uid="uid://6vc3ye0jnqy4" path="res://assets/ui/hud/tools/toothbrush_idle.png" id="3_sxute"]
[ext_resource type="Texture2D" uid="uid://djisqgfxhsrs2" path="res://assets/ui/hud/tools/toothbrush_used.png" id="4_atd0h"]

[sub_resource type="Animation" id="Animation_atd0h"]
resource_name = "brush"
length = 0.6
loop_mode = 1
tracks/0/type = "bezier"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("HUDTool/NozzleMarker/HUDElement/Pivot/TextureUsed:position:x")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"handle_modes": PackedInt32Array(0, 0, 0),
"points": PackedFloat32Array(-40, -0.1, 0, 0.1, 0, 40, -0.1, 0, 0.1, 0, -40, -0.1, 0, 0.1, 0),
"times": PackedFloat32Array(0, 0.3, 0.6)
}
tracks/1/type = "bezier"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("HUDTool/NozzleMarker/HUDElement/Pivot/TextureUsed:position:y")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"handle_modes": PackedInt32Array(0, 0),
"points": PackedFloat32Array(0, -0.2, 0, 0.3, 140, 0, -0.3, -140, 0.2, 0),
"times": PackedFloat32Array(0, 0.6)
}

[sub_resource type="Animation" id="Animation_8x7qe"]
length = 0.001
tracks/0/type = "bezier"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("HUDTool/NozzleMarker/HUDElement/Pivot/TextureUsed:position:x")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"handle_modes": PackedInt32Array(0),
"points": PackedFloat32Array(0, -0.2, 0, 0.2, 0),
"times": PackedFloat32Array(0)
}
tracks/1/type = "bezier"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("HUDTool/NozzleMarker/HUDElement/Pivot/TextureUsed:position:y")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"handle_modes": PackedInt32Array(0),
"points": PackedFloat32Array(0, -0.2, 0, 0.2, 0),
"times": PackedFloat32Array(0)
}

[sub_resource type="AnimationLibrary" id="AnimationLibrary_8x7qe"]
_data = {
&"RESET": SubResource("Animation_8x7qe"),
&"brush": SubResource("Animation_atd0h")
}

[node name="Toothbrush" type="Node3D"]
script = ExtResource("1_ivelq")
metadata/_custom_type_script = "uid://caygiek3vmx1g"

[node name="Raycast" type="RayCast3D" parent="."]
unique_name_in_owner = true
transform = Transform3D(1, 0, 0, 0, 0.997564, -0.0697565, 0, 0.0697565, 0.997564, 0, 0, -0.15)
target_position = Vector3(0, 0, -1)
collision_mask = 4

[node name="HUDTool" type="Node3D" parent="."]
unique_name_in_owner = true

[node name="NozzleMarker" type="Marker3D" parent="HUDTool"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.2)
script = ExtResource("2_awr0g")

[node name="HUDElement" type="Control" parent="HUDTool/NozzleMarker"]
layout_mode = 3
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
grow_horizontal = 2
grow_vertical = 2

[node name="Pivot" type="Control" parent="HUDTool/NozzleMarker/HUDElement"]
anchors_preset = 0
offset_left = -200.0
offset_top = -256.0
offset_right = -200.0
offset_bottom = -256.0

[node name="TextureIdle" type="TextureRect" parent="HUDTool/NozzleMarker/HUDElement/Pivot"]
unique_name_in_owner = true
texture_filter = 1
layout_mode = 0
offset_right = 64.0
offset_bottom = 128.0
scale = Vector2(5, 5)
texture = ExtResource("3_sxute")

[node name="TextureUsed" type="TextureRect" parent="HUDTool/NozzleMarker/HUDElement/Pivot"]
unique_name_in_owner = true
visible = false
texture_filter = 1
layout_mode = 0
offset_left = -40.0
offset_right = 24.0
offset_bottom = 128.0
scale = Vector2(5, 5)
texture = ExtResource("4_atd0h")

[node name="BrushAnimation" type="AnimationPlayer" parent="."]
unique_name_in_owner = true
libraries = {
&"": SubResource("AnimationLibrary_8x7qe")
}
