fix socat_terminal example

* Godot 4.x seems to require call StreamPeerTCP.poll
* add missing signal connection (data from terminal to network)
This commit is contained in:
Robert Paciorek 2024-06-08 13:25:27 +00:00 committed by Leroy Hopson
parent 9569c9e489
commit e830db667c
2 changed files with 3 additions and 0 deletions

View file

@ -19,6 +19,7 @@ func _ready():
func _process(delta):
_stream.poll()
match _stream.get_status():
StreamPeerTCP.STATUS_NONE, StreamPeerTCP.STATUS_CONNECTING:
_timeout -= 1

View file

@ -11,3 +11,5 @@ grow_horizontal = 2
grow_vertical = 2
theme = ExtResource("1_rw2ub")
script = ExtResource("1")
[connection signal="data_sent" from="." to="." method="_on_Terminal_data_sent"]