Update analyzer.py, commander.py and one other file

This commit is contained in:
Richard Bronkhorst
2023-06-13 16:33:22 +02:00
parent 7385362d4f
commit 263fc5d29e
3 changed files with 30 additions and 1 deletions

View File

@@ -1,6 +1,6 @@
from .base import Base
from math import sqrt
class System(Base):
x:int = 0
@@ -19,3 +19,6 @@ class System(Base):
def path(self):
sector, symbol = self.symbol.split('-')
return f'atlas/{sector}/{symbol[0:1]}/{self.symbol}.{self.ext()}'
def distance(self, other):
return sqrt((self.x - other.x) ** 2 + (self.y - other.y) ** 2)