I can't draw HUD on the scene on the FirstPersonExampleMap with C++

Hello Epic Community,

I’m an absolute beginner with UE4 because I came from Unity. Because I’m a programmer, I’d like to use C++ for my project, but it’s really hard to master Unreal programming. No good up to date tuts for people like me.

I started a First Person Shooter with C++ and I try to make any HUD elements appear on the scene at runtime. I use DrawText() and DrawLine() functions in my C++ HUD files. I can compile without errors in VS, so my code is good, but no text and no line appear on the scene at runtime. I can’t even switch on the default crosshair to be visible.

I feel the solution is easy, but for a beginner all seems difficult.

Thank you!

I have found the solution! I just restarted UE4 and Visual Studio and the HUD elements appeared. I don’t understand why.