Main module¶
-
class
Main.Main[source]¶ Bases:
PyQt5.QtWidgets.QMainWindowMain Window of program.
Inherits:
PyQt5.QtWidgets.QMainWindow-
connection_established()[source]¶ Starts multiplayer match and sends settings dump to other side. Called after successful connection established in
connectionWindow.ConnectionWindow
-
establish_internet_connection()[source]¶ Shows QWidget with host/connect options
connectionWindow.ConnectionWindowFunction called on multiplayer_button trigger event.
-
init_ui()[source]¶ Initialize user interface in Main Window. Intended to use only inside constructor.
Starts game. Function called on main_button trigger event. main_button is in the middle of toolbar.
-
paintEvent(e)[source]¶ Overwrites method from
PyQt5.QtWidgets.QMainWindow
-
show_settings_window()[source]¶ Shows QWidget with settings window
settingsWindow.SettingsWindowFunction called on option_act trigger event.
Shows
QMessageBoxto check if user didn’t make misclick. Function called on surrender_button trigger event.
Surrenders the game. Function called from msg_box inside
surrender_button_clicked()
-