Update central_command.py, commander.py and one other file
This commit is contained in:
parent
d6fe1cf183
commit
3010a8186d
@ -31,6 +31,15 @@ class CentralCommand:
|
||||
mission.step()
|
||||
return True
|
||||
|
||||
def run_interactive(self):
|
||||
print('auto mode. hit enter to stop')
|
||||
t = Thread(target=self.wait_for_stop)
|
||||
t.daemon = True
|
||||
t.start()
|
||||
self.run()
|
||||
print('manual mode')
|
||||
|
||||
|
||||
def wait_for_stop(self):
|
||||
try:
|
||||
input()
|
||||
@ -39,13 +48,6 @@ class CentralCommand:
|
||||
self.stopping = True
|
||||
print('stopping...')
|
||||
|
||||
def run_interactive(self):
|
||||
print('auto mode. hit enter to stop')
|
||||
t = Thread(target=self.wait_for_stop)
|
||||
t.daemon = True
|
||||
t.start()
|
||||
self.run()
|
||||
print('manual mode')
|
||||
|
||||
def run(self):
|
||||
self.update_missions()
|
||||
|
@ -123,6 +123,8 @@ class Commander(CommandLine):
|
||||
|
||||
def do_chaul(self):
|
||||
if not self.has_ship(): return
|
||||
if len(ship.cargo) > 0:
|
||||
raise CommandError('please dump cargo first')
|
||||
contract = self.active_contract()
|
||||
delivery = contract.unfinished_delivery()
|
||||
if delivery is None:
|
||||
|
@ -25,6 +25,7 @@ class Marketplace(SystemMember):
|
||||
price['symbol'] = symbol
|
||||
price['buy'] = mg(g, 'purchasePrice')
|
||||
price['sell'] = mg(g, 'sellPrice')
|
||||
price['volume'] = mg(g, 'tradeVolume')
|
||||
prices[symbol] = price
|
||||
self.prices = prices
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user