Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions setup-stage1.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,16 @@ printf -v FFXIV_ENVIRON_FINAL '%s\nexport XIVLAUNCHER_PATH=%q' "$FFXIV_ENVIRON_F
MANAGED_WINE=$(grep 'WineStartupType' $HOME/.xlcore/launcher.ini | sed 's/WineStartupType=\(.*\)/\1/')
if [[ $MANAGED_WINE == *"Managed"* ]]; then
# Find the actual wine version name inside the XLCore directory.
XLCORE_WINE_VERSION=$(ls -1tr $HOME/.xlcore/compatibilitytool/beta | tail -n1)
# This is hard-coded in XLCore, and is vanishingly unlikely to ever change.
PROTON_PATH="$HOME/.xlcore/compatibilitytool/beta/$XLCORE_WINE_VERSION/bin/wine"
# The base path is hard-coded in XLCore but may be different depending on version.
if [[ -d "$HOME/.xlcore/compatibilitytool/wine" ]]; then
# For versions of XLCore since https://github.com/goatcorp/XIVLauncher.Core/commit/877cfd14dd686dacc65aafd01ad38c5de4337ab6
XLCORE_WINE_BASE_DIR="$HOME/.xlcore/compatibilitytool/wine"
else
# For older XLCore versions
XLCORE_WINE_BASE_DIR="$HOME/.xlcore/compatibilitytool/beta"
fi
Comment on lines +140 to +146
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this logic cause issues with installations that were upgraded from an older version? e.g. does XLCore properly remove the old beta folder?

Alternatively, is there a reasonable way to just read the current path from XLCore's config somehow?

Copy link
Author

@travisbartholome travisbartholome Aug 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wiped my old wine prefix at some point while trying to upgrade so I can't fully confirm, but I think it doesn't remove the old wine in beta folder. Reasoning: my original problem was that I updated XIVLauncher AUR package but not ffxiv-tools generated scripts, and then FFXIV was running on a much newer wine version than ACT, so I think the old path was still valid and ACT was trying to run on it.

This is why the logic is looking for the new path first and falling back to the old one, rather than the other way around - so even if the old one is still there, we'll choose the new one. I think it should be safe but lmk if I'm missing a detail there.

Not sure if the path is stored directly in config but I think it's not if you use the default wine managed by xlcore (just says "Managed" in the config file iirc). I can confirm once back home in a couple days.

Copy link
Author

@travisbartholome travisbartholome Aug 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok yeah, confirmed that XLCore's launcher.ini just contains WineStartupType=Managed for this case, and no path info. Also looked around elsewhere and didn't see anything else.

Seems hardcoding the path may still be the only option.

XLCORE_WINE_VERSION=$(ls -1tr $XLCORE_WINE_BASE_DIR | tail -n1)
PROTON_PATH="$XLCORE_WINE_BASE_DIR/$XLCORE_WINE_VERSION/bin/wine"
else
# Customized wine doesn't actually require us to find the version, since the full path is stored in the ini file.
XLCORE_WINE_VERSION="Customized"
Expand Down