need help updating older UE4 code

im trying to follow this tutorial, but it isn’t working. im useless with C++ in unreal so was hoping to get this solved to move onto the blueprints. This is the tutorial
The first two sections dont work, assuming because something is outdated.

Can you post the errors you’re seeing from the compiler? Or are you saying it doesn’t do what it says?