Hi everyone,
I’m building a MTG arena snap.
The snap downloads the game and installs it and is built upon the template https://github.com/snapcrafters/wine-sommelier
It seems that some computers have issues with the snap and some don’t and i cant pinpoint the issue.
I’m thinking maybe it could be Nvidia related but I’m not sure
on Ubuntu 19.10 i get the following error
Mono path[0] = 'C:/Program Files (x86)/Wizards of the Coast/MTGA/MTGA_Data/Managed' Mono config path = 'C:/Program Files (x86)/Wizards of the Coast/MTGA/MonoBleedingEdge/etc' libGL error: No matching fbConfigs or visuals found libGL error: failed to load driver: swrast X Error: GLXBadContext Request Major code 151 (GLX) Request Minor code 6 () Error Serial #197 Current Serial #196
please try the snap for yourself and report back sudo snap install mtg-arena --edge
It takes a long time to install and it seems to be stuck on 0% but dont worry its doing its thing just give it time.
The snap works well on my end. I can install the snap, wait patiently for it to get setup, and then launch the game. It runs well on my integrated Intel GPU.
One thing doesn’t work: I have a discrete Nvidia GPU, currently configured to take advantage of the Nvidia On Demand support in the latest kernels. To run a game on my Nvidia card, I need to set some environment variables, including __NVIDIA_PRIME_RENDER_OFFLOAD=1 and __GLX_VENDOR_LIBRARY_NAME=“nvidia”. Those environment variables doesn’t seem to get passed on to the snap, so I’m stuck running this version of Arena on my Intel card.
Nice work, there went 3 hours of my life last night (only ever played with physical cards before).
I would recommend not using pulseaudio andinstead change that to audio-playback to get audio out of the box. If the game supports conversation you can potentially hook up audio-record which would require manual connection.
About the NVIDIA setup, this might be a nice task for snap set, something like snap set mtg-arena nvidia.enable-on-demand=true (I didn’t give the setting that much thought) and have a configure hook that acts upon that and writes out something (maybe to $SNAP_DATA) that can be sourced a command-chain to export those variables.
I submitted two quick PRs fixing missed spots when adapting from the template. That should allow to start the application with mtg-arena (instead of mtg-arena.super-snap), if I understand correctly.
You should check out Wizard’s Fan Content Policy. I’m fairly certain re-wrapping the client (without changing it) is okay according to that license (NAL!) but you will want to
replace the logo image with something not in violation with the license (or obtain permission) and
include the necessary license note in both the README and Snap description.
Unfortunately, in my case the app still doesn’t start; it seems the Nvidia driver is not found at all? Some advice can be found online but I have no idea how to (efficiently) act on it in the context of Wine inside a snap.