Skip to content

Commit

Permalink
Format
Browse files Browse the repository at this point in the history
  • Loading branch information
brianquinlan committed Nov 2, 2023
1 parent e3166c7 commit 2e40c77
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dcsmissionpy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@

from dcsmissionpy.mission import Mission


class DCSWorldNotInstalledError(Exception):
pass


_MISSION_TYPES = (
"Single",
"Training",
Expand All @@ -28,13 +30,15 @@ def _get_dcs_path():
except FileNotFoundError:
raise DCSWorldNotInstalledError()


def is_dcs_installed():
try:
_get_dcs_path()
return True
except DCSWorldNotInstalledError:
return False


def get_installed_aircraft():
path = os.path.join(_get_dcs_path(), rf"Mods\aircraft")
for f in os.listdir(path):
Expand Down

0 comments on commit 2e40c77

Please sign in to comment.