Search Unity

[Solved] User is disabled when unloading a scene

Discussion in 'Input System' started by RoyorGames, Jan 13, 2021.

  1. RoyorGames

    RoyorGames

    Joined:
    Mar 14, 2017
    Posts:
    25
    Hi,

    I am using the new input system and trying a scriptable object approach to my architecture.
    Each scene is completely separate (goal), and is loading needed info from Scriptable Objects.
    The PlayerSelectionScreen is one scene and it is listening to unregistered device activity. Any activity will register a new input user and a control schema, both of which is activated and stored in a player info SO.
    But when unloading the scene and the loading a new one, then all actions on the user are disabled (when looking with the input debugger). It is also not possible to enable the input again with .Enable().
    I am not disabling it anywhere in my own code (print debugs are not logged).
    If I keep the gameobject, that has the monobehaviour on it, then it works as wanted.

    Does the input system support, saving items to Scriptable Objects and then loading them from them as well?
    Am I missing something else that should be saved as well?

    Best regards Povl