I am assuming that it’s an issue carrying over from Video 3 where the changes in recent versions of UE4 make the code in the videos not work, but I haven’t found a solution for them like I did for part 3.
[Here is the video][1]
[Here is Pickup.cpp][2]
[Here is Pickup.h][3]
[Here is BatteryPickup.cpp][4]
[And here is BatteryPickup.h][5]
And below is an image of the errors I am experiencing
That tutorial series was great back then and I expect you would learn a lot from it too. I don’t think that many issue should occur, outside of this constructor macro if you have to create new classes.
I’d suggest you try to stick with it, post question here in case of trouble and people will be happy to help you.
Yeah, basically GENERATED_BODY is trying to detect if you have declared a constructor. If you don’t, it declares and defines it for you. If you do, then it tries to use it, but expects you to define it also in cpp.
Can you post your BatteryPickup.cpp and BatteryPickup.h after modification, so we can identify the problem?
In this case simply change GENERATE_BODY to GENERATE_UCLASS_BODY in BatteryPickup.h
Since GENERATE_BODY did not exist when they made that tutorial series, you can assume you can change every GENERATE_BODY by GENERATE_UCLASS_BODY and remove every constructor declaration and definition except the one in the cpp file with the Object Initializer