elishacloud / dxwrapper

Fixes compatibility issues with older games running on Windows 10/11 by wrapping DirectX dlls. Also allows loading custom libraries with the file extension .asi into game processes.
zlib License
1.23k stars 90 forks source link

How do I set it up to better support the old Legend of Mir3 , please help me! #241

Closed Leewx820 closed 9 months ago

Leewx820 commented 10 months ago

ScreenShot1 ScreenShot2

I've been playing old Legend of Mir3, but it doesn't work on newer systems, I found dxwrapper and tried it, but it still doesn't work, how do I set it up so I can play the game properly, as far as I know the game uses directdraw.

Leewx820 commented 10 months ago

I can provide the full program.

elishacloud commented 10 months ago

Are the screenshots with or without dxwrapper? What settings are you using for this? Can you send me the log file?

Leewx820 commented 9 months ago

Yes, this is how it runs with dxwrapper, I only turned on the Dd7to9 option, here is a log of the game running with the option turned on, see if that helps you troubleshoot the problem.

3732 15:21:34.088 Starting DxWrapper v1.1.6900.22 3732 15:21:34.088 Running from: C:\Users\Developer\Desktop\Mir3\dxwrapper.dll 3732 15:21:34.088 Reading config file: C:\Users\Developer\Desktop\Mir3\dxwrapper.ini 3732 15:21:34.088 VMware, Inc. None VMware20,1 (Other) 3732 15:21:34.088 Intel Corporation 440BX Desktop Reference Platform None (Other) 3732 15:21:34.088 VMware SVGA 3D 3732 15:21:34.088 Windows 7 Ultimate 64-bit (6.1.7601) Service Pack 1 3732 15:21:34.088 MirGame.exe (PID:3728) 3732 15:21:34.088 Environment variable __COMPAT_LAYER = "" 3732 15:21:34.088 Disabling High DPI Scaling... 3732 15:21:34.088 Loaded library: user32.dll 3732 15:21:34.088 Loading 'ddraw.dll'... 3732 15:21:34.088 Hooking ddraw.dll APIs... 3732 15:21:34.088 Loaded library: d3d9.dll 3732 15:21:34.088 Enabling ddraw wrapper 3732 15:21:34.088 Enabling d3d9 wrapper 3732 15:21:34.088 Loading 'd3d9.dll'... 3732 15:21:34.088 DxWrapper loaded! 3732 15:21:34.134 dd_DirectDrawCreate 3732 15:21:34.134 dd_DirectDrawCreateEx 3732 15:21:34.134 Redirecting 'DirectDrawCreate' IID_IDirectDraw to --> 'Direct3DCreate9' 3732 15:21:34.134 Creating interface m_IDirectDrawX::m_IDirectDrawX (00AE9668) converting interface from v1 to v9 3732 15:21:34.134 d9_Direct3DCreate9 3732 15:21:34.134 Redirecting 'Direct3DCreate9' ... 3732 15:21:34.150 Creating interface m_IDirect3D9Ex::m_IDirect3D9Ex (00ABE020) 3732 15:21:34.150 m_IDirect3D9Ex::LogAdapterNames Adapter: 0 \.\DISPLAY1 VMware SVGA 3D 3732 15:21:34.150 m_IDirectDrawX::CreateSurface2 Primary surface 0x0 dwFlags: 0x1 ddsCaps: 0x200, 0x0, 513 3732 15:21:34.150 Creating interface m_IDirectDrawSurfaceX::m_IDirectDrawSurfaceX (00AF56F0) converting interface from v1 to v9 3732 15:21:34.150 m_IDirectDrawX::~m_IDirectDrawX (00AE9668) deleting interface! 3732 15:21:34.150 m_IDirect3D9Ex::~m_IDirect3D9Ex (00ABE020) deleting interface! 3732 15:21:34.150 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:21:34.150 Redirecting 'DirectDrawCreate' IID_IDirectDraw7 to --> 'Direct3DCreate9' 3732 15:21:34.150 Creating interface m_IDirectDrawX::m_IDirectDrawX (00AE9668) converting interface from v7 to v9 3732 15:21:34.150 Redirecting 'Direct3DCreate9' ... 3732 15:21:34.150 Creating interface m_IDirect3D9Ex::m_IDirect3D9Ex (00AFCEA0) 3732 15:21:34.150 m_IDirectDrawX::~m_IDirectDrawX (00AE9668) deleting interface! 3732 15:21:34.150 m_IDirect3D9Ex::~m_IDirect3D9Ex (00AFCEA0) deleting interface! 3732 15:21:34.150 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:21:34.150 dd_DirectDrawEnumerateExA 3732 15:21:34.150 Redirecting 'Direct3DCreate9' ... 3732 15:21:34.166 Creating interface m_IDirect3D9Ex::m_IDirect3D9Ex (00AFCE40) 3732 15:21:34.166 Redirecting 'DirectDrawCreate' IID_IDirectDraw7 to --> 'Direct3DCreate9' 3732 15:21:34.166 Creating interface m_IDirectDrawX::m_IDirectDrawX (00AEFD28) converting interface from v7 to v9 3732 15:21:34.166 Creating interface m_IDirect3DX::m_IDirect3DX (00AB6120) converting interface from v7 to v9 3732 15:21:34.197 m_IDirect3DX::~m_IDirect3DX (00AB6120) deleting interface! 3732 15:21:34.197 m_IDirectDrawX::~m_IDirectDrawX (00AEFD28) deleting interface! 3732 15:21:34.197 m_IDirect3D9Ex::~m_IDirect3D9Ex (00AFCF60) deleting interface! 3732 15:21:34.197 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:21:34.212 Creating interface m_IDirect3DX::m_IDirect3DX (00AB6120) converting interface from v7 to v9 3732 15:21:34.228 m_IDirect3DX::~m_IDirect3DX (00AB6120) deleting interface! 3732 15:21:34.228 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:21:34.228 m_IDirectDrawX::CreateSurface2 Primary surface 0x0 dwFlags: 0x1 ddsCaps: 0x2200, 0x0, 513 3732 15:21:34.228 Creating interface m_IDirectDrawSurfaceX::m_IDirectDrawSurfaceX (00AFC8D0) converting interface from v7 to v9 3732 15:21:34.228 Creating interface m_IDirectDrawSurfaceX::m_IDirectDrawSurfaceX (00B0EF88) converting interface from v7 to v9 3732 15:21:34.228 Creating interface m_IDirectDrawClipper::m_IDirectDrawClipper (00AB6120) 3732 15:21:34.228 Creating interface m_IDirect3DX::m_IDirect3DX (00AB64E0) converting interface from v7 to v9 3732 15:21:34.228 Creating interface m_IDirect3DDeviceX::m_IDirect3DDeviceX (00AD99E8) converting interface from v7 to v9 3732 15:21:34.228 m_IDirectDrawX::CreateD3D9Device Direct3D9 device! 640x480 refresh: 0 format: D3DFMT_UNKNOWN wnd: WND(00050208,1F3F6RLDKACFM3,{154,154,802,661}) params: {640,480,D3DFMT_UNKNOWN,1,0,0,1,WND(00050208,1F3F6RLDKACFM3,{154,154,802,661}),1,0,D3DFMT_UNKNOWN,0x0,0,0x80000000} flags: 0x44 3732 15:21:34.306 Creating interface m_IDirect3DDevice9Ex::InitDirect3DDevice (00B48A10) 3732 15:21:34.306 Creating interface m_IDirect3DTexture9::m_IDirect3DTexture9 (00AF1DA0) 3732 15:21:34.306 Creating interface m_IDirect3DSurface9::m_IDirect3DSurface9 (00AFCF60) 3732 15:21:34.571 Creating interface m_IDirect3DTexture9::m_IDirect3DTexture9 (00B56020) 3732 15:21:34.571 Creating interface m_IDirect3DSurface9::m_IDirect3DSurface9 (00B5A900) 3732 15:21:34.571 Creating interface m_IDirect3DSurface9::m_IDirect3DSurface9 (00B5A930) 3732 15:21:34.587 Creating interface m_IDirect3DVertexBuffer9::m_IDirect3DVertexBuffer9 (00AF1E00) 3732 15:21:42.481 Creating interface m_IDirect3DTexture9::m_IDirect3DTexture9 (257E4858) 3732 15:21:42.481 Creating interface m_IDirect3DPixelShader9::m_IDirect3DPixelShader9 (257E4888) 3732 15:21:42.481 m_IDirectDrawSurfaceX::~m_IDirectDrawSurfaceX (257E5330) deleting interface! 3732 15:21:42.481 m_IDirectDrawSurfaceX::~m_IDirectDrawSurfaceX (257E5330) deleting interface! 3732 15:21:42.496 m_IDirectDrawSurfaceX::~m_IDirectDrawSurfaceX (257E5330) deleting interface! 3732 15:21:43.565 m_IDirect3DDeviceX::~m_IDirect3DDeviceX (00AD99E8) deleting interface! 3732 15:21:43.565 m_IDirectDrawClipper::~m_IDirectDrawClipper (00AB6120) deleting interface! 3732 15:21:43.565 m_IDirect3DX::~m_IDirect3DX (00AB64E0) deleting interface! 3732 15:21:43.565 m_IDirect3DDevice9Ex::~m_IDirect3DDevice9Ex (00B48A10) deleting interface! 3732 15:21:43.565 m_IDirect3DPixelShader9::~m_IDirect3DPixelShader9 (257E4888) deleting interface! 3732 15:21:43.565 m_IDirect3DSurface9::~m_IDirect3DSurface9 (00AFCF60) deleting interface! 3732 15:21:43.565 m_IDirect3DSurface9::~m_IDirect3DSurface9 (00B5A900) deleting interface! 3732 15:21:43.565 m_IDirect3DSurface9::~m_IDirect3DSurface9 (00B5A930) deleting interface! 3732 15:21:43.565 m_IDirect3DTexture9::~m_IDirect3DTexture9 (257E63E0) deleting interface! 3732 15:21:43.565 m_IDirect3DTexture9::~m_IDirect3DTexture9 (25817480) deleting interface! 3732 15:21:43.565 m_IDirect3DTexture9::~m_IDirect3DTexture9 (00AF1DA0) deleting interface! 3732 15:21:43.565 m_IDirect3DVertexBuffer9::~m_IDirect3DVertexBuffer9 (00AF1E00) deleting interface! 3732 15:21:43.575 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:21:43.575 m_IDirectDrawX::CreateD3D9Device Direct3D9 device! 1920x1080 refresh: 0 format: D3DFMT_UNKNOWN wnd: WND(00050208,1F3F6RLDKACFM3,{99,95,747,602}) params: {1920,1080,D3DFMT_UNKNOWN,1,0,0,1,WND(00050208,1F3F6RLDKACFM3,{99,95,747,602}),1,0,D3DFMT_UNKNOWN,0x0,0,0x80000000} flags: 0x44 3732 15:21:43.625 Creating interface m_IDirect3DDevice9Ex::InitDirect3DDevice (257F3880) 3732 15:21:43.625 m_IDirectDrawX::CreateSurface2 Primary surface 0x0 dwFlags: 0x1 ddsCaps: 0x2200, 0x0, 513 3732 15:21:43.625 Creating interface m_IDirectDrawClipper::m_IDirectDrawClipper (00AB64E0) 3732 15:21:43.625 Creating interface m_IDirect3DDeviceX::m_IDirect3DDeviceX (00AD9D48) converting interface from v7 to v9 3732 15:21:43.625 m_IDirectDrawX::CreateD3D9Device Direct3D9 device! 800x600 refresh: 0 format: D3DFMT_UNKNOWN wnd: WND(00050208,1F3F6RLDKACFM3,{99,95,907,722}) params: {800,600,D3DFMT_UNKNOWN,1,0,0,1,WND(00050208,1F3F6RLDKACFM3,{99,95,907,722}),1,0,D3DFMT_UNKNOWN,0x0,0,0x80000000} flags: 0x44 3732 15:21:45.895 Creating interface m_IDirect3DVertexBuffer9::m_IDirect3DVertexBuffer9 (00AF1C38) 3732 15:21:48.485 Creating interface m_IDirect3DPixelShader9::m_IDirect3DPixelShader9 (00AF1B90) 3732 15:22:04.883 m_IDirect3DDeviceX::~m_IDirect3DDeviceX (00AD9D48) deleting interface! 3732 15:22:04.883 m_IDirectDrawClipper::~m_IDirectDrawClipper (00AB64E0) deleting interface! 3732 15:22:04.893 m_IDirect3DDevice9Ex::~m_IDirect3DDevice9Ex (257F3880) deleting interface! 3732 15:22:04.893 m_IDirect3DPixelShader9::~m_IDirect3DPixelShader9 (00AF1B90) deleting interface! 3732 15:22:04.893 m_IDirect3DVertexBuffer9::~m_IDirect3DVertexBuffer9 (00AF1C38) deleting interface! 3732 15:22:04.893 m_IDirectDrawSurfaceX::CleanupSharedEmulatedMemory Deleting 0 emulated surfaces! 3732 15:22:04.903 Quiting DxWrapper 3732 15:22:04.903 Unloading libraries... 3732 15:22:04.903 DxWrapper terminated!

