Weird error

So I am working on TileVania from the 2d unity course. Currently on the Set Up Input System video. I am encountering an unusual error: Assets\Scripts\PlayerMovement.cs(23,29): error CS1519: Invalid token ‘;’ in class, record, struct, or interface member declaration.

I followed the videos code as described. I will attach an image of my code as well as the console. Any help with this would be greatly appreciated.

Thanks,
Drakken

You have a function in parentheses instead of ‘curly-braces’

It should be

void OnMove(InputValue value)
{ // <-- curly, not round
    moveInput = value.Get<Vector2>();
    Debug.Log(moveInput);
} // <-- curly, not round

oh my, thank you so much. That would fix it

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms