Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Guide] Running on Proton with steam Guild Wars 2 #144

Open
fmazur opened this issue Jun 28, 2023 · 19 comments
Open

[Guide] Running on Proton with steam Guild Wars 2 #144

fmazur opened this issue Jun 28, 2023 · 19 comments
Labels
documentation Improvements or additions to documentation

Comments

@fmazur
Copy link

fmazur commented Jun 28, 2023

  1. Install Guild Wars 2 on steam. If using non-steam account add %command% -provider Portal.
  2. Launch a game, close it and locate a proton prefix. Should be in:
    echo /home/$(whoami)/.local/share/Steam/steamapps/compatdata/1284210/pfx
  3. Download Burrito and extract anywhere suitable
  4. Create run_burrito_link.sh file. Make it executable. It's contents should be something like this below (didn't test whether everything there is required):
    But definitely essential are WINEARCH, WINE, WINEPREFIX and command at the end, rest are things generated by Lutris
    I'm using ge-proton but can replace with existing proton 8 that's included in steam but make sure to update to correct paths.

Edit "/home/$USER/Executables/Burrito_Linux/burrito_link.exe" to point to burrito_link.exe

#!/bin/bash

USER=$(whoami)
PROTON="GE-Proton7-55"
PROTON_PATH="/home/$USER/.local/share/Steam/compatibilitytools.d/$PROTON/files/bin/wine"
GUILD_WARS_PATH="/home/$USER/.local/share/Steam/steamapps/common/Guild Wars 2"
GUILD_WARS_PREFIX_PATH="/home/$USER/.local/share/Steam/steamapps/compatdata/1284210/pfx"
# Environment variables
export DISABLE_LAYER_AMD_SWITCHABLE_GRAPHICS_1="1"
export __GL_SHADER_DISK_CACHE="1"
export __GL_SHADER_DISK_CACHE_PATH=$GUILD_WARS_PATH
export WINEDEBUG="-all"
export DXVK_LOG_LEVEL="none"
export WINEARCH="win64"
export WINE=$PROTON_PATH
export WINEPREFIX=$GUILD_WARS_PREFIX_PATH
export WINEESYNC="1"
export WINEFSYNC="1"
export DXVK_NVAPIHACK="0"
export DXVK_ENABLE_NVAPI="1"
export WINEDLLOVERRIDES="winemenubuilder="
export WINE_LARGE_ADDRESS_AWARE="1"
export TERM="xterm"

# Command
gamemoderun $PROTON_PATH "/home/$USER/Executables/Burrito_Linux/burrito_link.exe"
  1. Start Guild Wars 2
  2. Run compositor(if not already running) to allow overlay transparency. I'm using empty config picom.
  3. Run run_burrito_link.sh and move window over Guild Wars 2 if it doesn't get attached on multi monitor setup.
  4. Load parsed markers from .json file. I'm using i3wm therefore Guild Wars 2 window gets tiled and its in windowed mode, Burrito window is set to floating and automatically resizes to Guild Wars 2 window resolution. In case of Guild Wars 2 window freezing adjust i3wm gap ±1-3px

Hope this helps someone.

@AsherGlick AsherGlick added the documentation Improvements or additions to documentation label Jun 29, 2023
@AsherGlick
Copy link
Owner

This is a great guide. Nice work figuring out what environment variables need to be set for the burrito link exe to work with proton. One day we will have a better, more discoverable, place to put this.

@fmazur
Copy link
Author

fmazur commented Jun 29, 2023

I've seen people writing scripts for this but they "run" or attach when you start Guild Wars 2 which adds additional steps if you want to just run Guild Wars 2 without the overlay.
In the way I've made it start is standalone which can be run at any point during the game. I'll figure out minimal config next time I use Burrito and update the code snippet above. Reduced number of envs.
Also on tiling window managers like i3wm it's possible to directly tell window to spawn at specific place in a specific mode(floating in this case) so the moving the window part could be skipped.

@rogeriofrsouza
Copy link

Hey, your guide was really helpful, I was able to run it all here but I can't adjust the overlay properly.
Seems like Burrito is getting the main window focus and I can't control Guild Wars 2, keyboard keys won't work.
Do you have any suggestion for my case?
I'm using Manjaro Gnome, playing on Steam, Proton 8.0, probably mutter compositor and Wayland window manager.

@fmazur
Copy link
Author

fmazur commented Jul 6, 2023

Hey, your guide was really helpful, I was able to run it all here but I can't adjust the overlay properly. Seems like Burrito is getting the main window focus and I can't control Guild Wars 2, keyboard keys won't work. Do you have any suggestion for my case? I'm using Manjaro Gnome, playing on Steam, Proton 8.0, probably mutter compositor and Wayland window manager.

When Burrito takes focus then you'll have to find a way to disable that focus in your compositor. Probably similar to what's here: https://gist.github.com/dlamkins/df0bbc656cf38edc5af779d331dd295c
It's the same issue with Blish on PC where it steals focus and doesn't pass keyboard input through.

@jabuxas
Copy link

jabuxas commented Jul 30, 2023

I'm having this issue when I run the script

Application could not be started, or no application associated with the specified file.
ShellExecuteEx failed: File not found.

@fmazur
Copy link
Author

fmazur commented Aug 13, 2023

I'm having this issue when I run the script

Application could not be started, or no application associated with the specified file.
ShellExecuteEx failed: File not found.

Look into paths that are being used.
Most likely this is the path "/home/$USER/Executables/Burrito_Linux/burrito_link.exe" that fails. Note that Executables is custom folder path that I use which most likely doesn't exist for others.

@nlfog
Copy link

nlfog commented Oct 11, 2023

I'm trying to figure out if there is an extra step I'm missing here. I have followed the instructions, and I have my terminal window open running the "run_burrito_link.sh", and it looks like that's working as it's providing me json output of my character in game, but I don't see any "window" or overlay. There's nothing in my task bar, nothing open anywhere else. How do I go about getting the overlay side of it and loading markers?

@fmazur
Copy link
Author

fmazur commented Oct 11, 2023

I'm trying to figure out if there is an extra step I'm missing here. I have followed the instructions, and I have my terminal window open running the "run_burrito_link.sh", and it looks like that's working as it's providing me json output of my character in game, but I don't see any "window" or overlay. There's nothing in my task bar, nothing open anywhere else. How do I go about getting the overlay side of it and loading markers?

That guide is to setup burrito_link as steps are different from when you launch with Lutris.
You still need to run burrito executable "burrito.x86_64". For example ./burrito.x86_64 (needs execute permissions)
The "burrito.x86_64" is the actual overlay whereas burrito_link is the connection between Guild Wars 2 and burrito overlay.

@nlfog
Copy link

nlfog commented Oct 11, 2023

I'm trying to figure out if there is an extra step I'm missing here. I have followed the instructions, and I have my terminal window open running the "run_burrito_link.sh", and it looks like that's working as it's providing me json output of my character in game, but I don't see any "window" or overlay. There's nothing in my task bar, nothing open anywhere else. How do I go about getting the overlay side of it and loading markers?

That guide is to setup burrito_link as steps are different from when you launch with Lutris. You still need to run burrito executable "burrito.x86_64". For example ./burrito.x86_64 (needs execute permissions) The "burrito.x86_64" is the actual overlay whereas burrito_link is the connection between Guild Wars 2 and burrito overlay.

Okay, makes sense. I did try that after, and it looks like it launches and says "accepted peer: 127.0.0.1:52619", and I see the little burrito on my left display (I play GW2 on my right), but click it does nothing, I dragged it over to my right display (Where I play GW2), and nothing. No output in the terminal window other than:

[fog@sorrento burrito]$ ./burrito.x86_64
Godot Engine v3.3.2.stable.official - https://godotengine.org
OpenGL ES 3.0 Renderer: AMD Radeon RX 6600 XT (navi23, LLVM 16.0.6, DRM 3.54, 6.5.6-zen2-1-zen)
OpenGL ES Batching: ON

accepted peer: 127.0.0.1:52619
Setting transient for
Successfully set transient property!

EDIT: Okay, I tried it a few more times, and I finally got a Main Menu pop up, but clicking any of the buttons freezes it altogether and the only thing I can do is Ctrl+C in the terminal. I tried -d on the command line, but there was no difference in output.

@fmazur
Copy link
Author

fmazur commented Oct 11, 2023

Never encountered overlay freeze issue. Maybe @AsherGlick knows why that happens.

@AsherGlick
Copy link
Owner

@nlfog I have not encountered a freeze like the one you describe. However the major problem of, and major benefit of, linux is the flexibility of choice. It is possible that whatever renderer, window manager, etc is not playing nice with burrito doing the kinda-weird things an overlay does. Once work is completed on #56 (closer than ever) my next priority is #102 which will begin to help us solve these platform specific issues.

In the meantime go ahead an open up a new issue with your problem and include the output to inxi -Gxxx and wmctrl -m in the issue so we can sort that issue into the correct test bucket when we begin sorting them.

@nlfog
Copy link

nlfog commented Oct 13, 2023

@nlfog I have not encountered a freeze like the one you describe. However the major problem of, and major benefit of, linux is the flexibility of choice. It is possible that whatever renderer, window manager, etc is not playing nice with burrito doing the kinda-weird things an overlay does. Once work is completed on #56 (closer than ever) my next priority is #102 which will begin to help us solve these platform specific issues.

In the meantime go ahead an open up a new issue with your problem and include the output to inxi -Gxxx and wmctrl -m in the issue so we can sort that issue into the correct test bucket when we begin sorting them.

I'll do that over the next few days. I'll also do some more thorough troubleshooting as well and try different configurations. I'm currently running latest Plasma desktop on arch with Wayland, but can try some other setups as well.

@AsherGlick
Copy link
Owner

Wayland or xwayland might be the problem, lots of folks have reported issues with it. I can't currently test or support it specifically because my machine still runs X11. But once #102 unblocks cross platform testing we will be able to investigate it better.

@Rojikku
Copy link

Rojikku commented Mar 1, 2024

I'm using i3wm therefore Guild Wars 2 window gets tiled and its in windowed mode, Burrito window is set to floating and automatically resizes to Guild Wars 2 window resolution. In case of Guild Wars 2 window freezing adjust i3wm gap ±1-3px

@fmazur
I would greatly appreciate you expanding upon how you did this because I would like to replicate it, also in i3wm.

@fmazur
Copy link
Author

fmazur commented Mar 1, 2024

@fmazur I would greatly appreciate you expanding upon how you did this because I would like to replicate it, also in i3wm.

I'll be able to write up more detailed guide on this specific thing with screenshots in 1-2 days.

@Rojikku
Copy link

Rojikku commented Mar 1, 2024

@fmazur I would greatly appreciate you expanding upon how you did this because I would like to replicate it, also in i3wm.

I'll be able to write up more detailed guide on this specific thing with screenshots in 1-2 days.

TBH i3config snippets would work in the meanwhile, if you have it available.

for_window [class="Burrito"] floating enable
assign [class="Burrito"] 2

I have this so far, 2 being where I always run steam and gw2.
But uh...It's very easy for me to lose burrito since it's transparent. For example, I JUST realized it's on workspace 1 for unknown reasons over this very window after looking around for it.

I am temporarily able to just...move it to workspace 2 and get it to work.
I am mystified as to why it goes to 1 despite that config clearly saying 2. Nothing assigns to 1. Nothing.

@fmazur
Copy link
Author

fmazur commented Mar 1, 2024

I don't have it available right now but it'd be easier for you to not have those rules for burrito. Launch gw2 in windowed mode and ensure it's not in floating mode (should be tiled by default) the launch on different workspace burrito eg with command line. Move it to workspace where gw2 is. At this point the gw2 window and burrito window will share tiling space so they'll be gw2 on the left and burrito on the right. Hover over right side and toggle floating for burrito . Burrito window should snap to gw2 window. Keep in mind that burrito can still be moved with mod+drag.

I'm not using it that often to have it auto run and assign itself but probably you can accomplish that with i3-msg in bash script after burrito finishes launching

@fmazur
Copy link
Author

fmazur commented Mar 2, 2024

@Rojikku
Here is expanded version of what I've described in the initial post that works on my i3wm:
(screenshots are for one of the monitors but only one is relevant for this guide)

  1. Launch Guild Wars 2
    1709407031

  2. Run compositor(unless already running)

  3. Run burrito link ./run_burrito_link.sh

  4. Run ./burrito.x86_64
    (2/3/4 steps on screenshot)
    1709407066

  5. Move burrito window to workspace with Guild Wars 2
    1709407076

  6. bindsym $mod+Shift+space floating toggle on Burrito window

  7. Load marker file
    (6/7)
    1709407101

  8. Play Gw2 normally

I could use dll way but I'm only using burrito for map exploration which is not that often so this is more than enough for me to use it just fine.

@Rojikku
Copy link

Rojikku commented Mar 2, 2024

@fmazur Thank you.
My assumption is that the burrito window goes full left if you start it in floating mode, meaning X/Y:0 or something. If I click the burrito icon on my far left monitor, it gives the red border, and I can use hotkeys to relocate it to the second workspace. It'll automatically be pixel-perfect and covering GW2 from there. I play in windowed fullscreen though.
I run picom anyway, so that's already running. I used the DLL method. Might use arcdps method when that comes back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

6 participants