[gd_scene load_steps=5 format=3 uid="uid://5uv1idl3lqet"]

[ext_resource type="Script" uid="uid://d0jwv5opi3mrl" path="res://scenes/pribor-afsp/pribor-afsp.gd" id="1_tfses"]
[ext_resource type="Script" uid="uid://bux47vkw71w1t" path="res://scenes/контроль/request.gd" id="2_miwrd"]
[ext_resource type="PackedScene" uid="uid://dnxq870xf6pkh" path="res://scenes/контроль/bort-afsp.tscn" id="3_xpxb5"]

[sub_resource type="GDScript" id="GDScript_yhnwg"]
script/source = "extends Timer

func _ready(): wait_time = ProjectSettings.get_setting('application/config/unit_rr_request_period')
"

[node name="pribor_afsp" type="Control"]
layout_mode = 3
anchors_preset = 0
offset_left = 81.0
offset_top = 108.0
offset_right = 81.0
offset_bottom = 108.0
scale = Vector2(1, 0.9)
script = ExtResource("1_tfses")
unit_name = &"уарэп-афсп-правый"
metadata/DeviceName = &"Устройство РР правого борта"

[node name="request" type="HTTPRequest" parent="."]
use_threads = true
script = ExtResource("2_miwrd")
projsettings_path_left = "application/config/Адрес АФСП левого борта"
projsettings_path_right = "application/config/Адрес АФСП правого борта"

[node name="timer" type="Timer" parent="request"]
wait_time = 30.0
autostart = true
script = SubResource("GDScript_yhnwg")

[node name="bort" parent="." instance=ExtResource("3_xpxb5")]
layout_mode = 0
offset_left = -11.0
offset_top = -59.0
offset_right = 569.0
offset_bottom = 1130.0
metadata/DeviceName = &"Устройство РР правого борта"

[connection signal="child_entered_tree" from="request" to="request" method="_on_child_entered_tree"]
[connection signal="request_completed" from="request" to="." method="_on_request_completed"]
[connection signal="timeout" from="request/timer" to="request" method="_on_request_timer"]
[connection signal="pressed" from="bort" to="." method="_on_item_pressed"]
