Try this
in your Hierarchy Click on Gameplay UI or it may be called EMM...... (forgot what it's called)
In the Inspector look at UI Controller and look for "Pause Game and UI Events".
Add these to Pause Game and UI Events
OnPause () drag your player controller into the Runtime box and to the right choose vshootermelleInput Showcursor then tick the box
OnPause () drag your player controller into the Runtime box and to the right choose vshootermelleInput Lockcursor then tick the box
THEN ADD
OnunPause () drag your player controller into the Runtime box and to the right choose vshootermelleInput Showcursor then Do Not tick the box
OnunPause () drag your player controller into the Runtime box and to the right choose vshootermelleInput Lockcursor then Do Not tick the box
It's late but I can clarify tomorrow but this should work.
Pixel Crusher (Dialogue System or Quest Machine) has a really good Invector Intergration and it works with EMM. Quest Machine Input Manager is Way Better an also adds a pause script to it's Invector Chararater Demo Scene. I ended up not needing Quest Machine "$35" but it handles Pause WAY better then what I showed You above.
I have EMM working Perfectly in 2019.3.3 and I spent many nights and tears getting it that way.
I ended up only needing it for Easy's Main Menu and Gameplay UI for Scene Changes, I disabled "unticked" all of Gameplay UI functions except Load Game manager and use
(that eliminated Escape Key Conflicts with EMM and Dialogue Machine or Quest Machine). I wanted the Escape Key and I ended up needing Quest Machine or Dialogue System for another Key conflict. I Will never actually use Dialogue System or Quests but the Invector intergration saved my ass.
Anyway, let me know if You need more help.
Tried Custom scripts but the Pause on and off was problematic. What You see in the video required Easy Main Menu, Pixel Crushers Dialogue Manager and their "Extras" Menu System in the Main Menu Hierarchy and JUST GamePlay UI "with everything disabled except Load Game manager in Every Scene. Change Menu System default Cancel button for Pause to Escape. Easy Main Menu's "Gameplay UI won't know I hit Escape since it no longer controls Pause for me."
I needed pixel Crushers Dialogue System with Invector Integration to get Change Scene Portal working "green box in my video". I comes with EMMScenePortal.cs which handles changing scene and uses Easy Main Menu's Loading Screen between scenes.
Did not need Quest System but if I have any snags with UI and Pause again I will use it, it has a gagillion other Event drag and drop functions I could use for audio, UI's,save load plus it's intended purpose.
The Pros would find an easier way but I can't even code "Hello World".
Made a video of Easy Main Menu and Invector Pixel Crushers integration and their "Extra" Save Menu. I need to Beautify the Save Load Menu then add it to my game.
Youtube Video of my edited Easy Main Menu with Pixel Crushers Invector Demo Scene
R