Hey, I’ve recently noticed a problem while working on a uni project.
I’m currently using the new Input System to handle my multiplayer, and this was working without a hitch during preview 3 1.0, but I have recently upgraded to preview 6 (thinking I should stay updated for preview packages).
Since doing that my Player Prefab constantly looses reference to the InputActionAsset in my Asset Folder. Here is what happens once the player is loaded into the scene after reapplying the reference.
I’m not changing it in code or anything, just using the bulk standard Player Input Manager which joins players when Gamepad South or Space is pressed.
When the prefab is not selected and you go into play mode, the asset reference of the prefab’s PlayerInput component goes missing? With 1.0 non-preview?
After a bit more experimenting it seems to be caused when I set the prefab and exit play mode in a different scene than I started in. For example I can hit Play and go through my menus and then stop playing and it will be fine, but when I exit out of Play mode in say, my Level scene then it’ll be classes as Type Mismatch and then become missing and I’ll have to reapply it.
Hi! Sorry to revive an old thread, but I found this problem too.
It happens when I join a second player using PlayerInputManager. After the instatiation of the Player Prefab, the Actions field in the PlayerInput component switched to Type Mismatch (only in my asset, not in the instatiated objects).
Also having this issue. It’s a really hard repro to nail down, but it was definitely a ‘type mismatch’ and then pure loss of the link in the source prefab, leading to a lot of confusion.
It happens when I instantiate 2 players in the scene, each player with diferent control schemes. To be more specific, first I instantiate 1 player in the scene with any of the controls schemes and work perfectly, the problem arrives when a second player join the scene and this player has a different control scheme assigned. At the time the seconds player join the scene, the player input component in the prefab ‘loses’ the input actions asset.
I’m having this problem too. First player joins on keyboard, 2nd on gamepad and after you stop the game, the action has disappeared and has to be dragged over again. is there any fix for this yet?
Same issue here. Every time I join a second player, the Player Input component on the player prefab will clear the Actions field to Type Mismatch, and then after exiting play mode the input action asset will be missing. This is in Unity 2020.3 with 1.0.2 version of Input System. Since this seems to have been around for some time, did anyone happen to find a creative workaround?
Edit Seems to only affect play mode in editor though, so no issue in build.