Spawning blueprint actor from c++

I think it’s not thread-safe to create any UObject (which includes AActors) from a non-game thread (and modifying UObjects in certain ways as well), as the garbage collector runs on the game thread unsyncronized with non-game threads, and I don’t think the garbage collector is threadsafe/lockfree. As for getting the callback from your TCP socket onto the game thread, I believe there is a function “defer into game thread” or something, where you can pass a functor that will be called later on the game thread.