def run(self): """Call flint functions and emit a signal when each one is complete.""" fl.get_systems() self.jobFinished.emit('systems') fl.maps.generate_universe_graph() self.jobFinished.emit('universe') fl.get_equipment() self.jobFinished.emit('equipment') fl.get_goods() self.jobFinished.emit('goods') fl.routines.get_markets() self.jobFinished.emit('markets')
def run(self): """This is a bit of a hack. Run expensive routines in flint before loading the rest of the application.""" fl.get_systems() self.jobFinished.emit('Systems') fl.maps.generate_universe_graph() self.jobFinished.emit('Universe') fl.get_equipment() self.jobFinished.emit('Equipment') fl.get_goods() self.jobFinished.emit('Goods') fl.routines.get_markets() self.jobFinished.emit('Markets')
def __init__(self, freelancer_root): fl.paths.set_install_path(freelancer_root) self._systems = {s.name() for s in fl.get_systems() if s.name()} self._bases = {b.name() for b in fl.get_bases() if b.name()} self._timer = None self._process = 0 self.begin_polling()
def __call__(self): if not self.state.system: input.queue_display_text(f'Err: unknown location') else: systems = {s.name(): s for s in flint.get_systems()} system_scale = systems[self.state.system].navmapscale sector = flint.maps.pos_to_sector(self.state.pos, system_scale) input.queue_display_text( f'You are in sector {sector}, {self.state.system}')