def __init__(self, unit, text='', priority=Priority.normal): self.unit = unit self.text = str(text) self.time = time.time() self.priority = priority # deductions from previous data self.coords = unit.coords
def is_executable(self): return self.time <= time.time()
def __init__(self, time_shift=0.01): self.time = time.time() + time_shift
def _actualize_report_time(self): self.next_report_time = time.time() + self.report_timestamp
def remain_report_time(self): return self.next_report_time - time.time()