diff --git a/content/entities/sensor/sensor.gd b/content/entities/sensor/sensor.gd index 78fd781..fff70fb 100644 --- a/content/entities/sensor/sensor.gd +++ b/content/entities/sensor/sensor.gd @@ -5,6 +5,9 @@ extends StaticBody3D # Called when the node enters the scene tree for the first time. func _ready(): + if HomeApi.has_connected() == false: + await HomeApi.on_connect + var stateInfo = await HomeApi.get_state(entity_id) set_text(stateInfo)