mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Add AWCD mid-game cheat
This commit is contained in:
@@ -15,6 +15,7 @@ from PySide6.QtWidgets import (
|
||||
QTableWidgetItem,
|
||||
QVBoxLayout,
|
||||
QWidget,
|
||||
QPushButton,
|
||||
)
|
||||
|
||||
from game.ato.flight import Flight
|
||||
@@ -23,6 +24,7 @@ from game.theater import ConflictTheater
|
||||
from qt_ui.delegates import TwoColumnRowDelegate
|
||||
from qt_ui.models import AirWingModel, AtoModel, GameModel, SquadronModel
|
||||
from qt_ui.simcontroller import SimController
|
||||
from qt_ui.windows.AirWingConfigurationDialog import AirWingConfigurationDialog
|
||||
from qt_ui.windows.SquadronDialog import SquadronDialog
|
||||
|
||||
|
||||
@@ -245,6 +247,18 @@ class AirWingTabs(QTabWidget):
|
||||
)
|
||||
self.addTab(AirInventoryView(game_model), "Inventory")
|
||||
|
||||
if game_model.game.settings.enable_air_wing_adjustments:
|
||||
pb = QPushButton("Open Air Wing Config Dialog")
|
||||
pb.clicked.connect(lambda _: self.open_awcd(game_model))
|
||||
pb.setMaximumWidth(300)
|
||||
layout = QHBoxLayout()
|
||||
layout.addWidget(pb)
|
||||
w = QWidget(layout=layout)
|
||||
self.addTab(w, "Cheats")
|
||||
|
||||
def open_awcd(self, gm: GameModel):
|
||||
AirWingConfigurationDialog(gm.game, True, self).exec_()
|
||||
|
||||
|
||||
class AirWingDialog(QDialog):
|
||||
"""Dialog window showing the player's air wing."""
|
||||
|
||||
Reference in New Issue
Block a user