I tried reproducing the error by creating a new project and adding a anim montage reference there but it compiles just fine. I also checked that the dependencies are the same ( “Core”, “CoreUObject”, “Engine”, “InputCore” ) but to no avail.
Then I looked up where the value in question was defined and it is in Engine/Source/Runtime/Engine/Private/AnimationAsset.cpp. Does that mean plugins do not have access to it?
Ok I have re-created the initial setup using the New Plugin function of the editor and everything works find with it, I will now investigate why it doesn’t work in my plugin.
Alright I at least found the cause of the error: RootMotionParams.Accumulate in my custom movement component.
The question now is what do I have to do to make it work again?
A very dirty temporary fix is redefining it in my .cpp with “FVector FRootMotionMovementParams::RootMotionScale(1.0f, 1.0f, 1.0f);” but that only works until I want to make a build because then it complains about double definitions (obviously).
As far as I can tell it is only ever used to reset the root motion scale and is otherwise not used at all. So why is it hidden then?
I also cannot create custom RootMotion sources, because that results in the same error.
This is good to know and hopefully Epic fixes that soon, however it doesn’t help me right now as I have to make it work with the Pre-Build version from the launcher.
You can easily fix this problem by adding ENGINE_API to FRootMotionMovementParams::RootMotion so that it can be linked properly into your game.
static ENGINE_API FVector RootMotionScale;
Seems like the guys at Epic forgot to add that macro. Or maybe they are planning a different solution, but for now this will allow your project to compile.