Fix receiving packets
This commit is contained in:
parent
372468b5a1
commit
231b639901
2 changed files with 6 additions and 1 deletions
|
|
@ -56,6 +56,11 @@ void MarshConnector::_process(double delta) {
|
|||
|
||||
if (!socket->is_socket_connected()) {
|
||||
socket->connect_to_host("127.0.0.1", 24400);
|
||||
} else {
|
||||
while (socket->get_available_packet_count() > 0) {
|
||||
const PackedByteArray data = socket->get_packet();
|
||||
receive_data(data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue