Open PalmarHealer opened 7 months ago
I coincidentally tried this yesterday with Genshin 4.5 using an-anime-game-launcher on Wayland. After executing Inventory Kamera within the same wine context it was able to find the Genshin process, however, it did not fully work.
Inventory Kamera launches fine, updates the internal lookup database but upon starting a scan, fails to capture the contents of the Genshin window. Only black pixels seem to be captured. Sending the right keystrokes and mouse moves works.
I'm happy to conduct further testing and help where I can to get this working under Linux/Wine :+1:
Here is the log of the scan:
2024-03-31 09:36:41.632|INFO|MainForm|Starting scan
2024-03-31 09:36:41.636|INFO|MainForm|Hotkey registered
2024-03-31 09:36:41.637|INFO|MainForm|Scan settings:
Game Version Data: 4.5
Weapons: True
Artifacts: True
Characters: True
Dev Items: False
Materials: False
Min Weapon Rarity: 4
Min Weapon Level: 1
Equip Weapons: True
Min Artifact Rarity: 4
Min Artifact Level: 0
Equip Artifacts: True
Delay: 0
03d8:fixme:oleacc:LresultFromObject unsupported wParam = ffffffff
03d8:err:ole:marshal_object Failed to create an IRpcStubBuffer from IPSFactory for {e89f726e-c4f4-4c19-bb19-b647d7fa8478} with error 0x80004002
0900:fixme:ver:GetCurrentPackageId (0000000010D9EFC0 0000000000000000): stub
2024-03-31 09:36:41.720|DEBUG|Navigation|Checking for GenshinImpact.exe
0900:fixme:win:NtUserGetWindowPlacement not fully supported on other process window 0x30060.
2024-03-31 09:36:41.733|DEBUG|Navigation|Found GenshinImpact.exe
2024-03-31 09:36:41.733|DEBUG|Navigation|Window location (1920x1080): x=320, y=189
2024-03-31 09:36:41.782|INFO|InventoryKamera|Kamera initialized
2024-03-31 09:36:41.782|INFO|MainForm|Resolution: 1920x1080
2024-03-31 09:36:41.788|INFO|InventoryKamera|Logging directory reset
2024-03-31 09:36:41.803|DEBUG|InventoryKamera|Added 3 workers
2024-03-31 09:36:41.803|DEBUG|InventoryKamera|Thread #42 priority: Normal
2024-03-31 09:36:41.803|DEBUG|InventoryKamera|Thread #43 priority: Normal
2024-03-31 09:36:41.803|DEBUG|InventoryKamera|Thread #44 priority: Normal
2024-03-31 09:36:42.049|DEBUG|GenshinProcesor|8 Engines restarted
Bottom=0, top=52, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:42.101|INFO|GenshinProcesor|Internally set traveler custom name to dt
2024-03-31 09:36:42.104|INFO|InventoryKamera|Scanning weapons...
Bottom=0, top=37, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:45.179|ERROR|UserInterface|Unable to locate Weapons item count.
2024-03-31 09:36:47.180|INFO|InventoryKamera|Done scanning weapons
2024-03-31 09:36:47.180|INFO|InventoryKamera|Scanning artifacts...
Bottom=0, top=37, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:50.233|ERROR|UserInterface|Unable to locate Artifacts item count.
2024-03-31 09:36:52.234|INFO|InventoryKamera|Done scanning artifacts
2024-03-31 09:36:52.235|INFO|InventoryKamera|Scanning characters...
2024-03-31 09:36:52.310|DEBUG|InventoryKamera|Thread 43 exit
2024-03-31 09:36:52.310|DEBUG|InventoryKamera|Thread 44 exit
2024-03-31 09:36:52.310|DEBUG|InventoryKamera|Thread 42 exit
0900:fixme:gdiplus:resample_bitmap_pixel Unimplemented interpolation 7
Bottom=0, top=134, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:56.314|DEBUG|CharacterScraper|Could not parse character name/element (Atempt 1/75). Retrying...
Bottom=0, top=134, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:56.435|DEBUG|CharacterScraper|Could not parse character name/element (Atempt 2/75). Retrying...
Bottom=0, top=134, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-03-31 09:36:56.556|DEBUG|CharacterScraper|Could not parse character name/element (Atempt 3/75). Retrying...
Bottom=0, top=134, base=0, x=0
And here comes some more information... It seems like the Inventory Kamera application only captures black pixels. This is what the GUI looks like after a scan attempt, aborted after the first "Unable to locate Weapons item count." error:
As far as I can tell, the images besides the "Navigation"-Label (top right) should display game data but displays black pixels instead.
This is an excerpt of the log (from scan start to abort on error):
0a08:fixme:oleacc:LresultFromObject unsupported wParam = ffffffff
0a08:err:ole:marshal_object Failed to create an IRpcStubBuffer from IPSFactory for {e89f726e-c4f4-4c19-bb19-b647d7fa8478} with error 0x80004002
2024-04-01 13:29:58.745|INFO|MainForm|Starting scan
2024-04-01 13:29:58.754|INFO|MainForm|Hotkey registered
2024-04-01 13:29:58.754|INFO|MainForm|Scan settings:
Game Version Data: 4.5
Weapons: True
Artifacts: True
Characters: True
Dev Items: False
Materials: False
Min Weapon Rarity: 4
Min Weapon Level: 1
Equip Weapons: True
Min Artifact Rarity: 4
Min Artifact Level: 0
Equip Artifacts: True
Delay: 2
2024-04-01 13:29:58.756|DEBUG|Navigation|Checking for GenshinImpact.exe
0ac4:fixme:win:NtUserGetWindowPlacement not fully supported on other process window 0x30060.
2024-04-01 13:29:58.764|DEBUG|Navigation|Found GenshinImpact.exe
2024-04-01 13:29:58.764|DEBUG|Navigation|Window location (1920x1080): x=320, y=189
2024-04-01 13:29:58.803|INFO|InventoryKamera|Kamera initialized
2024-04-01 13:29:58.803|INFO|MainForm|Resolution: 1920x1080
2024-04-01 13:29:58.805|INFO|InventoryKamera|Logging directory reset
2024-04-01 13:29:58.813|DEBUG|InventoryKamera|Thread #23 priority: Normal
2024-04-01 13:29:58.814|DEBUG|InventoryKamera|Added 2 workers
2024-04-01 13:29:58.814|DEBUG|InventoryKamera|Thread #24 priority: Normal
2024-04-01 13:29:59.051|DEBUG|GenshinProcesor|8 Engines restarted
Bottom=0, top=52, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-04-01 13:29:59.075|INFO|GenshinProcesor|Internally set traveler custom name to dt
2024-04-01 13:29:59.077|INFO|InventoryKamera|Scanning weapons...
Bottom=0, top=37, base=0, x=0
Total count=0
Min=0.00 Really=0
Lower quartile=0.00
Median=0.00, ile(0.5)=0.00
Upper quartile=0.00
Max=0.00 Really=0
Range=1
Mean= 0.00
SD= 0.00
2024-04-01 13:30:08.151|ERROR|UserInterface|Unable to locate Weapons item count.
2024-04-01 13:30:08.894|INFO|MainForm|Hotkey pressed
2024-04-01 13:30:09.067|DEBUG|InventoryKamera|Thread 23 exit
2024-04-01 13:30:09.067|DEBUG|InventoryKamera|Thread 24 exit
2024-04-01 13:30:09.068|INFO|MainForm|Hotkey removed
0a08:fixme:oleacc:LresultFromObject unsupported wParam = ffffffff
0a08:err:ole:marshal_object Failed to create an IRpcStubBuffer from IPSFactory for {e89f726e-c4f4-4c19-bb19-b647d7fa8478} with error 0x80004002
After installing .NET Framework v4.7.2
and Microsoft Visual C++ Redistributable for Visual Studio 2015-2022 (x86 or x64)
I was able to reduce the errors a little. However, still capturing blank screenshots...
I'm absolute no Windows guy nor know anything about Microsoft frameworks, but to me it seems like this seems to be somehow related to the problem:
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {c3fcc19e-a970-11d2-8b5a-00a0c9b7c9c4}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {b196b283-bab4-101a-b69c-00aa00341d07}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {af86e2e0-b12d-4c6a-9c5a-d7aa65101e90}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {ecc8691b-c1db-4dc0-855e-65f6c551af49}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {94ea2b94-e9cc-49e0-c0ff-ee64ca8f5b90}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {00000003-0000-0000-c000-000000000046}
0830:fixme:olepicture:OLEPictureImpl_QueryInterface () : asking for unsupported interface {00000144-0000-0000-c000-000000000046}
I was able to run the application without any issues by placing the directory under Program Files
of the prefix created by AAGL and running both InventoryKamera and Genshin from Wine's file explorer. Note that the scanning only worked in an X11 session in Wayland I also get a black screen
Current Behavior
Link to video: https://files.nauren.de/uploads/Screencast-from-31.03.2024-12:10:24.webm
Expected Behavior
Other (please specify in additional notes)
Reproducing a Behavior
Use Ubuntu 22.04 and Import Genshin as non-steam game and run it (it probably doesn't matter, you also can just run it with wine. But for greater performance I would highly recommend using it). Then try scanning and you'll get the error
Device OS
Linux (please specify the version in additional notes)
Genshin Impact Version
4.5.0
Inventory Kamera Version
1.3.15
Screen resolution, screen mode, and UI scale
1600x900
Additional notes and remarks
I'm running Ubuntu 22.04 with Steam Proton Experimental (as of 2024/03/29).
Evidence
Preflight Checklist