I’m new to programing UE C++ and I encountered a mistake that confused me: Why VS Intellisense is underlining the GENERATED_BODY macro in red and telling me “this declaration has no storage class or type specifier”? It seems to be related to the line.
I learned from other answers that this is an IntelliSense error, and UE Living Code can indeed be compiled successfully. So I think I can ignore this error, but the error makes my functions “BeginPlay” and “Tick” in CPP getting wrong: “UObject” has no member.
I’m completely confused.
TLDR: IntelliSense error causes GENERATED_BODY macro error. GENERATED_BODY macro error causes CPP file to recognize its parent AActor as UObject, so my VS2022 cannot recognize function BeginPlay and Tick. I need a solution to the error.


