Cannot find action on XInputController error

Hello,
I’m getting the following error on this line of code and can’t figure out why:

GetComponent<PlayerInputManager>().JoinPlayer(-1, -1, "Keyboard&Player");

It says it can not find the controller’s action but I don’t even try to join player by gamepad (A gamepad is in deed connected)

*Edit: I fixed it by switching the PlayerInputManager’s behavior to “Send messages” instead of Unity Events, implemented this method public void OnMove(InputValue value) {} and it now works without any error.

Cannot find action ‘Player/MoveAxis[/XInputControllerWindows/leftStick]’ with ID ‘53ca1077-7ceb-4d51-8d6a-e0a61f293aa2’ in 'PlayerInputActions (UnityEngine.InputSystem.InputActionAsset)
UnityEngine.InputSystem.PlayerInputManager:JoinPlayer(Int32, Int32, String, InputDevice)
LocalMultiplayerManager:SpawnFirstPlayer() (at Assets/_Scripts/Game/LocalMultiplayerManager.cs:17)

*Edit:
The odd thing is that the error says “action 'Cannot find action 'Player/MoveAxis…”. And at this moment Player/MoveAxis was already deleted hours before.

The error about it not finding the action is annoying. However, it should not break things and input should otherwise function normally.

ATM only the inspector for PlayerInput will clean up the list if there are action->event entries in there that have since become obsolete by the respective action having been deleted. We’re currently looking for a better solution here.

1 Like

Thanks for replying.
You are correct, it did not break anything but error messages are very annoying.