Before I say anything, been using Unity for about a week, so I am still very new with it.
The script “Locomotion” as I am calling it, seems to be spitting back this message, but otherwise seems to have no errors. I am trying to write an animation script for a 1st person Ethan ~ Stealth module.
Console reads 1 Error
Script error: OnAnimatorMove
The message must have 0 or 1 parameters.
The message will be ignored.
The OnAnimatorMove segment…
void OnAnimatorMove (float Horizontal, float Vertical, bool sneak)
{
anim.SetBool(hash.sneakingBool, sneak);
transform.rotation = anim.rootRotation;
if(Horizontal != 0f || Vertical != 0f)
{
anim.SetFloat(hash.speedFloat, 5.5f, speedDampTime, Time.deltaTime);
}
else
anim.SetFloat(hash.speedFloat, 0f);
}
And then the warning
Assets/Scripts/PlayerMovement/Locomotion.cs(12,31): warning CS0414: The private field `Locomotion.animSetup’ is assigned but its value is never used
Deleted the line, and then the script said animSetup was not present. So I can only presume the checker missed it. And cause it is a warning and not an error, I will ignore this part for now.