Доработка. Сообщение "Тип 8" для КАПС-РПБ

This commit is contained in:
sasha80
2025-07-09 13:16:27 +03:00
parent 3549ca2644
commit b800983615

View File

@@ -129,7 +129,7 @@ func _ready() -> void:
threats.connect('threat_lost', Callable(self, 'on_threats_lost').bind(ecms, unit_caps))
var key = settings.get_unit_key('навигация')
var unit_nav = network.units[key]
unit_nav.connect('data_received', on_nav_data_received.bind())
unit_nav.connect('data_received', on_nav_data_received.bind(unit_caps))
func on_nav_data_received(coords: Dictionary, unit_caps):
@@ -142,6 +142,7 @@ func on_nav_data_received(coords: Dictionary, unit_caps):
'lat': coords.get('latitude', 0),
'course': coords.get('k', 0),
'speed': coords.get('speed', 0) }
print_debug(data_to_json)
var json_data = JSON.stringify(data_to_json).to_utf8_buffer()
unit_caps.tx_stack.append(json_data)
msg8_num += 1