elishacloud commented 9 months ago

Yes. This is a Direct3D game. The support for Direct3D is still limited. Dd7to9 tries to convert the game to Direct3D9. This issue here has to do with the game trying to modify the backbuffer or the primary surface directly, which is not normally allowed in newer versions of DX. There is a potential fix, but its not too easy and I am afraid it will cause the game to run slow.

One idea, I noticed you are playing this on VMware. If you can try playing this on Windows 7/10/11, non-VMware then you could try using DDrawCompat. But that only works on a non-VM machine.

Leewx820 commented 9 months ago

Yes, I ran the game on VMWare and found the problem, but before that I had tested it on a physical machine and had the same problem as you see above, I have some friends with the same problem as me and I was wondering if there was a follow up arrangement for this kind of problem, thank you for your efforts in this matter.

elishacloud commented 9 months ago

Did you try using DDrawCompat on a physical machine?

Leewx820 commented 9 months ago

Yes, I tried it with DDrawCompat on a physical machine. There is basically no difference between 20 and 21 when they are opened, 31 improves the performance of the game considerably but there are some problems with the windowed image. image

Leewx820 commented 9 months ago

I realized that I was using high dpi, I disabled high dpi and it worked fine. image

elishacloud commented 9 months ago

Very good. How did you disable High DPI? In Windows? In the compatibility settings for this game? Which option did you chose?

I don't have this game so I cannot test it.

Leewx820 commented 9 months ago

I right clicked on the program before and enabled the high DPI option in the properties, I've now turned it off and he's able to work, but it looks a little bit small at 4K resolution, but he's able to work, which is great, thank you very much for your efforts.

elishacloud commented 9 months ago

Your welcome. I am glad you got it working!