[SOLVED] Child C++ Class UStaticMeshComponent not Assigning StaticMesh

Were you able to compile this project with BaseGun.h and BaseGun.cpp as they are? In the header file you commented-out the forward declaration of UStaticMeshComponent. You need to forward declare it. In the cpp file you didn’t include the header file for UStaticMeshComponent, which is

#include "Components/StaticMeshComponent.h"
1 Like