* \returns the score as an unsigned int.
* \todo add a param to specify what tick to use.
*/
- unsigned planetScore() const;
+ unsigned planetScore(int tick = 0) const;
/** Sets the score for the current fleet.
* \param score this param is a unsigned int holding the score
* \todo add a param to specify what tick to use.
*/
- void setPlanetScore(unsigned score);
+ void setPlanetScore(unsigned score, int tick = 0);
+
+ /** Adds score to the current fleet.
+ * \param score this param is a unsigned int holding the score
+ * \todo add a param to specify what tick to use.
+ */
+ void addPlanetScore(unsigned score, int tick = 0);
/** This function is used to get the number of roids of a specific type.
* \param type the for this roid (for pa: metal, crystal, eonium, uninit)
*/
void runBattle(std::vector<Fleet*> friendly, std::vector<Fleet*> hostile);
+ void calculateScoreLoss(std::vector<Fleet*> friendly, int tick = 1);
+
+ float capping(int tick = 0);
+ void setCapping(float capping, int tick = 0);
+
protected:
/** This function is used to start the calculations of a single tick of the
* battle on the current planet. It's protected because it's not really meant
*/
void calcOneTick(Planet* friendly, Fleet* hostile, std::map<std::string, std::map<std::string, int> >& stealfriendly, std::map<std::string, std::map<std::string, int> >& stealhostile, int tick = 0);
- unsigned m_iScore;
+ std::vector <unsigned> m_Score;
+ std::vector <float> m_Capping;
RoidList m_Roids;
};