Compare commits
8 Commits
0d9ee584e5
...
9696b33f34
Author | SHA1 | Date | |
---|---|---|---|
|
9696b33f34 | ||
|
723596bb16 | ||
|
c26ca666c5 | ||
|
fc7346c681 | ||
|
5eb82457b8 | ||
|
8c60222c27 | ||
|
fc565a2de8 | ||
|
f7c9fee8c1 |
@ -2,6 +2,9 @@ You can help us in the development of the project on the website: https://linux-
|
||||
----------------------------------------
|
||||
Changelog:
|
||||
|
||||
###Scripts version 2383### / Date: 22.12.2024 / Download update size: 4 megabytes
|
||||
* added automatic creation of shortcuts for games from Epic Games Launcher (thanks alex2844)
|
||||
|
||||
###Scripts version 2382### / Date: 22.12.2024 / Download update size: 270 megabytes
|
||||
* updated PROTON_LG to version "9-21"
|
||||
* updated versions:
|
||||
|
@ -2,6 +2,9 @@
|
||||
-----------------------------------------
|
||||
История изменений:
|
||||
|
||||
###Scripts version 2383### / Дата: 22.12.2024 / Размер скачиваемого обновления: 4 мегабайта
|
||||
* добавлено автоматическое создание ярлыков для игр из Epic Games Launcher (спасибо alex2844)
|
||||
|
||||
###Scripts version 2382### / Дата: 22.12.2024 / Размер скачиваемого обновления: 270 мегабайт
|
||||
* обновлен PROTON_LG до версии "9-21"
|
||||
* обновлены версии:
|
||||
|
@ -1890,8 +1890,7 @@ export -f wait_wineserver
|
||||
|
||||
kill_portwine () {
|
||||
if [[ "${PW_WINE_USE}" != "USE_SYSTEM_WINE" ]] ; then
|
||||
check_flatpak
|
||||
if [[ "$ALPINE_FP" == "1" ]] ; then
|
||||
if check_flatpak && [[ "$ALPINE_FP" == "1" ]] ; then
|
||||
wine_pids=$(ls -l /proc/*/exe >/dev/null 2>&1 | grep -ie PortProton | grep -E 'wine(64)?-preloader|wineserver' | awk -F/ '{print $3}')
|
||||
bwrap_pids=$(pgrep -f wrap | grep PortProton | head -n 1)
|
||||
else
|
||||
@ -1908,7 +1907,6 @@ kill_portwine () {
|
||||
kill -n 9 "${pw_kill_pids}" &>/dev/null
|
||||
fi
|
||||
done
|
||||
|
||||
return 0
|
||||
}
|
||||
export -f kill_portwine
|
||||
@ -2799,45 +2797,45 @@ pw_skip_get_info () {
|
||||
GET_AMD_VULKAN_DRIVER_LIST="amdvlk amdgpupro radv"
|
||||
unset AMD_VULKAN_DRIVER_LIST
|
||||
|
||||
for DRIVER in $GET_AMD_VULKAN_DRIVER_LIST; do
|
||||
case "$DRIVER" in
|
||||
"amdvlk")
|
||||
for file in /opt/amdgpu/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/usr/share/vulkan/icd.d/amd_icd*.json ; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="amdvlk"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
"amdgpupro")
|
||||
for file in /opt/amdgpu-pro/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/usr/share/vulkan/icd.d/amd_pro_icd*.json; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="!amdgpupro"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
"radv")
|
||||
for file in /usr/share/vulkan/icd.d/radeon_icd.*.json ; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="!radv"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
esac
|
||||
done
|
||||
export AMD_VULKAN_DRIVER_LIST
|
||||
|
||||
if [[ -z "$AMD_VULKAN_DRIVER_LIST" ]] || check_flatpak ; then
|
||||
AMD_VULKAN_CB=":DCB"
|
||||
if ! check_flatpak \
|
||||
&& [[ $(check_vendor_gpu) =~ amd ]]
|
||||
then
|
||||
for DRIVER in $GET_AMD_VULKAN_DRIVER_LIST; do
|
||||
case "$DRIVER" in
|
||||
"amdvlk")
|
||||
for file in /opt/amdgpu/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/usr/share/vulkan/icd.d/amd_icd*.json ; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="amdvlk"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
"amdgpupro")
|
||||
for file in /opt/amdgpu-pro/etc/vulkan/icd.d/amd_icd*.json \
|
||||
/usr/share/vulkan/icd.d/amd_pro_icd*.json; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="!amdgpupro"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
"radv")
|
||||
for file in /usr/share/vulkan/icd.d/radeon_icd.*.json ; do
|
||||
if [ -f "$file" ]; then
|
||||
AMD_VULKAN_DRIVER_LIST+="!radv"
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
esac
|
||||
done
|
||||
export AMD_VULKAN_DRIVER_LIST
|
||||
export AMD_VULKAN_CB=":CB"
|
||||
else
|
||||
AMD_VULKAN_CB=":CB"
|
||||
export AMD_VULKAN_CB=":DCB"
|
||||
fi
|
||||
export AMD_VULKAN_CB
|
||||
|
||||
logical_cores=$(grep -c ^"processor" /proc/cpuinfo)
|
||||
if [[ "${logical_cores}" -le "4" ]] ; then
|
||||
@ -4377,24 +4375,34 @@ portwine_launch () {
|
||||
fi
|
||||
|
||||
[[ $PW_LOG != 1 ]] && debug_timer --start -s "PW_TIME_IN_GAME"
|
||||
case "${portwine_exe,,}" in
|
||||
*.exe)
|
||||
pw_run "${PW_VD_TMP[@]}" ${WINE_WIN_START} "$portwine_exe"
|
||||
;;
|
||||
*.bat)
|
||||
PW_USE_TERMINAL=1
|
||||
pw_run "${PW_VD_TMP[@]}" "$portwine_exe"
|
||||
;;
|
||||
*.msi)
|
||||
pw_run "${PW_VD_TMP[@]}" msiexec /i "$portwine_exe"
|
||||
;;
|
||||
*.reg)
|
||||
pw_run "${PW_VD_TMP[@]}" regedit "$portwine_exe"
|
||||
;;
|
||||
*)
|
||||
pw_run "${PW_VD_TMP[@]}" winefile
|
||||
;;
|
||||
esac
|
||||
if [[ -n "${LAUNCH_URI}" ]]; then
|
||||
pw_run start /high /b "${LAUNCH_URI}" &
|
||||
while true ; do
|
||||
sleep 5
|
||||
GAMEPID="$(pgrep -fa "$(basename "$portwine_exe")" | grep -v "start.sh" | grep -i "epic" | awk '{print $1}')"
|
||||
[[ -n $GAMEPID ]] && break
|
||||
done
|
||||
while [[ -f "/proc/$GAMEPID/exe" ]] ; do sleep 5 ; done
|
||||
else
|
||||
case "${portwine_exe,,}" in
|
||||
*.exe)
|
||||
pw_run "${PW_VD_TMP[@]}" ${WINE_WIN_START} "$portwine_exe"
|
||||
;;
|
||||
*.bat)
|
||||
PW_USE_TERMINAL=1
|
||||
pw_run "${PW_VD_TMP[@]}" "$portwine_exe"
|
||||
;;
|
||||
*.msi)
|
||||
pw_run "${PW_VD_TMP[@]}" msiexec /i "$portwine_exe"
|
||||
;;
|
||||
*.reg)
|
||||
pw_run "${PW_VD_TMP[@]}" regedit "$portwine_exe"
|
||||
;;
|
||||
*)
|
||||
pw_run "${PW_VD_TMP[@]}" winefile
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
}
|
||||
|
||||
pw_winecfg () {
|
||||
@ -6176,8 +6184,7 @@ portwine_output_yad_shortcut () {
|
||||
|
||||
export PW_NEW_DESKTOP="1"
|
||||
|
||||
if [[ "$PW_NO_RESTART_PPDB" != "1" ]] \
|
||||
|| [[ -z ${LINKS[1]} ]] ; then
|
||||
if [[ "$PW_NO_RESTART_PPDB" != "1" ]] ; then
|
||||
print_info "Restarting PP..."
|
||||
[[ "$PW_GUI_START" == "NOTEBOOK" ]] && unset PW_YAD_FORM_TAB
|
||||
restart_pp
|
||||
@ -6192,18 +6199,21 @@ portwine_output_yad_shortcut () {
|
||||
|
||||
parse_lnk () {
|
||||
prefix_name=$(echo "$1" | awk -F"/prefixes/" '{print $2}' | awk -F"/" '{print $1}')
|
||||
if fix_icon_name=$(grep -i "Icon File Name" "${PW_TMPFS_PATH}/exiftool.tmp" 2>/dev/null) \
|
||||
&& [[ "${fix_icon_name//*.exe/true}" == "true" ]] ; then
|
||||
link_drive=$(sed -n 's/^Icon File Name\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp" | cut -d: -f1 | awk '{print tolower($0)}')
|
||||
link_path=$(sed -n 's/^Icon File Name\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp" | sed 's|%ProgramFiles(x86)%|C:\\Program Files (x86)|gi;s|%ProgramFiles%|C:\\Program Files|gi' | sed "s|^.|${PORT_WINE_PATH}/data/prefixes/${prefix_name:-DEFAULT}/dosdevices/$link_drive|g" | sed 's/\\/\//g')
|
||||
if fix_icon_name=$(grep -i "Icon File Name" "${PW_TMPFS_PATH}/exiftool.tmp" 2>/dev/null) && [[ "${fix_icon_name//*.exe/true}" == "true" ]] ; then
|
||||
exe_path=$(sed -n 's/^Icon File Name\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp")
|
||||
else
|
||||
link_drive=$(sed -n 's/^Local Base Path\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp" | cut -d: -f1 | awk '{print tolower($0)}')
|
||||
link_path=$(sed -n 's/^Local Base Path\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp" | sed 's|%ProgramFiles(x86)%|C:\\Program Files (x86)|gi;s|%ProgramFiles%|C:\\Program Files|gi' | sed "s|^.|${PORT_WINE_PATH}/data/prefixes/${prefix_name:-DEFAULT}/dosdevices/$link_drive|g" | sed 's/\\/\//g')
|
||||
exe_path=$(sed -n 's/^Local Base Path\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp")
|
||||
fi
|
||||
get_lnk_path "${exe_path}"
|
||||
link_name=$(sed -n 's/^File Name\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp" | sed 's|\.lnk||')
|
||||
link_cmd=$(sed -n 's/^Command Line Arguments\s*:\s*//p' "${PW_TMPFS_PATH}/exiftool.tmp")
|
||||
}
|
||||
|
||||
get_lnk_path () {
|
||||
link_drive=$(echo "$1" | cut -d: -f1 | awk '{print tolower($0)}')
|
||||
link_path=$(echo "$1" | sed 's|%ProgramFiles(x86)%|C:\\Program Files (x86)|gi;s|%ProgramFiles%|C:\\Program Files|gi' | sed "s|^.|${PORT_WINE_PATH}/data/prefixes/${prefix_name:-${PW_PREFIX_NAME:-DEFAULT}}/dosdevices/${link_drive}|g" | sed 's/\\/\//g')
|
||||
}
|
||||
|
||||
get_lnk () {
|
||||
if command -v exiftool &>/dev/null ; then
|
||||
if timeout 3 exiftool "$1" &> "${PW_TMPFS_PATH}/exiftool.tmp" ; then
|
||||
@ -6228,6 +6238,30 @@ pw_auto_create_shortcut () {
|
||||
return 0
|
||||
fi
|
||||
|
||||
if [[ "${portwine_exe}" =~ EpicGamesLauncher.exe$ ]]; then
|
||||
for item_file in "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/ProgramData/Epic/EpicGamesLauncher/Data/Manifests/"*".item"; do
|
||||
if [[ -f "${item_file}" ]]; then
|
||||
exe_path=$(jq -r '.InstallLocation + "\\" + .LaunchExecutable' "${item_file}")
|
||||
get_lnk_path "${exe_path}"
|
||||
PORTWINE_CREATE_SHORTCUT_NAME=$(jq -r '.DisplayName' "${item_file}")
|
||||
if ! exe_path="$(realpath "${link_path}" 2>/dev/null)" || [[ ! -f "${exe_path}" ]]; then
|
||||
print_warning "Link broken for: ${PORTWINE_CREATE_SHORTCUT_NAME}"
|
||||
elif [[ ! -f "${exe_path}.ppdb" ]]; then
|
||||
unset FILE_SHA256SUM DESKTOP_NAME_FILE DESKTOP_CORRECT_FILE
|
||||
item_id=$(jq -r '.AppName' "${item_file}")
|
||||
portwine_exe="${exe_path}"
|
||||
PORTWINE_DB_FILE="${portwine_exe}.ppdb"
|
||||
LAUNCH_URI="com.epicgames.launcher://apps/${item_id}?action=launch&silent=true"
|
||||
pw_init_db
|
||||
export PW_NO_RESTART_PPDB="1"
|
||||
edit_db_from_gui PW_PREFIX_NAME LAUNCH_URI
|
||||
portwine_create_shortcut
|
||||
fi
|
||||
fi
|
||||
done
|
||||
return 0
|
||||
fi
|
||||
|
||||
unset LINKS
|
||||
for link_file in "${PORT_WINE_PATH}"/data/prefixes/*/drive_c/users/*/Desktop/*.lnk ; do
|
||||
link_file=$(readlink -f "$link_file")
|
||||
|
@ -99,7 +99,7 @@ unset CHK_SYMLINK_FILE PW_MESA_GL_VERSION_OVERRIDE PW_VKD3D_FEATURE_LEVEL PATH_T
|
||||
unset PW_PREFIX_NAME WINEPREFIX VULKAN_MOD PW_WINE_VER PW_ADD_TO_ARGS_IN_RUNTIME PW_GAMEMODERUN_SLR PW_WINE_CPU_TOPOLOGY
|
||||
unset MANGOHUD_CONFIG FPS_LIMIT PW_WINE_USE WINEDLLPATH WINE WINEDIR WINELOADER WINESERVER PW_USE_RUNTIME PORTWINE_CREATE_SHORTCUT_NAME MIRROR
|
||||
unset PW_LOCALE_SELECT PW_SETTINGS_INDICATION PW_GUI_START PW_AUTOINSTALL_EXE NOSTSTDIR RADV_DEBUG PW_NO_AUTO_CREATE_SHORTCUT
|
||||
unset PW_TERM PW_EXEC_FROM_DESKTOP WEBKIT_DISABLE_DMABUF_RENDERER PW_AMD_VULKAN_USE PW_VK_ICD_FILENAMES
|
||||
unset PW_TERM PW_EXEC_FROM_DESKTOP WEBKIT_DISABLE_DMABUF_RENDERER PW_AMD_VULKAN_USE PW_VK_ICD_FILENAMES LAUNCH_URI
|
||||
|
||||
export PORT_WINE_TMP_PATH="${PORT_WINE_PATH}/data/tmp"
|
||||
rm -f "$PORT_WINE_TMP_PATH"/*{exe,msi,tar}*
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
#Author: Castro-Fidel (linux-gaming.ru)
|
||||
#SCRIPTS_NEXT_VERSION=2382
|
||||
#SCRIPTS_NEXT_VERSION=2383
|
||||
#SCRIPTS_STABLE_VERSION=2380
|
||||
########################################################################
|
||||
export AI_TOP_GAMES="PW_LGC PW_VKPLAY PW_EPIC PW_BATTLE_NET PW_WORLD_OF_SEA_BATTLE PW_RUSSIAN_FISHING PW_HO_YO_PLAY PW_FARLIGHT84 PW_WARFRAME PW_WGC PW_UBISOFT"
|
||||
|
Loading…
Reference in New Issue
Block a user