BepInEx / BepInEx.ConfigurationManager

Plugin configuration manager for BepInEx
https://www.patreon.com/ManlyMarco
GNU Lesser General Public License v3.0
227 stars 54 forks source link

Keyboard shorcuts do not work #65

Closed JoewAlabel closed 1 year ago

JoewAlabel commented 1 year ago

I am getting the error:

[Error : Unity Log] InvalidOperationException: You are trying to read Input using the UnityEngine.Input class, but you have switched active Input handling to Input System package in Player Settings.

The code:

if (MyHotKey.Value.IsDown())
{
    // action here...
 }

Is not working...

I can not use shortcurts cause an Unity's Player Settings problem. :P

I can manually set the keys with this code:

if (Keyboard.current[Key.LeftAlt].isPressed)
{
    if (Keyboard.current[Key.Digit4].wasPressedThisFrame)
    {
        //Log.LogInfo("Keys Pressed!");
    }
}

But I CAN NOT find a way to allow players set your own keys =(

Can anyone tell me how I make it work with the KeyboardShortcut(KeyCode.Keypad1, KeyCode.LeftAlt)); , please?

Thank you!

ManlyMarco commented 1 year ago

Update BepInEx.

JoewAlabel commented 1 year ago

It is not working with BepInEx6 (BepInEx Bleeding Edge (BE) builds). I am using latest build. But it works with BepInEx5 latest build =(

ManlyMarco commented 1 year ago

Use BepInEx5 latest, v6 is not supported at the moment.

JoewAlabel commented 1 year ago

Use BepInEx5 latest, v6 is not supported at the moment.

Ok. thank you!!!!!