Oh wow thank you for sharing your code too with everyone!
This should get everyone going with sockets in UE4 quite easily!
Do you want me to add a link to your bitbucket to my wiki?
My favorite thing from your code base, other than your own personal way of converting the stream to FString as you mentioned, was your use of the *TCPListener* class!
Very nice!
One thing you might want to watch out for, if your module is ever used in conjunction with PIE, is the complete shutting down of the
```
FSocket* Client;
```
I found that in PIE, the socket connection would be held on to by the Editor, but in command prompt running of the game / editor closed this did not occur.
**The result was that if I tried to reconnect to the socket in successive PIE instances, it would only work the first time :)**
My solution was to ensure that I called this, which you'd probably put in your ShutdownModule()
```
if(Client)
{
Client->Close();
ISocketSubsystem::Get(PLATFORM_SOCKETSUBSYSTEM)->DestroySocket(Client);
}
```
I dont think this will come up in your case but I wanted to mention it for future readers as well as something I encountered and the solution I found.
:)
Thanks again for sharing Alfafasprossen!
:)
PS: I emailed the author of the python script about sharing it publically :)