UEAsLibrary mouse input not working as app is never active

Hello,

I am currently developing an app that needs to be embedded in another Windows and I have resorted to using UEAsLibrary.

Everything is working fine in both Win32 and Qt app but we found out that mouse input does not work at all.

By reading the code I found that mouse input is not handled if bAppIsActive is set to false.

The problem is that in the case of UEAsLibrary is always false and by the comment on the source code it seems that it should be like that.

// If we are embedded inside another app then we never need to be "active" bAppIsActive = !GUELibraryOverrideSettings.bIsEmbedded;

Is this correct or is it something I miss?

By commenting the incrimitated line everything is working

4 Likes

helow,I have a problem,int UELibrary_Init(HINSTANCE hInst, HWND hWnd, const char* CmdLine)
i do not know how to send const char* CmdLine , i send nothing error like this ,can you teach me CmdLine how to send .

微信图片_20220322090549

my project name is UELibrary …

Did you copy your project data (and the uproject) inside the output folder of your porject?

this is other applications , i build ue as a dll file , but i dont know how to use api UELibrary_Init open the ue project , can you give me a demo?

i tell you what i do:
1. build ue as lib
2.copy the dll file to my another c++ application
3.user LoadLibrary to call UELibrary_InitA
4.build my c++ application
5.run and show me error:
微信图片_20220322090549

this is my code ships :

The steps that are required:

  1. build your project using what described in the docs.
  2. export and cook the content.
  3. Copy your project dll where needed
  4. Copy your cooked content (both YourProject and Engine directory) two levels up in the directory tree from where you put your exe/dll
  5. Everything should work now.

I think you are missing your project content (step 4).

thanks,i feel better,another thing: “ const char* CmdLine ” , what CmdLine look like,can you give me an example,thanks plus

i followed your steps , it looks like work ,but it nothing show in my window , can you help me again,thanks plus!!!

i have a new problem like photo, but i swear in my project directory “WindowsNoEditor” exist and contain a DefaultEngine.ini. do you have any idea ?

hello ,UE Documentation say Unreal Engine as a Library can spawn their own UE4 instances ,but i
dont know how to send cmdline to spawn a ue instances .

I Have the same problem,do you solve this problem,could you help me ,thanks