Basic mission vessel tunnel

This commit is contained in:
2023-08-29 01:01:24 +02:00
parent 5f2d358664
commit 979415cdb0
10 changed files with 569 additions and 144 deletions

25
lib.py Normal file
View File

@@ -0,0 +1,25 @@
from connector import get_connexion
def get_contract(title):
for c in get_connexion().space_center.contract_manager.active_contracts:
if c.title == title:
return c
raise LookupError('Contract "{}" not found'.format(title))
def get_vessel(name):
for v in get_connexion().space_center.vessels:
if v.name == name:
return v
raise LookupError("Vessel {} not found".format(name))
def get_rescuee_vessel(rescuee_name):
for v in get_connexion().space_center.vessels:
if rescuee_name in v.name:
return v
raise LookupError("Rescuee {} vessel not found".format(rescuee_name))