@@ -110,6 +110,7 @@ func _ready():
uf_control = UFControl.new('уарэп-эмс')
signaller.connect('update_uf_serviceability', Callable(self, 'on_update_uf_serviceability').bind(pribor_node))
# Пиктограммы приборов, которые отображают состояние подключения только
for pribor_node in get_tree().get_nodes_in_group('pribor_pics'):
var unit_name = pribor_node.get_meta('unit_name')
@@ -166,14 +167,24 @@ func on_pribor_press(pribor_path, header_text, pribor_node):
pribor.add_to_group('pribor_items')
add_child(pribor)
update_pribor_items_visibility()
if pribor_node.get_meta('unit_name')[0] == 'уарэп-афсп-левый' or pribor_node.get_meta('unit_name')[0] == 'уарэп-афсп-правый':
var req = pribor.request_url
req.connect('sending_request', Callable(self, 'on_sending_request').bind(pribor_node, pribor.time_req.wait_time))
# Вызов при отправке запроса на селфтест АФСП
func on_sending_request(node: Node, time_req: float) -> void:
node.progress_max_value = time_req
node.progress_visible = true
node.timeout_tween = time_req
## Прием сигналов о текущем состояниях приборах
func on_serviceability_changed(state: int, prd_pribor_node: Node)-> void:
func on_serviceability_changed(state: int, prd_pribor_node: Node) -> void:
prd_pribor_node.state = state
func on_update_uf_serviceability(uf_serviceaability: int, uf_pribor: Node)-> void:
func on_update_uf_serviceability(uf_serviceaability: int, uf_pribor: Node) -> void:
uf_pribor.state = uf_serviceaability
@@ -558,6 +569,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(100, 0, 0, 1)]
timeout_tween = null
metadata/online_proc = "on_line_changed"
metadata/unit_name = ["уарэп-яу 07-1н"]
@@ -643,18 +655,20 @@ frame_progress = 0.72355
[node name="pribor_uf" type="TextureButton" parent="." groups=["pribor_buttons"]]
editor_description = "Кнопка для выбора прибора."
layout_mode = 0
offset_left = 1183 .0
offset_top = 55 8.0
offset_right = 1294 .0
offset_left = 1188 .0
offset_top = 581 .0
offset_right = 1285 .0
offset_bottom = 743.0
size_flags_horizontal = 15
size_flags_vertical = 15
toggle_mode = true
action_mode = 0
texture_normal = ExtResource("2_0nvm1")
ignore_texture_size = true
stretch_mode = 0
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-эмс"]
metadata/online_proc = "on_line_changed"
@@ -753,6 +767,7 @@ texture_normal = ExtResource("3_hhadv")
stretch_mode = 0
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = [&"уарэп-бпо-1", &"уарэп-бпо-2"]
metadata/online_proc = "online_change_arr"
@@ -781,16 +796,6 @@ patch_margin_top = 16
patch_margin_right = 16
patch_margin_bottom = 16
[node name="label2" type="Label" parent="pribor_rtr"]
layout_mode = 0
offset_left = 11.0
offset_top = -49.0
offset_right = 94.0
offset_bottom = -30.0
text = "Р Т Р "
horizontal_alignment = 1
vertical_alignment = 1
[node name="pic_functional" type="TextureRect" parent="pribor_rtr"]
visible = false
z_index = 1
@@ -827,8 +832,8 @@ editor_description = "Кнопка для выбора прибора."
layout_mode = 0
offset_left = 1053.0
offset_top = 425.0
offset_right = 1886 .0
offset_bottom = 106 5.0
offset_right = 1853 .0
offset_bottom = 102 5.0
scale = Vector2(0.2, 0.2)
pivot_offset = Vector2(-10, -65)
size_flags_horizontal = 15
@@ -836,9 +841,11 @@ size_flags_vertical = 15
toggle_mode = true
action_mode = 0
texture_normal = ExtResource("9_iqgf5")
ignore_texture_size = true
stretch_mode = 0
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = [&"уарэп-афсп-левый"]
metadata/online_proc = "on_line_changed"
@@ -857,9 +864,9 @@ vertical_alignment = 1
visible = false
self_modulate = Color(0.890196, 0.486275, 0.196078, 1)
layout_mode = 0
offset_left = -60 .0
offset_top = -165 .0
offset_right = 130 .0
offset_left = -55 .0
offset_top = -170 .0
offset_right = 125 .0
offset_bottom = 10.0
scale = Vector2(5, 5)
texture = ExtResource("4_rasbe")
@@ -869,17 +876,6 @@ patch_margin_top = 16
patch_margin_right = 16
patch_margin_bottom = 16
[node name="label2" type="Label" parent="pribor_afsp_1"]
layout_mode = 0
offset_left = 175.0
offset_top = -245.0
offset_right = 272.0
offset_bottom = -225.0
scale = Vector2(5, 5)
text = "АФСП 1"
horizontal_alignment = 1
vertical_alignment = 1
[node name="pic_functional" type="TextureRect" parent="pribor_afsp_1"]
visible = false
z_index = 1
@@ -911,13 +907,36 @@ scale = Vector2(3, 2.981)
sprite_frames = SubResource("SpriteFrames_foasq")
frame_progress = 0.72355
[node name="control_progress" type="TextureProgressBar" parent="pribor_afsp_1"]
visible = false
offset_left = 15.0
offset_top = 735.0
offset_right = 815.0
offset_bottom = 775.0
size_flags_horizontal = 3
size_flags_vertical = 3
tooltip_text = "
Текущее: 0.00"
mouse_filter = 0
max_value = 30.0
value = 8.0
nine_patch_stretch = true
stretch_margin_left = 5
stretch_margin_top = 5
stretch_margin_right = 5
stretch_margin_bottom = 5
texture_under = ExtResource("9_w6m6a")
texture_progress = ExtResource("10_lbx5w")
tint_under = Color(1, 1, 1, 0.419608)
tint_progress = Color(0.890196, 0.486275, 0.196078, 1)
[node name="pribor_afsp_2" type="TextureButton" parent="." groups=["pribor_buttons"]]
editor_description = "Кнопка для выбора прибора."
layout_mode = 0
offset_left = 1243.0
offset_top = 425.0
offset_right = 2076 .0
offset_bottom = 106 5.0
offset_right = 2043 .0
offset_bottom = 102 5.0
scale = Vector2(0.2, 0.2)
pivot_offset = Vector2(-10, -65)
size_flags_horizontal = 15
@@ -925,10 +944,12 @@ size_flags_vertical = 15
toggle_mode = true
action_mode = 0
texture_normal = ExtResource("9_iqgf5")
ignore_texture_size = true
stretch_mode = 0
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = [&"уарэп-афсп-правый"]
metadata/online_proc = "on_line_changed"
@@ -948,8 +969,8 @@ visible = false
self_modulate = Color(0.890196, 0.486275, 0.196078, 1)
layout_mode = 0
offset_left = -50.0
offset_top = -165 .0
offset_right = 14 0.0
offset_top = -170 .0
offset_right = 13 0.0
offset_bottom = 10.0
scale = Vector2(5, 5)
texture = ExtResource("4_rasbe")
@@ -959,17 +980,6 @@ patch_margin_top = 16
patch_margin_right = 16
patch_margin_bottom = 16
[node name="label2" type="Label" parent="pribor_afsp_2"]
layout_mode = 0
offset_left = 175.0
offset_top = -240.0
offset_right = 272.0
offset_bottom = -220.0
scale = Vector2(5, 5)
text = "АФСП 2"
horizontal_alignment = 1
vertical_alignment = 1
[node name="pic_functional" type="TextureRect" parent="pribor_afsp_2"]
visible = false
z_index = 1
@@ -1001,21 +1011,46 @@ scale = Vector2(3, 2.981)
sprite_frames = SubResource("SpriteFrames_foasq")
frame_progress = 0.72355
[node name="control_progress" type="TextureProgressBar" parent="pribor_afsp_2"]
visible = false
offset_left = 20.0
offset_top = 735.0
offset_right = 825.0
offset_bottom = 775.0
size_flags_horizontal = 3
size_flags_vertical = 3
tooltip_text = "
Текущее: 0.00"
mouse_filter = 0
max_value = 30.0
value = 8.0
nine_patch_stretch = true
stretch_margin_left = 5
stretch_margin_top = 5
stretch_margin_right = 5
stretch_margin_bottom = 5
texture_under = ExtResource("9_w6m6a")
texture_progress = ExtResource("10_lbx5w")
tint_under = Color(1, 1, 1, 0.419608)
tint_progress = Color(0.890196, 0.486275, 0.196078, 1)
[node name="pribor_uyep" type="TextureButton" parent="." groups=["pribor_buttons"]]
editor_description = "Кнопка для выбора прибора."
layout_mode = 0
offset_left = 1313.0
offset_top = 55 8.0
offset_right = 1407 .0
offset_top = 584 .0
offset_right = 1394 .0
offset_bottom = 744.0
size_flags_horizontal = 15
size_flags_vertical = 15
toggle_mode = true
action_mode = 0
texture_normal = ExtResource("5_kvnex")
ignore_texture_size = true
stretch_mode = 0
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-щ3", "уарэп-с пт25-1", "уарэп-с пт25-2"]
metadata/online_proc = "online_change_arr"
@@ -1091,6 +1126,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-2в"]
metadata/online_proc = "on_line_changed"
@@ -1189,6 +1225,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-2н"]
metadata/online_proc = "on_line_changed"
@@ -1289,6 +1326,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-2к"]
metadata/online_proc = "on_line_changed"
@@ -1387,6 +1425,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-3в"]
metadata/online_proc = "on_line_changed"
@@ -1485,6 +1524,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-3н"]
metadata/online_proc = "on_line_changed"
@@ -1583,6 +1623,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 1, 0, 1), Color(1, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-3к"]
metadata/online_proc = "on_line_changed"
@@ -1681,6 +1722,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(100, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-1в"]
metadata/online_proc = "on_line_changed"
@@ -1778,6 +1820,7 @@ stretch_mode = 4
flip_h = true
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(100, 0, 0, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-1к"]
metadata/online_proc = "on_line_changed"
@@ -1875,6 +1918,7 @@ texture_normal = ExtResource("6_i1yfn")
stretch_mode = 4
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(0.65, 0.0715, 0.0715, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-4в"]
metadata/online_proc = "on_line_changed"
@@ -1972,6 +2016,7 @@ texture_normal = ExtResource("6_i1yfn")
stretch_mode = 4
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(0.65, 0.0715, 0.0715, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-4н"]
metadata/online_proc = "on_line_changed"
@@ -2069,6 +2114,7 @@ texture_normal = ExtResource("6_i1yfn")
stretch_mode = 4
script = ExtResource("3_4pt7j")
state_colors = [Color(1, 1, 1, 1), Color(0, 0.87, 0, 1), Color(0.65, 0.0715, 0.0715, 1)]
timeout_tween = null
metadata/unit_name = ["уарэп-яу 07-4к"]
metadata/online_proc = "on_line_changed"