mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Version String managed in a single place. And shown in about Window
This commit is contained in:
parent
513c81b508
commit
5afa2a23f6
@ -1,9 +1,5 @@
|
|||||||
from userdata import logging_config
|
from userdata import logging_config
|
||||||
|
|
||||||
# Logging setup
|
|
||||||
VERSION_STRING = "2.1.0"
|
|
||||||
logging_config.init_logging(VERSION_STRING)
|
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
@ -19,6 +15,9 @@ from qt_ui.windows.QLiberationWindow import QLiberationWindow
|
|||||||
from qt_ui.windows.preferences.QLiberationFirstStartWindow import QLiberationFirstStartWindow
|
from qt_ui.windows.preferences.QLiberationFirstStartWindow import QLiberationFirstStartWindow
|
||||||
from userdata import liberation_install, persistency, liberation_theme
|
from userdata import liberation_install, persistency, liberation_theme
|
||||||
|
|
||||||
|
# Logging setup
|
||||||
|
logging_config.init_logging(uiconstants.VERSION_STRING)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
||||||
os.environ["QT_AUTO_SCREEN_SCALE_FACTOR"] = "1" # Potential fix for 4K screens
|
os.environ["QT_AUTO_SCREEN_SCALE_FACTOR"] = "1" # Potential fix for 4K screens
|
||||||
|
|||||||
@ -8,6 +8,8 @@ from game.event import UnitsDeliveryEvent, FrontlineAttackEvent
|
|||||||
from theater.theatergroundobject import CATEGORY_MAP
|
from theater.theatergroundobject import CATEGORY_MAP
|
||||||
from userdata.liberation_theme import get_theme_icons
|
from userdata.liberation_theme import get_theme_icons
|
||||||
|
|
||||||
|
VERSION_STRING = "2.1.0"
|
||||||
|
|
||||||
URLS : Dict[str, str] = {
|
URLS : Dict[str, str] = {
|
||||||
"Manual": "https://github.com/khopa/dcs_liberation/wiki",
|
"Manual": "https://github.com/khopa/dcs_liberation/wiki",
|
||||||
"Repository": "https://github.com/khopa/dcs_liberation",
|
"Repository": "https://github.com/khopa/dcs_liberation",
|
||||||
|
|||||||
@ -211,17 +211,16 @@ class QLiberationWindow(QMainWindow):
|
|||||||
self.info_panel.setGame(game)
|
self.info_panel.setGame(game)
|
||||||
|
|
||||||
def showAboutDialog(self):
|
def showAboutDialog(self):
|
||||||
text = "<h3>DCS Liberation</h3>" + \
|
text = "<h3>DCS Liberation " + CONST.VERSION_STRING + "</h3>" + \
|
||||||
"<b>Source code :</b> https://github.com/khopa/dcs_liberation" + \
|
"<b>Source code :</b> https://github.com/khopa/dcs_liberation" + \
|
||||||
"<h4>Authors</h4>" + \
|
"<h4>Authors</h4>" + \
|
||||||
"<p>DCS Liberation was originally developed by <b>shdwp</b>, DCS Liberation 2.0 is a partial rewrite based on this work by <b>Khopa</b>." \
|
"<p>DCS Liberation was originally developed by <b>shdwp</b>, DCS Liberation 2.0 is a partial rewrite based on this work by <b>Khopa</b>." \
|
||||||
"<h4>Contributors</h4>" + \
|
"<h4>Contributors</h4>" + \
|
||||||
"shdwp, Khopa, Wrycu, calvinmorrow, JohanAberg, Deus" + \
|
"shdwp, Khopa, Wrycu, calvinmorrow, JohanAberg, Deus, root0fall" + \
|
||||||
"<h4>Special Thanks :</h4>" \
|
"<h4>Special Thanks :</h4>" \
|
||||||
"<b>rp-</b> <i>for the pydcs framework</i><br/>"\
|
"<b>rp-</b> <i>for the pydcs framework</i><br/>"\
|
||||||
"<b>Grimes (mrSkortch)</b> & <b>Speed</b> <i>for the MIST framework</i><br/>"\
|
"<b>Grimes (mrSkortch)</b> & <b>Speed</b> <i>for the MIST framework</i><br/>"\
|
||||||
"<b>Ciribob </b> <i>for the JTACAutoLase.lua script</i><br/>"
|
"<b>Ciribob </b> <i>for the JTACAutoLase.lua script</i><br/>"
|
||||||
|
|
||||||
about = QMessageBox()
|
about = QMessageBox()
|
||||||
about.setWindowTitle("About DCS Liberation")
|
about.setWindowTitle("About DCS Liberation")
|
||||||
about.setIcon(QMessageBox.Icon.Information)
|
about.setIcon(QMessageBox.Icon.Information)
|
||||||
|
|||||||
@ -95,7 +95,7 @@ class NewGameWizard(QtWidgets.QWizard):
|
|||||||
game.budget = int(game.budget * multiplier)
|
game.budget = int(game.budget * multiplier)
|
||||||
game.settings.multiplier = multiplier
|
game.settings.multiplier = multiplier
|
||||||
game.settings.sams = True
|
game.settings.sams = True
|
||||||
game.settings.version = "2.1.0"
|
game.settings.version = CONST.VERSION_STRING
|
||||||
|
|
||||||
if midgame:
|
if midgame:
|
||||||
game.budget = game.budget * 4 * len(list(conflictTheater.conflicts()))
|
game.budget = game.budget * 4 * len(list(conflictTheater.conflicts()))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user