Commit | Line | Data |
---|---|---|
9c4f7450 FC |
1 | import ya2.engine.log # so logging's info/debug are logged |
2 | from sys import argv | |
3 | from panda3d.core import load_prc_file_data | |
4 | if '--version' in argv: | |
5 | load_prc_file_data('', 'window-type none') | |
6 | from os.path import exists | |
7 | from traceback import print_exc | |
404a11ea | 8 | from game.app import PmachinesApp |
9c4f7450 FC |
9 | from p3d_appimage import AppImageBuilder |
10 | ||
11 | ||
12 | class Main: | |
13 | ||
14 | def __init__(self): | |
15 | pmachines = PmachinesApp() | |
16 | if pmachines.updating: | |
17 | AppImageBuilder('pmachines').update() | |
18 | elif not pmachines.version: | |
19 | try: pmachines.base.run() | |
20 | except Exception: | |
21 | print_exc() |