I’ve been working struggling with this for a couple hours, and I’m sure it’s something silly I’m missing. I’ll try to keep this short and sweet. The CreateDefaultSubobject for TankAimingComponent int Tank.cpp works fine, and is set up the exact way.
I get an error when compiling Projectile.cpp. When I comment the following line, it compiles fine.
Movement = CreateDefaultSubobject(FName(“Projectile Movement”));
I’ve looked through the docs, and don’t know why these wouldn’t cast right, since they’re both inheriting from UObject. I’ve tried different includes, different casting, even different variable names. I eventually rebuild the project, but the issue remains.
The only thing I can think of is that something has changed in this version of the engine, but even then, the TankAimingComponent is working fine.
Thanks so much for any help you can offer.