Nope, i found that the changes between engine versions are often breaking and that most examples for C++ dont work. I decided against sticking with an old version as so many new features and improvements are released each time.
Rama’s tutorials are super helpful buti find myself often frustrated with all the extra fluff, when i just want simple threading like std::thread.
With that in mind, and the fact that visual studio’s intellisense is appalling when working with UE4 (worse with source) even on a high end system with SSD’s i decided to cancel my subscription and try out Unity3d.
Until there’s a clear sources of documentation for each release with working c++ examples i wont be returning. Epic seems to be focusing on the blueprint faff.
**Im told that there are third party plugins that solve the code completion problem but they cost more than the engine did itself (when it wasnt free).
I had the same issue and recently found out it happens because of PBThread->Kill(true); section simple solution : in case you do not use any lock in your RUN() function then just simply call it with PBThread->Kill(false);
problem is that within the Kill function of FrunnableThread there is an wait for infinity which in actually should never takes a long time after calling Close function. but strangely it stuck there
virtual bool Kill( bool bShouldWait = false ) override
{
check(Thread && "Did you forget to call Create()?");
bool bDidExitOK = true;
// Let the runnable have a chance to stop without brute force killing
if (Runnable)
{
Runnable->Stop();
}
// If waiting was specified, wait the amount of time. If that fails,
// brute force kill that thread. Very bad as that might leak.
if (bShouldWait == true)
{
// Wait indefinitely for the thread to finish. IMPORTANT: It's not safe to just go and
// kill the thread with TerminateThread() as it could have a mutex lock that's shared
// with a thread that's continuing to run, which would cause that other thread to
// dead-lock. (This can manifest itself in code as simple as the synchronization
// object that is used by our logging output classes. Trust us, we've seen it!)
WaitForSingleObject(Thread,INFINITE);
}
// Now clean up the thread handle so we don't leak
CloseHandle(Thread);
Thread = NULL;
return bDidExitOK;
}
I agree with everything you have said. It is also a shame that it is so very difficult to get any replies on this answers site. Unfortunately, I have to stick with UE4 for my PhD…