/Engine/Source/Runtime/Engine/Classes/Components/SkeletalMeshComponent.h
These changes status of animation instance, which is transient data, which means it won't serialize with this component Because of that reason, it is not safe to be used during construction script Please use OverrideAnimationData for construction script. That will override AnimationData to be serialized
void PlayAnimation ( class [UAnimationAsset](API\Runtime\Engine\Animation\UAnimationAsset) * NewAnimToPlay, bool bLooping )