Genshin Impact on Android VM under Linux working! #9
Comments
Hello I am here now. |
Any ETA on the Bluestacks libraries? ;-; |
Bluestacks libraries aren't needed. The necessary Houdini libraries are already included with Bliss OS. |
i damaged my install by trying
we can definitly improve if we have the bluestack libs because it doesn't crash as much in the download phase |
Should I make the translation layer or should [at]Marc-Pierre-Barbier make it? |
i will work on it if i achieve to make the game run, so feel free to start |
I don’t even have it running yet :( Also, it seems that Genshin Impact uses a timing attack to detect VM, so Windows version is officially hopeless. Only android is possible now... let’s hope it still works |
I can nearly hear my SSD’s happiness as 39GB of virtual SSD is deleted from the system |
im going to try the lastest blissos release to see if it change something |
1.7GB, this may take some time... |
They make so much effort to block Windows VMs now, yet it's still easy to bypass the anti-cheat altogether, which is how others are playing it on Linux via Wine with throwaway accounts. Stupid decisions on the developers part. |
Slightly less crashing but it still did crash a ton of times during the download phase. I wouldn't really consider it much of an improvement (if any). The improvement with Bluestacks is the super easy keyboard mapping. What might be an improvement is distributing updated Bliss OS disk images with Genshin Impact fully pre-installed? |
yea great idea |
Though I am unsure of the legality of such a thing... aka unsure if we can distribute disk images containing Genshin Impact |
i don't want to read the genshin licence ... |
Another thing that might be a problem for using Bluestacks houdini is that it's based on Android 7.1 but Bliss OS is Android 9. There are different versions of Houdini for different Android versions, such as Houdini7_x/y/z.sfs vs 9_x/y/z.sfs |
I'm guessing we're already violating the license by just playing the game in a VM in the first place. |
I mean, I never saw anything in the agreement about a VM :/ . |
It says that we cannot tamper with the anticheat, nothing about not running it in emulators or VMs, it also says that we cannot disable the anticheat, but this is not the primary goal of running it in a vm
… Le 18 févr. 2021 à 13:12, FarLanderCraft ***@***.***> a écrit :
Though I am unsure of the legality of such a thing... aka unsure if we can distribute disk images containing Genshin Impact
i don't want to read the genshin licence ...
I'm guessing we're already violating the license by just playing the game in a VM in the first place.
I mean, I never saw anything in the agreement about a VM :/ .
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
The primary goal is actually to ensure compatibility while they can’t, so this should be legal AND ToS compliant
… Le 18 févr. 2021 à 13:31, pika chu ***@***.***> a écrit :
It says that we cannot tamper with the anticheat, nothing about not running it in emulators or VMs, it also says that we cannot disable the anticheat, but this is not the primary goal of running it in a vm
>> Le 18 févr. 2021 à 13:12, FarLanderCraft ***@***.***> a écrit :
>>
>
> Though I am unsure of the legality of such a thing... aka unsure if we can distribute disk images containing Genshin Impact
>
> i don't want to read the genshin licence ...
>
> I'm guessing we're already violating the license by just playing the game in a VM in the first place.
>
> I mean, I never saw anything in the agreement about a VM :/ .
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
|
If this is a 15FPS on a 1070M, on an i5-5250U iGPU, this will be 1fps :(
This means that playing Genshin on my PC will be impossible :(
Of course, playing on a macbook isn’t exactly the best idea, but syscall user dispatch isnt out yet so no wine, so my only options are still limited
… Le 18 févr. 2021 à 13:31, pika chu ***@***.***> a écrit :
It says that we cannot tamper with the anticheat, nothing about not running it in emulators or VMs, it also says that we cannot disable the anticheat, but this is not the primary goal of running it in a vm
>> Le 18 févr. 2021 à 13:12, FarLanderCraft ***@***.***> a écrit :
>>
>
> Though I am unsure of the legality of such a thing... aka unsure if we can distribute disk images containing Genshin Impact
>
> i don't want to read the genshin licence ...
>
> I'm guessing we're already violating the license by just playing the game in a VM in the first place.
>
> I mean, I never saw anything in the agreement about a VM :/ .
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
|
That's with "low" settings. You could try with "lowest" and turn off AA, but yeah it won't be great and the experience is worse than when it ran in a Windows VM. This game requires higher-end Android smart phones (Snapdragon 845 or better is recommended) since they don't really water it down compared to the PC version and I'm guessing the x64 to Aarch64 translation is eating up a lot of resources. You could create a spare throwaway account and play the game with Wine and the game patcher. It would be a far better experience than what we're doing here, just riskier. If you're using a Macbook with macOS, you can just install Bluestacks 4 64-bit for Mac. It might run better compared to Android x86? Just make sure it's the 64-bit version with 64-bit Android. From what I've read the "syscall user dispatch" wont magically allow anti-cheat kernel drivers to work under Wine. IIRC, it's more for allowing anti-tamper and other forms of DRM like Denuvo to behave better under Wine and Linux. |
im used to 60fps on my ipad... may as well play on it
i think the best idea might be to just play on a mobile device at this point
… Le 18 févr. 2021 à 15:30, XaeroVincent ***@***.***> a écrit :
If this is a 15FPS on a 1070M, on an i5-5250U iGPU, this will be 1fps :( This means that playing Genshin on my PC will be impossible :( Of course, playing on a macbook isn’t exactly the best idea, but syscall user dispatch isnt out yet so no wine, so my only options are still limited
…
Le 18 févr. 2021 à 13:31, pika chu @.> a écrit : It says that we cannot tamper with the anticheat, nothing about not running it in emulators or VMs, it also says that we cannot disable the anticheat, but this is not the primary goal of running it in a vm >> Le 18 févr. 2021 à 13:12, FarLanderCraft @.> a écrit : >> > > Though I am unsure of the legality of such a thing... aka unsure if we can distribute disk images containing Genshin Impact > > i don't want to read the genshin licence ... > > I'm guessing we're already violating the license by just playing the game in a VM in the first place. > > I mean, I never saw anything in the agreement about a VM :/ . > > — > You are receiving this because you are subscribed to this thread. > Reply to this email directly, view it on GitHub, or unsubscribe.
That's with "low" settings. You could try with "lowest" and turn off AA, but yeah it won't be great and the experience is worse than when it ran in a VM.
This game requires higher-end Android smart phones (Snapdragon 845 or better is recommended) since they don't really water it down compared to the PC version.
You could create a spare throwaway account and play the game with Wine and the game patcher. It would be a far better experience than what we're doing here, just riskier.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Are you on macOS or is that just a Mac Linux theme? |
On macOS |
Now it says it's i686. WHAT IS WRONG WITH YOU QEMU |
Have you tried Bluestacks for Mac? https://www.bluestacks.com/download.html Or does the Mac version only support 32-bit Android games? |
Exactly. |
Aaaaand it crashes, blackscreen, MacBook Air early 2015. |
ok so now entire Bluestacks crashes... but QEMU not an option... |
I think I should just go on my Linux box even if it's the samsung 505NP EFI corruption one lol |
nomodeset fixed it, now what? |
adb not working, could someone help me? |
use adb over ip |
me neither, i tried it |
I've managed to get key mapping working with a background scripting hack. I can use a bash script with xdotool that waits for a key input and then moves the mouse cursor to a specific spot in the game and simulates a left click or hold inside the QEMU window. Obviously this requires you to run an X11 session instead of Wayland and doesn't work when the QEMU window is full-screen (but it can be maximized). I so far have managed to get WASD keys mapped and enables the character to move forwards and back on the screen. Other mappings are easy to add. What keys should be used for which particular actions, such as weapon use or switching characters? The biggest problem I'm having is just getting Genshin Impact to run consecutive times to do key map testing. I can get the game to occasionally run but then if I restart my VM, the game will often no longer start and just crash at loading screen. It all seems pretty random and there appears to be no reliable way to get the game to start predictably. |
I am surprised that you got it to boot, mine needs nomodeset.
Also:
Your script uses 8 cores emulated CPU, but I have 4 core CPU.
Falling back to 2 cores emulated CPU
Falling back to 2gb memory, I have 4gb and script wants 8gb
Falling back to -accel hvm instead of kvm (macos)
(...)
Have you considered using `adb shell input swipe x y x y duration` to map the keys? That would be my approach, but I say this just to let you and everyone know.
… Le 19 févr. 2021 à 12:53, XaeroVincent ***@***.***> a écrit :
I've managed to get key mapping working with a background scripting hack.
I can use a bash script with xdotool that waits for a key input and then moves the mouse cursor to a specific spot in the game and simulates a left click or hold inside the QEMU window. Obviously this requires you to run an X11 session instead of Wayland.
I so far have managed to get WASD keys mapped and enables the character to move forwards and back on the screen. Other mappings are easy to add.
What keys should be used for which particular actions, such as weapon use or switching characters?
The biggest problem I'm having is just getting Genshin Impact to run consecutive times to do key map testing. I can get the game to occasionally run but then if I restart my VM, the game will often no longer start and just crash at loading screen. It all seems pretty random and there appears to be no reliable way to get the game to start predictably.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
I put nomodeset on the end of the kernel cmdline
it works!!!
Now, I can’t sideload with adb but I will try to sideload normally
TODO+=find way to run adb over ip with qemu
… Le 19 févr. 2021 à 13:59, FarLanderCraft ***@***.***> a écrit :
It just drops me to a CLI
Wait here for a moment, it takes a bit for the shell to start first-time sometimes.
There is the possibility that the installer failed to do it correctly, do an auto-install.
(I had the same problem first-time.)
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Can someone update me on the progress of the joystick translation layer? |
i can't since my game still doesn't want to boot |
ok so i got mine to boot but the gpu surely isn’t virgil/virtio
… Le 24 févr. 2021 à 04:10, Marc barbier ***@***.***> a écrit :
i can't since my game still doesn't want to boot
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
wait, does nomodeset disable virgil?
… Le 24 févr. 2021 à 04:10, Marc barbier ***@***.***> a écrit :
i can't since my game still doesn't want to boot
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
https://askubuntu.com/questions/207175/what-does-nomodeset-do |
so its basically useless |
@NotKirito virgl renderer is known to have issues on mac. so you can try this or wait for venus to upstream in qemu (venus is a vulkan version of virgl and should hopefully work with moltenVK) In the mean time, you can try vmware-svga as it too has 3d acceleration to some degree. though software rasterizer may be faster than it. performance won't be great regardless until venus gets support gets added. (on linux hosts you can do GPU passthrough) @XaeroVincent you can pass a gpu through (If you go that route do not pass the GTX card, as nouveau graphics only) you can pass through your Igpu I believe or I think that cpu supports intel GVT-g, but ive never tested gvt-g with android before. |
Gvt-G is not meant for this. i tried and the game was running at like 1fps or less The best option we have is https://github.com/DualCoder/vgpu_unlock wich allows you to use the tesla driver and try to use sr-iov to do the equivalent of GVT-G but with a better gpu |
i do have an ETA for a linux box and i am not compiling qemu from source, thats going to take 5 hours
… Le 21 mai 2021 à 05:52, Marc barbier ***@***.***> a écrit :
@NotKirito virgl renderer is known to have issues on mac. so you can try this
https://mail.gnu.org/archive/html/qemu-devel/2021-02/msg04235.html
or wait for venus to upstream in qemu (venus is a vulkan version of virgl and should hopefully work with moltenVK)
In the mean time, you can try vmware-svga as it too has 3d acceleration to some degree. though software rasterizer may be faster than it.
performance won't be great regardless until venus gets support gets added. (on linux hosts you can do GPU passthrough)
@XaeroVincent you can pass a gpu through (If you go that route do not pass the GTX card, as nouveau graphics only)
you can pass through your Igpu I believe or I think that cpu supports intel GVT-g, but ive never tested gvt-g with android before.
Gvt-G is not meant for this. i tried and the game was running at like 1fps or less
if you want good DESKTOP performance or video decode perofrmance it can do the trick but the 256 MB vram was a deal breaker, depending on your system you might be able to go up to 2GB of ram but it don't expect it to perform well
The best option we have is https://github.com/DualCoder/vgpu_unlock wich allows you to use the tesla driver and try to use sr-iov to do the equivalent of GVT-G but with a better gpu
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Okay, meanwhile, if you still want to try i did some more digging, here is a homebrew version
GVT-g preformed fine for me doing basic games, I wouldn't expect much but it should be much higher, If you are limited to that ram though, I wouldn't expect much
I don't think it would be all that much better as androidx86 is limited to nouveau drivers. Kinda sucks but oh well, I guess we are in a hurry up and wait situation. while venus won't directly benefit, if zink + venus gets implemented on android x86 it should preform significantly better. ill bring it up on the android-generic telegram |
Hi, I have some news regarding playing the android version of GI. They are neither good nor bad, but news nonetheless. Since I had some time, I searched again for options and found redroid, a project to run android with GPU acceleration and arm translation on docker. The documentation was a bit lacking, but with some help from the devs (thx devs, if you ever see this) I managed to get an android instance with GPU and arm translation "working". The app installs and runs successfully (at least the launcher part). Then I had to download the actual game, which I had to painfully do so at 300-500kb/s (probably due to the arm translation since on my phone it's at least 10 times faster). The launcher still froze at least 20 times while downloading, and since I wasn't sure if it was still downloading, I restarted the app. I had to restart the entire container a few times, and it crashed my computer twice when it spawned the dump_crash32 processes (for some reason, it spawned like 30 at the same time). About two or three hours ago, I finally managed to finish downloading it. Finally, it was time to test it. However, I realized just how slow the ndk_translation libraries are when it literally took between 40 minutes and an hour just to verify its files. Thankfully it loaded a bit faster at about 10 to 15 mins. Then the game ran until when it should finally render the world. At this point it just left me with a black screen, and some time later it popped a message with "Connection lost. Retry?" or similar, and if I try to relog it just sends me back to the "start game" screen. The same happens every time. I should note that the redroid project is in its early stages and there are some (rather important) parts that are not yet implemented, like the entire audio hardware abstraction layer... (yes, there is no audio). Or that the input (keyboard, mouse) events are cloned to android (double mouse cursor and blindly pressing keys on android if you're using it on linux while not looking at the android screen...). Still, I think it's an interesting experiment and wanted to share my results. If anyone has any suggestion, please share it and I'll try it when possible. |
Glad to see that redroid is a thing and that it works. What if you root it, `pip install speedtest-cli`, then you run `speedtest` in the terminal? (just to see the network performance)
… On Jun 8, 2021, at 3:04 PM, MrAzteca ***@***.***> wrote:
). The launcher still froze at least 20 times while downloading, and since I wasn't sure if it was still downloading, I restarted the app. I had to restart the entire container a few times, and it crashed my computer twice when it spawned the dump_crash32 processes (for some reason, it spawned like 30 at the same time).
About two or three hours ago, I finally managed to finish downloading it. Finally, it was time to test it. However, I realized just how slow the ndk_translation libraries are when it literally took between 40 minutes and an hour just to verify its files. Thankfully it loaded a bit faster at about 10 to 15 mins.
Then the game ran until when it should finally render the world. At this point it just left me with a black screen, and some time later it popped a message with "Connection lost. Retry?" or similar, and if I try to relog it just sends me back to the "start game" screen. The same happens every time.
I should note that the redroid project is in its early stages and there are some (rather important) parts that are not yet implemented, like the entire audio hardware abstraction layer... (yes, there is no audio). Or that the input (keyboard, mouse) events are cloned to android (double mouse cursor and blindly pressing keys on android if you're using it on linux while not looking at the android screen...). Still, I think it's an interesting experiment and wanted to share my results.
If anyone has any suggestion, please share it and I'll try it when possible.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#9 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ARQIDCINWXGRZTKHHEV55JTTRZSSXANCNFSM4X2TIJ7Q>.
|
What I wanted suggestions on was the black screen and loading times. The speed should be the same for my phone and my computer since they are connected to the same place, one by wifi and the other by cable, so that's most likely not the issue. I could try the speed test but imho it's probably pointless. Besides, trying to get pip on an android shell is not worth anyone's time, and the browser will probably run the x86_64 version instead of the arm one, so that issue should not be present. I think that the fact that on my phone is at least 10 times faster than with ndk_translation proves it's most likely ndk_translation's fault. If you're still curious about the speed, point me to a speed testing app that uses native libraries and has no x86 version, and I'll test it for you (but it'll probably work a lot better since the game probably does some processing in realtime, like data decompression or something). |
Maybe the black screen is caused by genshin not being able to render anything fast enough + network not being fast enough to ping genshin servers? Try wiresharking too? |
I completely had a braindead moment, has anyone tried using android emulator with cuttlefish? it could be much more performant than virgl. and I tried it a long time ago now with older apps, and had decent performance with it. you can enable it in the official android emulator via the command at the bottom. I cannot test it, but if someone is willing to, it could be an avenue forward. Not to mention a lot of time will be needed before virgl gets remotely acceptable performance. due the the architecture of virgl (It translates Guest calls into Gallium3D calls, transports them back to host, and converts gallium calls into opengl calls, so its not very efficient at the moment,) and Venus will be vulkan only for a short bit, until the either gallium3D calls get translated to vulkan under virgl renderer, or someone implements zink into android to use Venus. In either case the same thing is more or less happening which is opengl -> gallium3d -> vulkan, its just a matter of how (or rather when) it is implemented. but in any case, I wouldn't assume it a to be something that would happen soon So GFXstream, or Cuttlefish is probably the best short term solution.
EDIT: I should note, cuttlefish is not really android emulator, but the specifics are here |
I got the game to work under Bliss OS 11.12 with QEMU & Virgil virtual GPU.
I've set the VM to 4 CPU cores and 8GB of RAM.
Download the game from APKPure and download an XAPK Installer app to install it in XAPK form. The game will crash numerous times during the download. Just keep trying. Press the Windows key on the keyboard once the game starts downloading from the 3D menu then open System Monitor to look at the network download traffic. The game may crash but continue to download it's 9GB of data. Try redoing the steps again if the network traffic and CPU usage falls to near zero. Eventually the game will download and once the game is downloaded, it doesn't appear to crash anymore (so far).
Keyboard mapping isn't working (Octopus doesn't seem to launch the game), however the game thankfully responds to mouse input!!
You can move your character around by moving the mouse cursor towards the bottom left hand corner of the screen (but not all the way to the end) and hold the left mouse button. Your character will move when you move your mouse while holding the left button down. Other actions can be done by clicking their respective buttons.
The framerate isn't great (maybe 10 to 15 FPS) but MUCH better compared to the nested virtualization under a Windows VM + Bluestacks that I had working prior. I have the graphics settings set at "Low". This level of performance is with a Core i7 6700HQ, 32GB RAM, and a GTX 1070 Mobile. A better computer will obviously yield better performance results.
The text was updated successfully, but these errors were encountered: