Scripts version 2146
This commit is contained in:
parent
15b84b931b
commit
5f02f61550
@ -2,13 +2,18 @@ You can help us in the development of the project on the website: boosty.to/linu
|
|||||||
-----------------------------------------
|
-----------------------------------------
|
||||||
Changelog:
|
Changelog:
|
||||||
|
|
||||||
|
###Scripts version 2146###
|
||||||
|
* added interface language switching in the "PORTPROTON SETTINGS" section
|
||||||
|
* added the ability to download the new version of PROTON STEAM 7.0-5
|
||||||
|
* minor fixes and script improvements
|
||||||
|
|
||||||
###Scripts version 2145###
|
###Scripts version 2145###
|
||||||
* added the ability to change SVN and VKD3D versions in the game settings file .pdb and globally in user.conf using variables (values are given for example):
|
* added the ability to change SVN and VKD3D versions in the game settings file .pdb and globally in user.conf using variables (values are given for example):
|
||||||
export DXVK_STABLE_VER="1.10.3"
|
export DXVK_STABLE_VER="1.10.3"
|
||||||
export SVN_GIT_VER="2.0"
|
export SVN_GIT_VER="2.0"
|
||||||
export VKD3D_STABLE_VER="2.6"
|
export VKD3D_STABLE_VER="2.6"
|
||||||
export VKD3D_GIT_VER="2.7"
|
export VKD3D_GIT_VER="2.7"
|
||||||
* for League of Legends, the default version is DX VK 1.10.2 - as more stable for this game
|
* for League of Legends, the default version is DXVK 1.10.2 - as more stable for this game
|
||||||
|
|
||||||
###Scripts version 2144###
|
###Scripts version 2144###
|
||||||
* updated WINE for League of Legends
|
* updated WINE for League of Legends
|
||||||
|
@ -2,6 +2,11 @@
|
|||||||
-----------------------------------------
|
-----------------------------------------
|
||||||
История изменений:
|
История изменений:
|
||||||
|
|
||||||
|
###Scripts version 2146###
|
||||||
|
* добавлено переключение языка интерфейса в разделе "НАСТРОЙКИ PORTPROTON"
|
||||||
|
* добавлена возможность скачивания новой версии PROTON STEAM 7.0-5
|
||||||
|
* небольшие исправления и улучшения скриптов
|
||||||
|
|
||||||
###Scripts version 2145###
|
###Scripts version 2145###
|
||||||
* добавлена возможность смены версий DXVK и VKD3D в файле настроек игры .ppdb и глобально в user.conf с помощью переменных (значения приведены для примера):
|
* добавлена возможность смены версий DXVK и VKD3D в файле настроек игры .ppdb и глобально в user.conf с помощью переменных (значения приведены для примера):
|
||||||
export DXVK_STABLE_VER="1.10.3"
|
export DXVK_STABLE_VER="1.10.3"
|
||||||
|
@ -4,6 +4,7 @@ import os
|
|||||||
import re
|
import re
|
||||||
import shlex
|
import shlex
|
||||||
import shutil
|
import shutil
|
||||||
|
import logging
|
||||||
from configparser import RawConfigParser
|
from configparser import RawConfigParser
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from subprocess import run
|
from subprocess import run
|
||||||
@ -36,9 +37,9 @@ class MainWindow(QMainWindow):
|
|||||||
QMessageBox.critical(self, 'Error', 'Can not find installed PortProton')
|
QMessageBox.critical(self, 'Error', 'Can not find installed PortProton')
|
||||||
exit(1)
|
exit(1)
|
||||||
g.scripts_dir = scripts_dir.rstrip('/')
|
g.scripts_dir = scripts_dir.rstrip('/')
|
||||||
g.pw_icon = shortcut.get('Desktop Entry', 'Icon', fallback='/usr/share/pixmaps/portproton.png')
|
g.pp_icon = shortcut.get('Desktop Entry', 'Icon', fallback='/usr/share/pixmaps/portproton.png')
|
||||||
pw_icon = QIcon(g.pw_icon)
|
pp_icon = QIcon(g.pp_icon)
|
||||||
self.setWindowIcon(pw_icon)
|
self.setWindowIcon(pp_icon)
|
||||||
self.setWindowTitle('PortProton games library')
|
self.setWindowTitle('PortProton games library')
|
||||||
|
|
||||||
g.base_dir = str(Path(scripts_dir + '/../..').resolve())
|
g.base_dir = str(Path(scripts_dir + '/../..').resolve())
|
||||||
@ -58,8 +59,10 @@ class MainWindow(QMainWindow):
|
|||||||
sep.setFrameShadow(QFrame.Shadow.Sunken)
|
sep.setFrameShadow(QFrame.Shadow.Sunken)
|
||||||
self._status_size = QLabel(self)
|
self._status_size = QLabel(self)
|
||||||
self._status_dir = QLabel(self)
|
self._status_dir = QLabel(self)
|
||||||
|
self._status_wine = QLabel(self)
|
||||||
self.statusBar().setVisible(False)
|
self.statusBar().setVisible(False)
|
||||||
self.statusBar().addWidget(self._status_dir, 1)
|
self.statusBar().addWidget(self._status_dir, 1)
|
||||||
|
self.statusBar().addWidget(self._status_wine)
|
||||||
self.statusBar().addWidget(sep)
|
self.statusBar().addWidget(sep)
|
||||||
self.statusBar().addWidget(self._status_size)
|
self.statusBar().addWidget(self._status_size)
|
||||||
|
|
||||||
@ -86,7 +89,7 @@ class MainWindow(QMainWindow):
|
|||||||
spacer = QWidget(self)
|
spacer = QWidget(self)
|
||||||
spacer.setSizePolicy(QSizePolicy.Policy.Expanding, QSizePolicy.Policy.Preferred)
|
spacer.setSizePolicy(QSizePolicy.Policy.Expanding, QSizePolicy.Policy.Preferred)
|
||||||
self.toolbar.addWidget(spacer)
|
self.toolbar.addWidget(spacer)
|
||||||
action = QAction(pw_icon, 'PortProton', self)
|
action = QAction(pp_icon, 'PortProton', self)
|
||||||
action.triggered.connect(self.run_pp)
|
action.triggered.connect(self.run_pp)
|
||||||
self.toolbar.addAction(action)
|
self.toolbar.addAction(action)
|
||||||
|
|
||||||
@ -100,7 +103,7 @@ class MainWindow(QMainWindow):
|
|||||||
self.game_list.reload()
|
self.game_list.reload()
|
||||||
|
|
||||||
def drop_prefix(self):
|
def drop_prefix(self):
|
||||||
res = QMessageBox.question(self, _tr('Are you shure ?'), _tr('Do you really want to remove<br/><b>{0}</b> ?', g.install_pfx))
|
res = QMessageBox.question(self, _tr('Are you sure ?'), _tr('Do you really want to remove<br/><b>{0}</b> ?', g.install_pfx))
|
||||||
if res == QMessageBox.StandardButton.Yes:
|
if res == QMessageBox.StandardButton.Yes:
|
||||||
shutil.rmtree(g.install_pfx, True)
|
shutil.rmtree(g.install_pfx, True)
|
||||||
|
|
||||||
@ -115,6 +118,7 @@ class MainWindow(QMainWindow):
|
|||||||
if item:
|
if item:
|
||||||
self._status_size.setText('Size: ' + item.dir_size_human)
|
self._status_size.setText('Size: ' + item.dir_size_human)
|
||||||
self._status_dir.setText(' ' + item.game_dir)
|
self._status_dir.setText(' ' + item.game_dir)
|
||||||
|
self._status_wine.setText(item.wine_use)
|
||||||
|
|
||||||
def closeEvent(self, event):
|
def closeEvent(self, event):
|
||||||
geometry = self.saveGeometry()
|
geometry = self.saveGeometry()
|
||||||
@ -233,7 +237,7 @@ class InstallGame(QDialog):
|
|||||||
src_dir = self.install_dir + '/' + game_dir
|
src_dir = self.install_dir + '/' + game_dir
|
||||||
dst_dir = g.games_dir + '/' + game_dir
|
dst_dir = g.games_dir + '/' + game_dir
|
||||||
exe_file = shlex.quote(g.games_dir + '/' + item.text())
|
exe_file = shlex.quote(g.games_dir + '/' + item.text())
|
||||||
ppdb = shlex.quote(g.games_dir + '/' + item.text()) + '.ppdb'
|
ppdb = shlex.quote(g.games_dir + '/' + item.text() + '.ppdb')
|
||||||
self.setDisabled(True)
|
self.setDisabled(True)
|
||||||
if self._installing and Path(dst_dir).exists():
|
if self._installing and Path(dst_dir).exists():
|
||||||
res = QMessageBox.question(self, _tr('Dir already exists'), _tr('Dir <b>{0}</b> already exists. Overwrite ?', game_dir))
|
res = QMessageBox.question(self, _tr('Dir already exists'), _tr('Dir <b>{0}</b> already exists. Overwrite ?', game_dir))
|
||||||
@ -246,15 +250,14 @@ class InstallGame(QDialog):
|
|||||||
export portwine_exe={exe_file}
|
export portwine_exe={exe_file}
|
||||||
cd {shlex.quote(g.scripts_dir)}
|
cd {shlex.quote(g.scripts_dir)}
|
||||||
. {shlex.quote(g.scripts_dir + '/runlib')}
|
. {shlex.quote(g.scripts_dir + '/runlib')}
|
||||||
pw_create_gui_png
|
|
||||||
pw_init_db
|
pw_init_db
|
||||||
[ -f {ppdb} ] && . {ppdb}
|
[ -f {ppdb} ] && . {ppdb}
|
||||||
echo -e "export PW_VULKAN_USE=${{PW_VULKAN_USE:-1}}\nexport PW_GUI_DISABLED_CS=1" >> {ppdb}
|
echo -e "export PW_VULKAN_USE=${{PW_VULKAN_USE:-1}}\nexport PW_GUI_DISABLED_CS=1" >> {ppdb}
|
||||||
"""
|
"""
|
||||||
run(['bash', '-c', script])
|
run(['bash', '-c', script])
|
||||||
icon_path = g.base_dir + '/data/img/' + Path(item.text()).stem + '.png'
|
icon_path = g.games_dir + '/' + item.text() + '.ico'
|
||||||
if not Path(icon_path).exists():
|
if not Path(icon_path).exists():
|
||||||
icon_path = g.pw_icon
|
icon_path = g.pp_icon
|
||||||
Path(shortcut).write_text(f"""[Desktop Entry]
|
Path(shortcut).write_text(f"""[Desktop Entry]
|
||||||
Name={shortcut_name}
|
Name={shortcut_name}
|
||||||
Exec=env {shlex.quote(g.scripts_dir + '/start.sh')} {exe_file}
|
Exec=env {shlex.quote(g.scripts_dir + '/start.sh')} {exe_file}
|
||||||
@ -294,8 +297,10 @@ class GameList(QListWidget):
|
|||||||
try:
|
try:
|
||||||
item = GameItem(self, shortcut)
|
item = GameItem(self, shortcut)
|
||||||
self.addItem(item)
|
self.addItem(item)
|
||||||
except Exception:
|
except ValueError:
|
||||||
pass
|
pass
|
||||||
|
except:
|
||||||
|
logging.exception('Error while parse "%s"', shortcut)
|
||||||
self.sortItems()
|
self.sortItems()
|
||||||
self.setCurrentIndex(QModelIndex())
|
self.setCurrentIndex(QModelIndex())
|
||||||
|
|
||||||
@ -316,8 +321,13 @@ class GameList(QListWidget):
|
|||||||
menu = QMenu(self)
|
menu = QMenu(self)
|
||||||
desktop = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DesktopIcon), _tr('Add to desktop'))
|
desktop = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DesktopIcon), _tr('Add to desktop'))
|
||||||
restore_gui = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DialogResetButton), _tr('Restore PortProton GUI'))
|
restore_gui = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DialogResetButton), _tr('Restore PortProton GUI'))
|
||||||
|
default_wine = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DialogOkButton), _tr('Set default wine'))
|
||||||
remove = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_TrashIcon), _tr('Remove game entry'))
|
remove = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_TrashIcon), _tr('Remove game entry'))
|
||||||
uninstall = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DialogCloseButton), _tr('Uninstall game'))
|
uninstall = menu.addAction(self.style().standardIcon(QStyle.StandardPixmap.SP_DialogCloseButton), _tr('Uninstall game'))
|
||||||
|
if not selected.pp_gui_disabled:
|
||||||
|
restore_gui.setVisible(False)
|
||||||
|
if not selected.wine_use:
|
||||||
|
default_wine.setVisible(False)
|
||||||
if not selected.game_dir.startswith(g.games_dir):
|
if not selected.game_dir.startswith(g.games_dir):
|
||||||
uninstall.setVisible(False)
|
uninstall.setVisible(False)
|
||||||
action = menu.exec(self.mapToGlobal(event.pos()))
|
action = menu.exec(self.mapToGlobal(event.pos()))
|
||||||
@ -328,31 +338,38 @@ class GameList(QListWidget):
|
|||||||
if res != QMessageBox.StandardButton.Yes:
|
if res != QMessageBox.StandardButton.Yes:
|
||||||
return
|
return
|
||||||
shutil.copy(selected.desktop_file, desktop_shortcut)
|
shutil.copy(selected.desktop_file, desktop_shortcut)
|
||||||
if action == restore_gui:
|
if action == restore_gui or action == default_wine:
|
||||||
|
ignore_line = 'PW_GUI_DISABLED_CS' if action == restore_gui else 'PW_WINE_USE'
|
||||||
ppdb = shlex.split(selected.get('Exec'))[-1] + '.ppdb'
|
ppdb = shlex.split(selected.get('Exec'))[-1] + '.ppdb'
|
||||||
if not Path(ppdb).exists():
|
if not Path(ppdb).exists():
|
||||||
return
|
return
|
||||||
with open(ppdb, 'r') as read:
|
with open(ppdb, 'r') as read:
|
||||||
with open(ppdb + '.new', 'w') as write:
|
with open(ppdb + '.new', 'w') as write:
|
||||||
while (line := read.readline()):
|
while (line := read.readline()):
|
||||||
if 'PW_GUI_DISABLED_CS' not in line:
|
if ignore_line not in line:
|
||||||
write.write(line)
|
write.write(line)
|
||||||
os.rename(ppdb + '.new', ppdb)
|
os.rename(ppdb + '.new', ppdb)
|
||||||
if action == remove:
|
if action == restore_gui:
|
||||||
|
selected.pp_gui_disabled = False
|
||||||
|
if action == default_wine:
|
||||||
|
selected.wine_use = None
|
||||||
|
self.selectItem(selected)
|
||||||
|
def remove_shortcut():
|
||||||
Path(desktop_shortcut).unlink(True)
|
Path(desktop_shortcut).unlink(True)
|
||||||
Path(selected.desktop_file).unlink(True)
|
Path(selected.desktop_file).unlink(True)
|
||||||
Path(selected.get('Icon')).unlink(True)
|
def_icon_path = g.base_dir + '/data/img/' + Path(shlex.split(selected.get('Exec'))[-1]).stem + '.png'
|
||||||
|
Path(def_icon_path).unlink(True)
|
||||||
|
if action == remove:
|
||||||
|
remove_shortcut()
|
||||||
self.reload()
|
self.reload()
|
||||||
if action == uninstall:
|
if action == uninstall:
|
||||||
res = QMessageBox.question(self,
|
res = QMessageBox.question(self,
|
||||||
_tr('Are you shure ?'),
|
_tr('Are you sure ?'),
|
||||||
_tr('Do you really want to uninstall <b>{0}</b><br/>located in "<b>{1}</b>" ?', selected.get('Name'), selected.game_dir)
|
_tr('Do you really want to uninstall <b>{0}</b><br/>located in "<b>{1}</b>" ?', selected.get('Name'), selected.game_dir)
|
||||||
)
|
)
|
||||||
if res != QMessageBox.StandardButton.Yes:
|
if res != QMessageBox.StandardButton.Yes:
|
||||||
return
|
return
|
||||||
Path(desktop_shortcut).unlink(True)
|
remove_shortcut()
|
||||||
Path(selected.desktop_file).unlink(True)
|
|
||||||
Path(selected.get('Icon')).unlink(True)
|
|
||||||
if selected.game_dir.startswith(g.games_dir):
|
if selected.game_dir.startswith(g.games_dir):
|
||||||
shutil.rmtree(selected.game_dir, True)
|
shutil.rmtree(selected.game_dir, True)
|
||||||
self.reload()
|
self.reload()
|
||||||
@ -374,19 +391,31 @@ class GameItem(QListWidgetItem):
|
|||||||
self.config.read(desktop_file)
|
self.config.read(desktop_file)
|
||||||
text = self.get('Name', Path(desktop_file).stem)
|
text = self.get('Name', Path(desktop_file).stem)
|
||||||
if not self.get('Exec') or text == 'PortProton':
|
if not self.get('Exec') or text == 'PortProton':
|
||||||
raise Exception('Validation fail')
|
raise ValueError('Validation fail')
|
||||||
self.game_dir = shlex.split(self.get('Exec'))[-1]
|
exe_file = shlex.split(self.get('Exec'))[-1]
|
||||||
if self.game_dir.startswith(g.games_dir):
|
if exe_file.startswith(g.games_dir):
|
||||||
self.game_dir = g.games_dir + '/' + self.game_dir[len(g.games_dir)+1:].split('/')[0]
|
self.game_dir = g.games_dir + '/' + exe_file[len(g.games_dir)+1:].split('/')[0]
|
||||||
else:
|
else:
|
||||||
self.game_dir = str(Path(self.game_dir).parent)
|
self.game_dir = str(Path(exe_file).parent)
|
||||||
if self.game_dir == '.':
|
if self.game_dir == '.':
|
||||||
raise Exception('Can not determine game dir')
|
raise ValueError('Can not determine game dir')
|
||||||
|
self.pp_gui_disabled = False
|
||||||
|
self.wine_use = None
|
||||||
|
ppdb = exe_file + '.ppdb'
|
||||||
|
if Path(ppdb).exists():
|
||||||
|
ppdb_conf = RawConfigParser(strict=False)
|
||||||
|
with open(ppdb) as f:
|
||||||
|
ppdb_conf.read_string('[dummy]\n' + f.read())
|
||||||
|
pp_gui_disabled = ppdb_conf.get('dummy', 'export PW_GUI_DISABLED_CS', fallback='').strip('"')
|
||||||
|
try: self.pp_gui_disabled = bool(int(pp_gui_disabled))
|
||||||
|
except: self.pp_gui_disabled = bool(pp_gui_disabled)
|
||||||
|
self.wine_use = ppdb_conf.get('dummy', 'export PW_WINE_USE', fallback='').strip('"')
|
||||||
|
|
||||||
super().__init__(parent)
|
super().__init__(parent)
|
||||||
|
|
||||||
self.setToolTip(text)
|
self.setToolTip(text)
|
||||||
self.setText(text)
|
self.setText(text)
|
||||||
icon_path = self.get('Icon') if Path(self.get('Icon')).exists() else g.pw_icon
|
icon_path = self.get('Icon') if Path(self.get('Icon')).exists() else g.pp_icon
|
||||||
qicon = QIcon(icon_path)
|
qicon = QIcon(icon_path)
|
||||||
self.setIcon(qicon)
|
self.setIcon(qicon)
|
||||||
self.setTextAlignment(Qt.AlignmentFlag.AlignHCenter | Qt.AlignmentFlag.AlignTop)
|
self.setTextAlignment(Qt.AlignmentFlag.AlignHCenter | Qt.AlignmentFlag.AlignTop)
|
||||||
@ -423,7 +452,7 @@ lang = {
|
|||||||
'Add game entry': 'Добавить в список',
|
'Add game entry': 'Добавить в список',
|
||||||
'Reload list': 'Обновить список',
|
'Reload list': 'Обновить список',
|
||||||
'Drop install prefix': 'Удалить установочный префикс',
|
'Drop install prefix': 'Удалить установочный префикс',
|
||||||
'Are you shure ?': 'Вы уверены ?',
|
'Are you sure ?': 'Вы уверены ?',
|
||||||
'Do you really want to remove<br/><b>{0}</b> ?': 'Вы действительно хотите удалить<br/><b>{0}</b> ?',
|
'Do you really want to remove<br/><b>{0}</b> ?': 'Вы действительно хотите удалить<br/><b>{0}</b> ?',
|
||||||
'Run another setup': 'Запустить установку',
|
'Run another setup': 'Запустить установку',
|
||||||
'Select game exe file': 'Выберите exe файл игры',
|
'Select game exe file': 'Выберите exe файл игры',
|
||||||
@ -436,6 +465,7 @@ lang = {
|
|||||||
'Dir <b>{0}</b> already exists. Overwrite ?': 'Директория <b>{0}</b> уже существует. Перезаписать ?',
|
'Dir <b>{0}</b> already exists. Overwrite ?': 'Директория <b>{0}</b> уже существует. Перезаписать ?',
|
||||||
'Add to desktop': 'Добавить на рабочий стол',
|
'Add to desktop': 'Добавить на рабочий стол',
|
||||||
'Restore PortProton GUI': 'Восстановить PortProton GUI',
|
'Restore PortProton GUI': 'Восстановить PortProton GUI',
|
||||||
|
'Set default wine': 'Выбрать дефолтный wine',
|
||||||
'Remove game entry': 'Убрать из списка',
|
'Remove game entry': 'Убрать из списка',
|
||||||
'Uninstall game': 'Удалить игру',
|
'Uninstall game': 'Удалить игру',
|
||||||
'Do you really want to uninstall <b>{0}</b><br/>located in "<b>{1}</b>" ?': 'Вы действительно хотите удалить <b>{0}</b><br/>расположеную в "<b>{1}</b>" ?'
|
'Do you really want to uninstall <b>{0}</b><br/>located in "<b>{1}</b>" ?': 'Вы действительно хотите удалить <b>{0}</b><br/>расположеную в "<b>{1}</b>" ?'
|
||||||
@ -448,6 +478,7 @@ def _tr(text, *fmt):
|
|||||||
return res
|
return res
|
||||||
|
|
||||||
app = QApplication([])
|
app = QApplication([])
|
||||||
|
app.setDesktopFileName('PortProton')
|
||||||
win = MainWindow()
|
win = MainWindow()
|
||||||
win.show()
|
win.show()
|
||||||
app.exec()
|
app.exec()
|
||||||
|
@ -11,6 +11,7 @@ then
|
|||||||
export loc_gui_rm_pp="Удалить PORTPROTON"
|
export loc_gui_rm_pp="Удалить PORTPROTON"
|
||||||
export loc_gui_upd_pp="Проверить обновления"
|
export loc_gui_upd_pp="Проверить обновления"
|
||||||
export loc_gui_changelog="История изменений"
|
export loc_gui_changelog="История изменений"
|
||||||
|
export loc_gui_change_loc="Сменить язык интерфейса"
|
||||||
export loc_gui_edit_usc="Редактировать USER.CONF"
|
export loc_gui_edit_usc="Редактировать USER.CONF"
|
||||||
export loc_gui_scripts_fb="Откатить версию скриптов"
|
export loc_gui_scripts_fb="Откатить версию скриптов"
|
||||||
export loc_gui_credits="Авторы и спасибы =)"
|
export loc_gui_credits="Авторы и спасибы =)"
|
||||||
@ -250,6 +251,7 @@ then
|
|||||||
export loc_gui_rm_pp="REMOVE PORTPROTON"
|
export loc_gui_rm_pp="REMOVE PORTPROTON"
|
||||||
export loc_gui_upd_pp="UPDATE PORTPROTON"
|
export loc_gui_upd_pp="UPDATE PORTPROTON"
|
||||||
export loc_gui_changelog="CHANGELOG"
|
export loc_gui_changelog="CHANGELOG"
|
||||||
|
export loc_gui_change_loc="CHANGE LANGUAGE"
|
||||||
export loc_gui_edit_usc="EDIT USER.CONF"
|
export loc_gui_edit_usc="EDIT USER.CONF"
|
||||||
export loc_gui_scripts_fb="SCRIPTS FROM BACKUP"
|
export loc_gui_scripts_fb="SCRIPTS FROM BACKUP"
|
||||||
export loc_gui_credits="CREDITS"
|
export loc_gui_credits="CREDITS"
|
||||||
|
@ -9,25 +9,12 @@
|
|||||||
################################################
|
################################################
|
||||||
export PW_DISABLED_CREATE_DB=1
|
export PW_DISABLED_CREATE_DB=1
|
||||||
export PW_ICON_FOR_YAD="${PORT_WINE_PATH}/data/img/setup.png"
|
export PW_ICON_FOR_YAD="${PORT_WINE_PATH}/data/img/setup.png"
|
||||||
export PW_VULKAN_USE=0 #dxvk or vkd3d
|
export PW_VULKAN_USE=1
|
||||||
export PW_MANGOHUD=0
|
export PW_MANGOHUD=0
|
||||||
#export PW_WINE_USE=PROTON_LG
|
|
||||||
#export WINEDLLOVERRIDES="blabla=n,b"
|
|
||||||
#export PW_LOG=0 # Enable debug mode fo terminal
|
|
||||||
export PW_NO_FSYNC=1 # Do not use futex-based in-process synchronization primitives. (Automatically disabled on systems with no FUTEX_WAIT_MULTIPLE support.
|
export PW_NO_FSYNC=1 # Do not use futex-based in-process synchronization primitives. (Automatically disabled on systems with no FUTEX_WAIT_MULTIPLE support.
|
||||||
export PW_NO_ESYNC=1 # Do not use eventfd-based in-process synchronization primitives
|
export PW_NO_ESYNC=1 # Do not use eventfd-based in-process synchronization primitives
|
||||||
#export PW_VULKAN_NO_ASYNC=1
|
|
||||||
#export PW_USE_TERMINAL=0
|
|
||||||
#export PW_OLD_GL_STRING=0
|
|
||||||
#export PW_USE_NVAPI_AND_DLSS=0
|
|
||||||
#export PW_VKD3D_FEATURE_LEVEL=0
|
|
||||||
export PW_NO_WRITE_WATCH=0 # Disable support for memory write watches in ntdll. This is a very dangerous hack and should only be applied if you have verified that the game can operate without write watches. This improves performance for some very specific games (e.g. CoreRT-based games).
|
|
||||||
#export PW_HIDE_NVIDIA_GPU=0
|
|
||||||
#export PW_FORCE_USE_VSYNC=2 # Vsync: 0-FORCE_OFF, 1-FORCE_ON, 2-BY_DEFAULT
|
|
||||||
export PW_WINEDBG_DISABLE=1
|
export PW_WINEDBG_DISABLE=1
|
||||||
export PW_USE_GAMEMODE=0 # Force disabele gamemod
|
export PW_USE_GAMEMODE=0 # Force disabele gamemod
|
||||||
export PW_FORCE_LARGE_ADDRESS_AWARE=0 # Force Wine to enable the LARGE_ADDRESS_AWARE flag for all executables. Enabled by default.
|
export PW_FORCE_LARGE_ADDRESS_AWARE=1 # Force Wine to enable the LARGE_ADDRESS_AWARE flag for all executables. Enabled by default.
|
||||||
#export PULSE_LATENCY_MSEC=60
|
|
||||||
export PW_DLL_INSTALL="mfc42 vcrun6sp6 vcrun2012 mfc120 mfc140 vcrun2013"
|
export PW_DLL_INSTALL="mfc42 vcrun6sp6 vcrun2012 mfc120 mfc140 vcrun2013"
|
||||||
#export LAUNCH_PARAMETERS="-d3d9"
|
|
||||||
#export PW_WINDOWS_VER=XP # Set windows version 10, 7 or XP
|
|
||||||
|
@ -391,21 +391,12 @@ start_portwine () {
|
|||||||
export WINE_FULLSCREEN_FSR=0
|
export WINE_FULLSCREEN_FSR=0
|
||||||
else
|
else
|
||||||
echo "Use VKD3D-PROTON and DXVK (DX 9-12 to vulkan)"
|
echo "Use VKD3D-PROTON and DXVK (DX 9-12 to vulkan)"
|
||||||
# if [[ ! -z "${PW_USE_AMDVLK_DRIVER}" ]] && [[ "${PW_USE_AMDVLK_DRIVER}" != 0 ]] ; then
|
|
||||||
# export AMD_VULKAN_ICD=AMDVLK
|
|
||||||
# unset DISABLE_LAYER_AMD_SWITCHABLE_GRAPHICS_1
|
|
||||||
# print_info "Try to use AMDVLK driver (only with MESA)"
|
|
||||||
# else
|
|
||||||
# export AMD_VULKAN_ICD=RADV
|
|
||||||
# export DISABLE_LAYER_AMD_SWITCHABLE_GRAPHICS_1=1
|
|
||||||
# print_info "Try to use RADV driver (only with MESA)"
|
|
||||||
# fi
|
|
||||||
if [[ "${PW_USE_WINE_DXGI}" == 1 ]] ; then
|
if [[ "${PW_USE_WINE_DXGI}" == 1 ]] ; then
|
||||||
export CP_DXVK_FILES="d3d11 d3d10core d3d9" # dxvk_config openvr_api_dxvk
|
export CP_DXVK_FILES="d3d11 d3d10core d3d9"
|
||||||
var_winedlloverride_update "d3d11,d3d10core,d3d9=n"
|
elif [[ "${USE_ALL_DXVK_DLLS}" == 1 ]] ; then
|
||||||
|
export CP_DXVK_FILES="d3d11 d3d10core d3d10_1 d3d10 d3d9 dxgi"
|
||||||
else
|
else
|
||||||
export CP_DXVK_FILES="d3d11 d3d10core d3d9 dxgi" # dxvk_config openvr_api_dxvk
|
export CP_DXVK_FILES="d3d11 d3d10core d3d9 dxgi"
|
||||||
var_winedlloverride_update "d3d11,d3d10core,d3d9,dxgi=n"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "${PW_VULKAN_USE}" == "1" ]] ; then
|
if [[ "${PW_VULKAN_USE}" == "1" ]] ; then
|
||||||
@ -424,11 +415,10 @@ start_portwine () {
|
|||||||
for wine_dxvk_dll in ${CP_DXVK_FILES} ; do
|
for wine_dxvk_dll in ${CP_DXVK_FILES} ; do
|
||||||
try_force_link_file "${PATH_TO_DXVK_FILES}/x32/${wine_dxvk_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/syswow64/${wine_dxvk_dll}.dll"
|
try_force_link_file "${PATH_TO_DXVK_FILES}/x32/${wine_dxvk_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/syswow64/${wine_dxvk_dll}.dll"
|
||||||
try_force_link_file "${PATH_TO_DXVK_FILES}/x64/${wine_dxvk_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/system32/${wine_dxvk_dll}.dll"
|
try_force_link_file "${PATH_TO_DXVK_FILES}/x64/${wine_dxvk_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/system32/${wine_dxvk_dll}.dll"
|
||||||
|
[[ "$?" == 0 ]] && var_winedlloverride_update "${wine_dxvk_dll}=n"
|
||||||
done
|
done
|
||||||
|
|
||||||
echo "Try link native VKD3D files..."
|
echo "Try link native VKD3D files..."
|
||||||
# try_force_link_file "${WINEDIR}/lib/vkd3d/libvkd3d-shader-1.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/syswow64/libvkd3d-shader-1.dll"
|
|
||||||
# try_force_link_file "${WINEDIR}/lib64/vkd3d/libvkd3d-shader-1.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/system32/libvkd3d-shader-1.dll"
|
|
||||||
for wine_vkd3d_dll in d3d12 # libvkd3d-proton-utils-3
|
for wine_vkd3d_dll in d3d12 # libvkd3d-proton-utils-3
|
||||||
do
|
do
|
||||||
try_force_link_file "${PATH_TO_VKD3D_FILES}/x86/${wine_vkd3d_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/syswow64/${wine_vkd3d_dll}.dll"
|
try_force_link_file "${PATH_TO_VKD3D_FILES}/x86/${wine_vkd3d_dll}.dll" "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/windows/syswow64/${wine_vkd3d_dll}.dll"
|
||||||
@ -436,9 +426,9 @@ start_portwine () {
|
|||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "${PW_DX12_DISABLE}" && "${PW_DX12_DISABLE}" != 0 ]]
|
if [[ "${PW_DX12_DISABLE}" == 1 ]]
|
||||||
then var_winedlloverride_update "d3d12=" # libvkd3d-proton-utils-3,libvkd3d-shader-1;
|
then var_winedlloverride_update "d3d12="
|
||||||
else var_winedlloverride_update "d3d12=n" # libvkd3d-proton-utils-3,libvkd3d-shader-1=n
|
else var_winedlloverride_update "d3d12=n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -d "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/vrclient/bin" ]] ; then
|
if [[ ! -d "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/vrclient/bin" ]] ; then
|
||||||
@ -459,7 +449,7 @@ start_portwine () {
|
|||||||
if [[ "${PW_USE_SHADER_CACHE}" == 1 ]] ; then
|
if [[ "${PW_USE_SHADER_CACHE}" == 1 ]] ; then
|
||||||
create_new_dir "${PATH_TO_DXVK_FILES}/gl_shader_cache"
|
create_new_dir "${PATH_TO_DXVK_FILES}/gl_shader_cache"
|
||||||
export __GL_SHADER_DISK_CACHE=1
|
export __GL_SHADER_DISK_CACHE=1
|
||||||
export __GL_SHADER_DISK_CACHE_PATH="${PORT_WINE_TMP_PATH}/gl_shader_cache"
|
export __GL_SHADER_DISK_CACHE_PATH="${PATH_TO_DXVK_FILES}/gl_shader_cache"
|
||||||
export __GL_SHADER_DISK_CACHE_SIZE=50000000000
|
export __GL_SHADER_DISK_CACHE_SIZE=50000000000
|
||||||
export __GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1
|
export __GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1
|
||||||
create_new_dir "${PATH_TO_DXVK_FILES}/dxvk_cache"
|
create_new_dir "${PATH_TO_DXVK_FILES}/dxvk_cache"
|
||||||
@ -662,8 +652,8 @@ cd "${PORT_SCRIPTS_PATH}"
|
|||||||
export PW_PLUGINS_PATH="${PORT_WINE_TMP_PATH}/plugins${PW_PLUGINS_VER}"
|
export PW_PLUGINS_PATH="${PORT_WINE_TMP_PATH}/plugins${PW_PLUGINS_VER}"
|
||||||
|
|
||||||
if [ ! -f "${PORT_WINE_TMP_PATH}/${portname}_loc" ] ; then
|
if [ ! -f "${PORT_WINE_TMP_PATH}/${portname}_loc" ] ; then
|
||||||
SET_LANG=`zenity --title "Install $portname" --text "Select the language" --list --radiolist \
|
SET_LANG=`zenity --title "LAUNGUAGE" --text "Select the language" --list --radiolist \
|
||||||
--column="Set:" --column "Language:" TRUE "RUS" FALSE "ENG" `
|
--column="Set:" --column "Choose language:" TRUE "RUS" FALSE "ENG" `
|
||||||
echo "${SET_LANG}" > "${PORT_WINE_TMP_PATH}/${portname}_loc"
|
echo "${SET_LANG}" > "${PORT_WINE_TMP_PATH}/${portname}_loc"
|
||||||
fi
|
fi
|
||||||
. "${PORT_SCRIPTS_PATH}"/lang
|
. "${PORT_SCRIPTS_PATH}"/lang
|
||||||
|
@ -454,16 +454,6 @@ if [[ ! -z "$(echo ${1} | grep '/Caliber/')" ]] ; then
|
|||||||
export PW_WINE_USE=PROTON_STEAM_6.3-8
|
export PW_WINE_USE=PROTON_STEAM_6.3-8
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# HOTFIX BATTLE.NET
|
|
||||||
|
|
||||||
if [[ ! -z "$(echo ${1} | grep 'Battle.net')" ]] ; then
|
|
||||||
export PW_WINE_USE="$PW_PROTON_LG_VER"
|
|
||||||
# RUN_SETFATTR="${PW_WINELIB}/portable/bin/setfattr"
|
|
||||||
# if [[ -f "${RUN_SETFATTR}" ]] ; then
|
|
||||||
# "${RUN_SETFATTR}" -x user.DOSATTRIB "${PORT_WINE_PATH}/data/prefixes/${PW_PREFIX_NAME}/drive_c/Program Files (x86)/Battle.net/Battle.net."*"/platforms/qwindows.dll" 2>/dev/null
|
|
||||||
# fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
case "${1}" in
|
case "${1}" in
|
||||||
'--help' )
|
'--help' )
|
||||||
echo '
|
echo '
|
||||||
@ -618,6 +608,13 @@ else
|
|||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
change_loc () {
|
||||||
|
try_remove_file "${PORT_WINE_TMP_PATH}/PortProton_loc"
|
||||||
|
echo "Restarting PP for change language..."
|
||||||
|
/usr/bin/env bash -c ${pw_full_command_line[*]} &
|
||||||
|
exit 0
|
||||||
|
}
|
||||||
|
|
||||||
gui_wine_uninstaller () {
|
gui_wine_uninstaller () {
|
||||||
start_portwine
|
start_portwine
|
||||||
pw_run uninstaller
|
pw_run uninstaller
|
||||||
@ -649,6 +646,7 @@ else
|
|||||||
--field=" $loc_gui_rm_pp"!""!"":"FBTN" '@bash -c "button_click gui_rm_portproton"' \
|
--field=" $loc_gui_rm_pp"!""!"":"FBTN" '@bash -c "button_click gui_rm_portproton"' \
|
||||||
--field=" $loc_gui_upd_pp"!""!"":"FBTN" '@bash -c "button_click gui_pw_update"' \
|
--field=" $loc_gui_upd_pp"!""!"":"FBTN" '@bash -c "button_click gui_pw_update"' \
|
||||||
--field=" $loc_gui_changelog"!""!"":"FBTN" '@bash -c "button_click open_changelog"' \
|
--field=" $loc_gui_changelog"!""!"":"FBTN" '@bash -c "button_click open_changelog"' \
|
||||||
|
--field=" $loc_gui_change_loc"!""!"":"FBTN" '@bash -c "button_click change_loc"' \
|
||||||
--field=" $loc_gui_edit_usc"!""!"":"FBTN" '@bash -c "button_click gui_open_user_conf"' \
|
--field=" $loc_gui_edit_usc"!""!"":"FBTN" '@bash -c "button_click gui_open_user_conf"' \
|
||||||
--field=" $loc_gui_scripts_fb"!""!"":"FBTN" '@bash -c "button_click gui_open_scripts_from_backup"' \
|
--field=" $loc_gui_scripts_fb"!""!"":"FBTN" '@bash -c "button_click gui_open_scripts_from_backup"' \
|
||||||
--field=" Xterm"!""!"":"FBTN" '@bash -c "button_click pw_start_cont_xterm"' \
|
--field=" Xterm"!""!"":"FBTN" '@bash -c "button_click pw_start_cont_xterm"' \
|
||||||
@ -698,10 +696,10 @@ else
|
|||||||
--field=" League of Legends"!"$PW_GUI_ICON_PATH/lol.png"!"":"FBTN" '@bash -c "button_click PW_LOL"' \
|
--field=" League of Legends"!"$PW_GUI_ICON_PATH/lol.png"!"":"FBTN" '@bash -c "button_click PW_LOL"' \
|
||||||
--field=" Gameforge Client"!"$PW_GUI_ICON_PATH/gameforge.png"!"":"FBTN" '@bash -c "button_click PW_GAMEFORGE"' \
|
--field=" Gameforge Client"!"$PW_GUI_ICON_PATH/gameforge.png"!"":"FBTN" '@bash -c "button_click PW_GAMEFORGE"' \
|
||||||
--field=" World of Sea Battle (BETA)"!"$PW_GUI_ICON_PATH/wosb.png"!"":"FBTN" '@bash -c "button_click PW_WOSB"' \
|
--field=" World of Sea Battle (BETA)"!"$PW_GUI_ICON_PATH/wosb.png"!"":"FBTN" '@bash -c "button_click PW_WOSB"' \
|
||||||
--field=" CALIBER"!"$PW_GUI_ICON_PATH/caliber.png"!"":"FBTN" '@bash -c "button_click PW_CALIBER"' \
|
--field=" CALIBER"!"$PW_GUI_ICON_PATH/caliber.png"!"":"FBTN" '@bash -c "button_click PW_CALIBER"' \
|
||||||
--field=" FULQRUM GAMES"!"$PW_GUI_ICON_PATH/fulqrumgames.png"!"":"FBTN" '@bash -c "button_click PW_FULQRUM_GAMES"' \
|
--field=" FULQRUM GAMES"!"$PW_GUI_ICON_PATH/fulqrumgames.png"!"":"FBTN" '@bash -c "button_click PW_FULQRUM_GAMES"' \
|
||||||
--field=" Plarium Play"!"$PW_GUI_ICON_PATH/plariumplay.png"!"":"FBTN" '@bash -c "button_click PW_PLARIUM_PLAY"' \
|
--field=" Plarium Play"!"$PW_GUI_ICON_PATH/plariumplay.png"!"":"FBTN" '@bash -c "button_click PW_PLARIUM_PLAY"' \
|
||||||
--field=" ITCH.IO"!"$PW_GUI_ICON_PATH/itch.png"!"":"FBTN" '@bash -c "button_click PW_ITCH"' &
|
--field=" ITCH.IO"!"$PW_GUI_ICON_PATH/itch.png"!"":"FBTN" '@bash -c "button_click PW_ITCH"' &
|
||||||
|
|
||||||
# --field=" Steam Client Launcher"!"$PW_GUI_ICON_PATH/steam.png"!"":"FBTN" '@bash -c "button_click PW_STEAM"'
|
# --field=" Steam Client Launcher"!"$PW_GUI_ICON_PATH/steam.png"!"":"FBTN" '@bash -c "button_click PW_STEAM"'
|
||||||
# --field=" Bethesda.net Launcher"!"$PW_GUI_ICON_PATH/bethesda.png"!"":"FBTN" '@bash -c "button_click PW_BETHESDA"'
|
# --field=" Bethesda.net Launcher"!"$PW_GUI_ICON_PATH/bethesda.png"!"":"FBTN" '@bash -c "button_click PW_BETHESDA"'
|
||||||
@ -779,6 +777,7 @@ case "$PW_YAD_SET" in
|
|||||||
gui_proton_downloader) gui_proton_downloader ;;
|
gui_proton_downloader) gui_proton_downloader ;;
|
||||||
gui_open_scripts_from_backup) gui_open_scripts_from_backup ;;
|
gui_open_scripts_from_backup) gui_open_scripts_from_backup ;;
|
||||||
open_changelog) open_changelog ;;
|
open_changelog) open_changelog ;;
|
||||||
|
change_loc) change_loc ;;
|
||||||
120) gui_vkBasalt ;;
|
120) gui_vkBasalt ;;
|
||||||
pw_create_prefix_backup) pw_create_prefix_backup ;;
|
pw_create_prefix_backup) pw_create_prefix_backup ;;
|
||||||
gui_credits) gui_credits ;;
|
gui_credits) gui_credits ;;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
#Author: Castro-Fidel (linux-gaming.ru)
|
#Author: Castro-Fidel (linux-gaming.ru)
|
||||||
#SCRIPTS_NEXT_VERSION=2145
|
#SCRIPTS_NEXT_VERSION=2146
|
||||||
########################################################################
|
########################################################################
|
||||||
export PW_MANGOHUD=0
|
export PW_MANGOHUD=0
|
||||||
export MANGOHUD_CONFIG=cpu_stats,cpu_temp,cpu_mhz,cpu_color=2e97cb,cpu_text=CPU,gpu_stats,gpu_temp,gpu_core_clock,gpu_mem_clock,vulkan_driver,gpu_name,gpu_color=2e9762,gpu_text=GPU,vram,vram_color=ad64c1,ram,ram_color=c26693,io_color=a491d3,frame_timing=1,frametime_color=00ff00,time,arch,wine,wine_color=eb5b5b,engine_color=eb5b5b,background_alpha=0.2,font_size=24,background_color=020202,text_color=ffffff,toggle_hud=Shift_R+F12,resolution,vkbasalt
|
export MANGOHUD_CONFIG=cpu_stats,cpu_temp,cpu_mhz,cpu_color=2e97cb,cpu_text=CPU,gpu_stats,gpu_temp,gpu_core_clock,gpu_mem_clock,vulkan_driver,gpu_name,gpu_color=2e9762,gpu_text=GPU,vram,vram_color=ad64c1,ram,ram_color=c26693,io_color=a491d3,frame_timing=1,frametime_color=00ff00,time,arch,wine,wine_color=eb5b5b,engine_color=eb5b5b,background_alpha=0.2,font_size=24,background_color=020202,text_color=ffffff,toggle_hud=Shift_R+F12,resolution,vkbasalt
|
||||||
|
Loading…
Reference in New Issue
Block a user