docs: def calculate_kills(self):
          """
          At the end of the game calculate kills/deaths, taking aegis into account
          This has to be done at the end when we have a playerid : hero map
          """
  
          aegises = deque(self.aegis)
  
          next_aegis = aegises.popleft() if aegises else None
          aegis_expires = None
          active_aegis = None
  
          real_kills = []
  
          for kill in self.kills:
              if next_aegis and next_aegis[0] < kill["tick"]:
                  active_aegis = next_aegis[1]
                  aegis_expires = next_aegis[0] + 1800 * 10  # 10 minutes
  
                  self.indexed_players[active_aegis].aegises += 1
  
                  next_aegis = aegises.popleft() if aegises else None
              elif aegis_expires and kill["tick"] > aegis_expires:
                  active_aegis = None
                  aegis_expires = None
  
              source = kill["source"]
              target = kill["target"]
              timestamp = kill["timestamp"]
  
              if active_aegis == self.heroes[target].index:
                  #This was an aegis kill
                  active_aegis = None
                  aegis_expires = None
  
                  self.heroes[target].aegis_deaths += 1
              else:
                  real_kills.append(kill)
                  self.heroes[target].add_death(source, timestamp)
                  if target != source:
                      #Don't count a deny as a kill
                      self.heroes[source].add_kill(target, timestamp)
  
          self.kills = real_kills