qmlfrontend/team.h
author unC0Rr
Wed, 28 Aug 2024 13:41:51 +0200
changeset 16049 9be943326d9c
parent 14312 f1a5b7baa87f
permissions -rw-r--r--
Store all snowflakes in a separate array, achieving performance increase of about 10% for the whole engine on winter maps

#ifndef TEAM_H
#define TEAM_H

#include <QObject>
#include <QVector>

struct Hedgehog {
  Hedgehog();

  QByteArray name;
  QByteArray hat;
  quint32 hp;
  int level;
};

class Team {
 public:
  explicit Team();

  void resize(int number);
  QVector<Hedgehog> hedgehogs() const;

  QByteArray name;
  QByteArray color;

 private:
  QVector<Hedgehog> m_hedgehogs;
  int m_hedgehogsNumber;
};

#endif  // TEAM_H