I’m receiving an error when utilizing the code below.
public void OnMouseScroll(InputAction.CallbackContext context)
{
Debug.Log(context.ReadValue<Vector2>());
}
I’m receiving an error when utilizing the code below.
public void OnMouseScroll(InputAction.CallbackContext context)
{
Debug.Log(context.ReadValue<Vector2>());
}
Messages cannot receive InputAction.CallbackContext arguments. Events must be used to receive the full callback context. Messages either need to be without an argument (for buttons) or take an InputValue argument.
Unity should provide a clearer error message for this. I saw quite a few threads asking the same question, and it wastes developer time.
Seconded. Haven’t found a single tutorial that explains this aspect properly